Skip to content

Commit

Permalink
Merge pull request #44768 from mmusich/mm_dev_fix_RecoEgamma_EgammaHL…
Browse files Browse the repository at this point in the history
…TProducers_14_0_X

[14.0.X] fixup eta lookup in `absEtaLowEdges_` in miscellaneous `RecoEgamma/EgammaHLTProducers` plugins
  • Loading branch information
cmsbuild authored and smuzaffar committed Apr 18, 2024
1 parent abea8d7 commit 8134154
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -162,14 +162,13 @@ void EgammaHLTBcHcalIsolationProducersRegional::produce(edm::StreamID,
int iEA = -1;
auto scEta = std::abs(recoEcalCandRef->superCluster()->eta());
for (int bIt = absEtaLowEdges_.size() - 1; bIt > -1; bIt--) {
if (scEta > absEtaLowEdges_.at(bIt)) {
if (scEta >= absEtaLowEdges_[bIt]) {
iEA = bIt;
break;
}
}
isol = isol - rho * effectiveAreas_.at(iEA);
isol = isol - rho * effectiveAreas_[iEA];
}

isoMap.insert(recoEcalCandRef, isol);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -229,12 +229,12 @@ void EgammaHLTHcalVarProducerFromRecHit::produce(edm::StreamID,
int iEA = -1;
auto scEta = std::abs(recoEcalCandRef->superCluster()->eta());
for (int bIt = absEtaLowEdges_.size() - 1; bIt > -1; bIt--) {
if (scEta > absEtaLowEdges_.at(bIt)) {
if (scEta >= absEtaLowEdges_[bIt]) {
iEA = bIt;
break;
}
}
isol = isol - rho * effectiveAreas_.at(iEA);
isol = isol - rho * effectiveAreas_[iEA];
}

isoMap.insert(recoEcalCandRef, isol);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -174,13 +174,12 @@ void HLTEcalPFClusterIsolationProducer<T1>::produce(edm::Event& iEvent, const ed
int iEA = -1;
auto cEta = std::abs(candRef->eta());
for (int bIt = absEtaLowEdges_.size() - 1; bIt > -1; bIt--) {
if (cEta > absEtaLowEdges_.at(bIt)) {
if (cEta >= absEtaLowEdges_[bIt]) {
iEA = bIt;
break;
}
}

sum = sum - rho * effectiveAreas_.at(iEA);
sum = sum - rho * effectiveAreas_[iEA];
}

recoCandMap.insert(candRef, sum);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -200,13 +200,12 @@ void HLTHcalPFClusterIsolationProducer<T1>::produce(edm::StreamID sid,
int iEA = -1;
auto cEta = std::abs(candRef->eta());
for (int bIt = absEtaLowEdges_.size() - 1; bIt > -1; bIt--) {
if (cEta > absEtaLowEdges_.at(bIt)) {
if (cEta >= absEtaLowEdges_[bIt]) {
iEA = bIt;
break;
}
}

sum = sum - rho * effectiveAreas_.at(iEA);
sum = sum - rho * effectiveAreas_[iEA];
}

recoCandMap.insert(candRef, sum);
Expand Down

0 comments on commit 8134154

Please sign in to comment.