Skip to content

Commit

Permalink
safety check to spot negative jet energy correction factors
Browse files Browse the repository at this point in the history
  • Loading branch information
ahinzmann committed May 26, 2020
1 parent fa34d6f commit bf296e1
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions CondFormats/JetMETObjects/src/SimpleJetCorrector.cc
Expand Up @@ -61,6 +61,11 @@ float SimpleJetCorrector::correction(const std::vector<float>& fX, const std::ve
}
result = tmp / mParameters.definitions().nBinVar();
}
if (result <= 0) {
edm::LogWarning("SimpleJetCorrector")
<< "Null or negative jet energy correction factor evaluated: " << result << ". Truncating to 10e-10.";
result = 10e-10;
}
return result;
}
//------------------------------------------------------------------------
Expand Down

0 comments on commit bf296e1

Please sign in to comment.