ATLAS Offline Software
Loading...
Searching...
No Matches
python.PhysCommonConfig Namespace Reference

Functions

 PhysCommonAugmentationsCfg (flags, **kwargs)

Variables

 msg = logging.getLogger('PHYSCommonConfig')

Function Documentation

◆ PhysCommonAugmentationsCfg()

python.PhysCommonConfig.PhysCommonAugmentationsCfg ( flags,
** kwargs )
Configure the common augmentation

Definition at line 14 of file PhysCommonConfig.py.

14def PhysCommonAugmentationsCfg(flags,**kwargs):
15 """Configure the common augmentation"""
16 acc = ComponentAccumulator()
17
18 # MC truth
19 if flags.Input.isMC:
20 from DerivationFrameworkMCTruth.MCTruthCommonConfig import (
21 AddStandardTruthContentsCfg,
22 AddHFAndDownstreamParticlesCfg,
23 AddMiniTruthCollectionLinksCfg,
24 AddPVCollectionCfg,
25 TruthClassificationAugmentationsCfg)
26 acc.merge(TruthClassificationAugmentationsCfg(flags))
27 from DerivationFrameworkMCTruth.TruthDerivationToolsConfig import DFCommonTruthCharmToolCfg
28 PhysCommonTruthCharmTool = acc.getPrimaryAndMerge(DFCommonTruthCharmToolCfg(
29 flags,
30 name = "PhysCommonTruthCharmTool"))
31 CommonAugmentation = CompFactory.DerivationFramework.CommonAugmentation
32 acc.addEventAlgo(CommonAugmentation("PhysCommonTruthCharmKernel",AugmentationTools=[PhysCommonTruthCharmTool]))
33 acc.merge(AddHFAndDownstreamParticlesCfg(flags))
34 acc.merge(AddStandardTruthContentsCfg
35 (flags,
36 navInputCollections = ["TruthElectrons",
37 "TruthMuons",
38 "TruthPhotons",
39 "TruthTaus",
40 "TruthNeutrinos",
41 "TruthBSM",
42 "TruthBottom",
43 "TruthTop",
44 "TruthBoson",
45 "TruthCharm",
46 "TruthHFWithDecayParticles"]))
47 # Re-point links on reco objects
48 acc.merge(AddMiniTruthCollectionLinksCfg(flags))
49 acc.merge(AddPVCollectionCfg(flags))
50
51 # InDet, Muon, Egamma common augmentations
52 from DerivationFrameworkInDet.InDetCommonConfig import InDetCommonCfg
53 from DerivationFrameworkMuons.MuonsCommonConfig import MuonsCommonCfg
54 from DerivationFrameworkEGamma.EGammaCommonConfig import EGammaCommonCfg
55 # TODO: need to find the new flags equivalent for the missing settings below, then we can
56 # drop these kwargs and do everything via the flags
57 acc.merge(InDetCommonCfg(flags,
58 DoVertexFinding = flags.Tracking.doVertexFinding,
59 AddPseudoTracks = flags.Tracking.doPseudoTracking,
60 DecoLRTTTVA = False,
61 DoR3LargeD0 = flags.Tracking.doLargeD0,
62 StoreSeparateLargeD0Container = flags.Tracking.storeSeparateLargeD0Container,
63 MergeLRT = False))
64 acc.merge(MuonsCommonCfg(flags))
65 acc.merge(EGammaCommonCfg(flags))
66 # Jets, di-taus, tau decorations, flavour tagging, MET association
67 from DerivationFrameworkJetEtMiss.JetCommonConfig import JetCommonCfg
68 from DerivationFrameworkTau.TauCommonConfig import (AddMuonRemovalTauAODReRecoAlgCfg, AddTauIDDecorationCfg)
69 from DerivationFrameworkTau.DiTauCommonConfig import (AddDiTauLowPtCfg, AddDiTauChargeDecoratorCfg, AddDiTauIDDecorationCfg)
70 from DerivationFrameworkJetEtMiss.METCommonConfig import METCommonCfg
71 from DerivationFrameworkJetEtMiss.METCommonConfig import HadRecoilMETCfg
72 acc.merge(JetCommonCfg(flags))
73 #We also need to build links between the newly created jet constituents (GlobalFE)
74 #and electrons,photons,muons and taus
75 from eflowRec.PFCfg import PFGlobalFlowElementLinkingCfg
76 acc.merge(PFGlobalFlowElementLinkingCfg(flags))
77 acc.merge(AddDiTauLowPtCfg(flags))
78 acc.merge(AddMuonRemovalTauAODReRecoAlgCfg(flags))
79 # eVeto WP and DeepSet ID for taus and muon-subtracted taus
80 acc.merge(AddTauIDDecorationCfg(flags, TauContainerName="TauJets"))
81 acc.merge(AddTauIDDecorationCfg(flags, TauContainerName="TauJets_MuonRM"))
82 # add ID score for ditau
83 acc.merge(AddDiTauIDDecorationCfg(flags, DiTauContainerName="DiTauJets"))
84 # for AOD produced before 24.0.17, the electron removal tau is not available
85 if flags.Tau.TauEleRM_isAvailable:
86 acc.merge(AddTauIDDecorationCfg(flags, TauContainerName="TauJets_EleRM"))
87 # ditau Charge
88 acc.merge(AddDiTauChargeDecoratorCfg(flags, DiTauContainerName="DiTauJets"))
89 acc.merge(AddDiTauChargeDecoratorCfg(flags, DiTauContainerName="DiTauJetsLowPt"))
90 if flags.Reco.EnableBTagging:
91 from BTagging.FlavorTaggingConfig import FlavorTaggingCfg
92 acc.merge(FlavorTaggingCfg(flags, "AntiKt4EMPFlowJets"))
93 acc.merge(FlavorTaggingCfg(flags, "AntiKt10UFOCSSKSoftDropBeta100Zcut10Jets"))
94 if flags.BTagging.RunNewVrtSecInclusive:
95 from NewVrtSecInclusiveTool.NewVrtSecInclusiveAlgConfig import (
96 NewVrtSecInclusiveAlgTightCfg
97 )
98 acc.merge(NewVrtSecInclusiveAlgTightCfg(flags))
99 if flags.GeoModel.Run >= LHCPeriod.Run4:
100 acc.merge(FlavorTaggingCfg(flags, "AntiKt4EMTopoJets"))
101
102 acc.merge(METCommonCfg(flags))
103 acc.merge(HadRecoilMETCfg(flags))
104
105 from AssociationUtils.AssociationUtilsConfig import FEAssociationCfg
106 acc.merge(FEAssociationCfg(flags,
107 SmallRJetChargedFELinksDecorKey="",
108 SmallRJetNeutralFELinksDecorKey="",
109 LargeRJetChargedFELinksDecorKey="",
110 LargeRJetNeutralFELinksDecorKey=""))
111
112 # Trigger matching and postprocessing
113 if flags.Reco.EnableTrigger or flags.Trigger.triggerConfig == 'INFILE':
114 from JetTagDerivationUtils.TrigBTagCopierConfig import TrigBTagCopierAlgCfg
115 acc.merge(TrigBTagCopierAlgCfg(flags))
116
117 from DerivationFrameworkPhys.TriggerMatchingCommonConfig import TriggerMatchingCommonRun2Cfg
118 from DerivationFrameworkPhys.TriggerMatchingCommonConfig import TriggerMatchingCommonRun2ToRun3Cfg
119 from DerivationFrameworkPhys.TriggerMatchingCommonConfig import TriggerMatchingCommonRun3Cfg
120 # requires some wrangling due to the difference between run 2 and 3
121 triggerListsHelper = kwargs['TriggerListsHelper']
122 if flags.Trigger.EDMVersion == 2:
123 # NOTE: Once Run-2 -> Run-3 trigger navigation is validated and doEDMVersionConversion is on by default, we will only want to do ONE of
124 # TriggerMatchingCommonRun2Cfg(s) OR TriggerMatchingCommonRun2ToRun3Cfg
125 # Otherwise we are doubling up on the analysis trigger data in both the Run-2 and Run-3 formats.
126
127 # This sets up the Run-2 style matching during the derivation process
128 acc.merge(TriggerMatchingCommonRun2Cfg(
129 flags,
130 name = "PhysCommonTrigMatchNoTau",
131 OutputContainerPrefix = "TrigMatch_",
132 ChainNames = triggerListsHelper.Run2TriggerNamesNoTau))
133 acc.merge(TriggerMatchingCommonRun2Cfg(
134 flags,
135 name = "PhysCommonTrigMatchTau",
136 OutputContainerPrefix = "TrigMatch_",
137 ChainNames = triggerListsHelper.Run2TriggerNamesTau,
138 DRThreshold = 0.2))
139 # This sets up a conversion of the Run-2 trigger navigation to the Run-3 style,
140 # followed by Run-3 style navigation slimming for trigger-matching from DAOD.
141 # This function is a noop if doEDMVersionConversion=False
142 acc.merge(TriggerMatchingCommonRun2ToRun3Cfg(
143 flags,
144 TriggerList = triggerListsHelper.Run2TriggerNamesNoTau +
145 triggerListsHelper.Run2TriggerNamesTau))
146 if flags.Trigger.EDMVersion == 3:
147 # This sets up the Run-3 style navigation slimming for trigger-matching from DAOD
148 acc.merge(TriggerMatchingCommonRun3Cfg(
149 flags, TriggerList = triggerListsHelper.Run3TriggerNames))
150
151 return acc
152

Variable Documentation

◆ msg

python.PhysCommonConfig.msg = logging.getLogger('PHYSCommonConfig')

Definition at line 12 of file PhysCommonConfig.py.