Adding GenJets to LST with indexing #224
Open
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR replaces #214. It's based on a more up-to-date version of CMSSW (CMSSW_16_0_0_pre4 rather than _pre2).
TrackingNtuple.cc has been modified so that when the trackingNtuple.root file is produced with cmsDriver.py, it includes branches corresponding to GenJets. These branches are:
The last one is an index that allows each sim track to be matched with the jet it is closest to (minimizes ΔR). This replaces the post-processing described in #187, which added branches corresponding to ΔR and the jets after trackingNtuple.root was produced. The branches sim_genjet_deltaR, sim_genjet_deltaEta, and sim_genjet_deltaPhi are now also included in trackingNtuple.root.
This allows the efficiency, fake rate, and duplicate rate to plotted against ΔR. I also included a limit such that only tracks corresponding to GenJets with pT > 1000 GeV are considered.
None of these changes should impact the rest of LST. The code looking at the jet branches can be enabled/disabled using the -J flag.
Here are some example plots for 100 events from the file /RelValQCD_Pt_1800_2400_14/CMSSW_16_0_0_pre1-150X_mcRun4_realistic_v1_STD_RegeneratedGS_Run4D110_noPU-v1/GEN-SIM-DIGI-RAW, including only tracks with GenJet pT > 1000 GeV: