-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
Update on L2 muon seeding #22330
Update on L2 muon seeding #22330
Conversation
The code-checks are being triggered in jenkins. |
+code-checks Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-22330/3547 |
A new Pull Request was created by @khaosmos93 for master. It involves the following packages: RecoMuon/L2MuonSeedGenerator @perrotta, @cmsbuild, @silviodonato, @slava77, @Martin-Grunewald, @fwyzard can you please review it and eventually sign? Thanks. cms-bot commands are listed here |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can find below a few sparse comments after a quick glance at your code. Certainly more will follow, but please start at least addressing these ones
@@ -41,6 +43,28 @@ using namespace std; | |||
using namespace edm; | |||
using namespace l1t; | |||
|
|||
//--- Functions used in output sorting | |||
bool SortByL1Pt(L2MuonTrajectorySeed &A, L2MuonTrajectorySeed &B) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Method names should start with lower case letters, upper case being reserved to class names
return (Ref_L1A->pt() > Ref_L1B->pt()); | ||
}; | ||
|
||
bool SortByL1QandPt(L2MuonTrajectorySeed &A, L2MuonTrajectorySeed &B) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Method names should start with lower case letters, upper case being reserved to class names
iEvent.getByToken(offlineSeedToken_, offlineSeedHandle); | ||
LogTrace(metname) << "Number of offline seeds " << offlineSeedHandle->size() << endl; | ||
offlineSeedMap = vector<int>(offlineSeedHandle->size(), 0); | ||
/* |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please remove the commented out code that you included for your debug (or use some LOgDebug if you want to maintain here for possible future needs)
|
||
if (newTSOS.isValid()){ | ||
|
||
//LogDebug(metname) << "(x, y, z) = (" << newTSOS.globalPosition().x() << ", " |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What the reason for letting the LogDebugs commented out (here and below)?
Please either remove (better) or uncomment
|
||
LogTrace(metname) << "radius "<<radius; | ||
|
||
if ( pt < 3.5 ) pt = 3.5; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What is special with "3.5"?
Shouldn't this threshold better made parameterizable, or taken from somewhere else?
unsigned int nL1; | ||
unsigned int i, j; // for the matrix element | ||
|
||
/* |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please remove the commented out code that you included for your debug (or use some LOgDebug if you want to maintain here for possible future needs)
sort(output->begin(),output->end(),SortByL1QandPt); | ||
} | ||
|
||
/* |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please remove the commented out code that you included for your debug (or use some LOgDebug if you want to maintain here for possible future needs)
TrajectoryStateOnSurface offseedTsos = theService->propagator(thePropagatorName)->propagate(offseedFTS, newTsos.surface()); | ||
LogDebug(metlabel) << "Offline seed info: Det and State" << std::endl; | ||
LogDebug(metlabel) << debugtmp.dumpMuonId(offseed->startingState().detId()) << std::endl; | ||
//LogDebug(metlabel) << "(x, y, z) = (" << newTSOS.globalPosition().x() << ", " |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Either uncomment or remove (here and below)
// Remove row and column for given (L1mu, offSeed) | ||
for(i=0; i<NmuColl; ++i) { | ||
for(j=0; j<NofflineSeed1; ++j) { | ||
dRmtx[theL1][j] = 999; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are you filling these vectors NmuColl*NofflineSeed1 times?
// Remove row and column for given (L1mu, offSeed) | ||
for(i=0; i<NmuColl; ++i) { | ||
for(j=0; j<NofflineSeed1; ++j) { | ||
dRmtx[theL1][j] = 999; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are you filling these vectors NmuColl*NofflineSeed1 times?
The code-checks are being triggered in jenkins. |
+code-checks Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-22330/3610 |
Pull request #22330 was updated. @perrotta, @cmsbuild, @silviodonato, @slava77, @Martin-Grunewald, @fwyzard can you please check and sign again. |
please test |
The tests are being triggered in jenkins. |
I update the code following your comments. Changes :
Thanks for the comments, and please let me know if anything more should be done. |
please test |
The tests are being triggered in jenkins. |
Comparison job queued. |
Comparison is ready Comparison Summary:
|
+1
|
@Martin-Grunewald do you confirm your signature? |
+1 |
This pull request is fully signed and it will be integrated in one of the next master IBs (tests are also fine). This pull request will now be reviewed by the release team before it's merged. @davidlange6, @slava77, @smuzaffar, @fabiocos (and backports should be raised in the release meeting by the corresponding L2) |
+1 |
This PR updates the L2 Muon seeding logic.
involving,
In order to make it work in the HLT menu, one should add below two lines at the end of given menu,
process.hltL2MuonSeeds.MatchType = cms.int32(0)
process.hltL2MuonSeeds.SortType = cms.int32(0)
Latest performance tests are done within 92X and they can be found in below link [1].
Efficiency drop in slide 5 of [1] was due to simple typo in 'hadd' command and it recovered after the fix [2].
[1] https://indico.cern.ch/event/694534/contributions/2848643/attachments/1583751/2503305/L2Seeding_MuonHLT_Min_20180116_v2.pdf
[2] https://cernbox.cern.ch/index.php/s/n8fBQECa10OTjof