-
Notifications
You must be signed in to change notification settings - Fork 4.4k
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
Store TrackExtra, TrackingRecHits, and SiPixel/StripClusters for muons in AOD+MINIAOD (Self-contained version without framework thinning) #31217
Conversation
…or muon tracks to RECO sequence and AOD event content
…or muon tracks to MINIAOD sequence and event content
The code-checks are being triggered in jenkins. |
-code-checks Logs: https://cmssdt.cern.ch/SDT/code-checks/cms-sw-PR-31217/17870
Code check has found code style and quality issues which could be resolved by applying following patch(s)
|
The code-checks are being triggered in jenkins. |
A new Pull Request was created by @bendavid (Josh Bendavid) for master. It involves the following packages: DataFormats/PatCandidates @perrotta, @jpata, @cmsbuild, @santocch, @slava77 can you please review it and eventually sign? Thanks. cms-bot commands are listed here |
I may have been missing some details. Would not be easier and more robust to just make a deep copy? |
Deep copy of what? The needed information is spread over reco::Track, reco::TrackExtra, TrackingRecHit, SiPixelCluster, SiStripCluster, and these objects are linked together by edm::Ref, so the only two possibilities I'm aware of are
Open to other alternatives of course. |
track, extra and hits can be deep copied using so what is left is to copy clusters and to rekey omni-refs in hits I admit that DetSetVector is a pretty complex container for thinning and a simpler vector and vector would be easier to fill and handle... |
|
+1 |
+upgrade |
+operations |
kind reminder @cms-sw/analysis-l2 @cms-sw/pdmv-l2 |
+1 |
merge |
+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 be automatically merged. |
- for slimmed/reduced muon clusters/extras from cms-sw/cmssw#31217: add some basic plots or `reco::TrackExtra` and the associated pixel/strip clusters - comes with some refactoring of existing plotting methods for the tracker clusters - for slimmedHcalRecHits from cms-sw/cmssw#31375 : basic plots for HBHE/HO/HF hits are added - comes with some refactoring of existing plotting methods for the calo rec hits - add a plot for hbhe rechits chi2 after some minimal energy cut - add pat Electron and Muon BS2D and PV2D plots - adjust the stats text and the exponent label offset for x and y axis plots to avoid/minimize overlapping or invisible text
Precision measurements using muons might want to be able to refit the muon tracks (and the momentum scale corrections for W mass are moving in this direction).
This PR adds thinned collections of TrackExtra and the corresponding TrackingRecHits and Strip/Pixel clusters to AOD for those tracks which are associated to muon::bestTrack() with some cuts applied to the muons.
(this means that for most muons with pt<200GeV only the pixel and strip rechits are stored and not the muon chamber ones, because bestTrack points to the inner track unless the muon is purely standalone). This behaviour could be modified if desired to store some additional trackExtra/hits for the global track.
The cut applied to the muons to store the extra information in AOD is pt>3.0 GeV.
A further reduced set of collections is stored in MINIAOD, applying a 4.5 GeV cut on top of the selectedPatMuons (such that the extra cuts in
cmssw/PhysicsTools/PatAlgos/python/slimming/miniAOD_tools.py
Line 118 in ee9e9ae
This is a fallback alternative to #30544 in case the needed framework functionality is not integrated quickly enough to backport this to 10_6 in time for the restart of the UL MC campaigns. (Since the AOD event content is modified it would be highly desirable to have this in for consistency purposes)
This PR does not touch any existing producers in the RECO sequence and only adds additional collections. Small modifications are made to the PATMuonSlimmer in the MINIAOD sequence.
Tested using 11834.0 (TTbar 2021 realistic with PU Run3_Flat55To75_PoissonOOTPU) 500 events.
The additional collections in AOD are:
(and the total size per event increases from 672 kB to 674 kB for a 0.25% increase)
The additional collections in MINIAOD are:
(and the total size per event increases from 101.5 kB to 102.4 kB for a 0.9% increase)
Some drawbacks of this approach with respect to the leveraging of framework thinning and slimming as in #30544:
-code is based on recursive rekeying and is therefore harder to maintain
-some duplication of reco::TrackExtras which are already stored in AOD (but need to be duplicated in order to have consistent rekeying of references to TrackingRecHits in the reduced collection)
-additional information is not easily accessible at AOD level, because the final reference rekeying only happens during the production of the slimmedMuons at MINIAOD level (but the association maps are present, so it is possible at least)
Some open points with this PR:
edm::Association<reco::TrackExtraCollection>
required adding additional dictionaries in DataFormats/TrackReco (so this will produce errors when reading the corresponding AOD files with an older release unless dropping those on input)Point 1) I think can be dealt with in a future PR
For points 2) and 3) it may be ok as is, but open to suggestions for alternatives to
edm::Association<reco::TrackExtraCollection>
for this use case (associating the original TrackExtra references to the reduced collection)