Cleanup truth particle association
In a recent merge request that added truth lepton decorations (!318 (merged)), we had some discussion on what aspects to make configurable. I'd like to avoid having too many different configuration options for truth particle association, so I'm going to try to build on the existing truth
structures we have now.
This will (hopefully) make the truth association a bit more flexible:
-
Add the truth particle selection from the lepton decorator added above to the list of options that JetTruthDecorator
supports -
Rename JetTruthDecorator
toJetTruthAssociator
, since it's really just associating truth particles.- Also make the associator store a vector of
IParticle
links, for consistency with the rest of the EDM
- Also make the associator store a vector of
-
Make an optional sub-field in the truth
configuration that specifies selection: if this is empty we expect to read the truth particle links from the EDM-
Make sure unused arguments in the truth structure throw an exception
-
-
Merge the LeptonTruthDecorator
, and theJetLeptonDecayLabelDecorator
to use these associations, and (optionally) run on each linked truth particle collection, with adecorate
option in eachtruth
configuration -
Tell TruthWriter
not to run ifn_to_save
is 0- Implemented as an optional structure for all output options
-
Make TruthWriter
build from the config structure
-
(maybe) make the lepton overlap removal depend on one of these collections, e.g. by removing jets where the number of elements in one associated collections is > 0
Edited by Dan Guest