Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement quick fix for eta going out of scope #43852

Merged
merged 3 commits into from
Feb 9, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions L1Trigger/L1TTrackMatch/plugins/L1TrackJetEmulatorProducer.cc
Original file line number Diff line number Diff line change
Expand Up @@ -297,6 +297,13 @@ void L1TrackJetEmulatorProducer::produce(Event &iEvent, const EventSetup &iSetup
// Eta bin
int j = eta_bin_firmwareStyle(L1TrkPtrs_[k]->getTanlWord()); //Function defined in L1TrackJetClustering.h

//This is a quick fix to eta going outside of scope - also including protection against phi going outside
//of scope as well. The eta index, j, cannot be less than zero or greater than 23 (the number of eta bins
//minus one). The phi index, i, cannot be less than zero or greater than 26 (the number of phi bins
//minus one).
if ((j < 0) || (j > (etaBins_ - 1)) || (i < 0) || (i > (phiBins_ - 1)))
continue;

if (trkpt < pt_intern(trkPtMax_))
epbins[i][j].pTtot += trkpt;
else
Expand Down