Render "jet context" be dependent on ConfigFlags
In a Jet sequence configuration the "Jet context" represents a set of options which must be common to all components (algs & tools) related to the jet sequence.
Jet contexts are defined and stored as dictionnaries inside a common jetContextDict
in standardJetContext.py
Until now the standard jet sequence descriptions (JetDefinition
) point to a default entry in the jetContextDict
which contains option for Run3 (in practice this means JetDefinition.context=="default"
and jetContextDict['default'] = dict(..options...)
)
This means that in Run4 jobs all usages of JetDefinition
must be preceded by an update of their context
properties. This implies checks on flags.GeoModel.Run
and updates in multiple parts of the config (reco, DAOD, ...).
This seems impractical (duplication of code) and error prone (in case a check is forgotten).
After discussions on the draft, this MR proposes to remove the jetContextDic
and to place all jet contexts under config flags. This allows to solve the pbm discussed above by defining flags.Jet.Context.default
as a function redirecting to the run3 or run4 context according to flags. This is also done with trigger context.
The change in implementation also impacts trigger, derivation and HI domains which all directly use some of the low-level jet config function, so I have adapted the calls to these functions and also details regarding the usage of jetContextDict
.