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, AddTauTESCompatibilityDecorationCfg)
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 TES compatibility check for taus
83 acc.merge(AddTauTESCompatibilityDecorationCfg(flags, TauContainerName="TauJets"))
84 acc.merge(AddTauTESCompatibilityDecorationCfg(flags, TauContainerName="TauJets_MuonRM"))
85 # add ID score for ditau
86 acc.merge(AddDiTauIDDecorationCfg(flags, DiTauContainerName="DiTauJets"))
87 # for AOD produced before 24.0.17, the electron removal tau is not available
88 if flags.Tau.TauEleRM_isAvailable:
89 acc.merge(AddTauIDDecorationCfg(flags, TauContainerName="TauJets_EleRM"))
90 acc.merge(AddTauTESCompatibilityDecorationCfg(flags, TauContainerName="TauJets_EleRM"))
91 # ditau Charge
92 acc.merge(AddDiTauChargeDecoratorCfg(flags, DiTauContainerName="DiTauJets"))
93 acc.merge(AddDiTauChargeDecoratorCfg(flags, DiTauContainerName="DiTauJetsLowPt"))
94 if flags.Reco.EnableBTagging:
95 from BTagging.FlavorTaggingConfig import FlavorTaggingCfg
96 acc.merge(FlavorTaggingCfg(flags, "AntiKt4EMPFlowJets"))
97 acc.merge(FlavorTaggingCfg(flags, "AntiKt10UFOCSSKSoftDropBeta100Zcut10Jets"))
98 if flags.BTagging.RunNewVrtSecInclusive:
99 from NewVrtSecInclusiveTool.NewVrtSecInclusiveAlgConfig import (
100 NewVrtSecInclusiveAlgTightCfg
101 )
102 acc.merge(NewVrtSecInclusiveAlgTightCfg(flags))
103 if flags.GeoModel.Run >= LHCPeriod.Run4:
104 acc.merge(FlavorTaggingCfg(flags, "AntiKt4EMTopoJets"))
105
106 acc.merge(METCommonCfg(flags))
107 acc.merge(HadRecoilMETCfg(flags))
108
109 from AssociationUtils.AssociationUtilsConfig import FEAssociationCfg
110 acc.merge(FEAssociationCfg(flags,
111 SmallRJetChargedFELinksDecorKey="",
112 SmallRJetNeutralFELinksDecorKey="",
113 LargeRJetChargedFELinksDecorKey="",
114 LargeRJetNeutralFELinksDecorKey=""))
115
116 # Trigger matching and postprocessing
117 if flags.Reco.EnableTrigger or flags.Trigger.triggerConfig == 'INFILE':
118 from JetTagDerivationUtils.TrigBTagCopierConfig import TrigBTagCopierAlgCfg
119 acc.merge(TrigBTagCopierAlgCfg(flags))
120
121 from DerivationFrameworkPhys.TriggerMatchingCommonConfig import TriggerMatchingCommonRun2Cfg
122 from DerivationFrameworkPhys.TriggerMatchingCommonConfig import TriggerMatchingCommonRun2ToRun3Cfg
123 from DerivationFrameworkPhys.TriggerMatchingCommonConfig import TriggerMatchingCommonRun3Cfg
124 # requires some wrangling due to the difference between run 2 and 3
125 triggerListsHelper = kwargs['TriggerListsHelper']
126 if flags.Trigger.EDMVersion == 2:
127 # NOTE: Once Run-2 -> Run-3 trigger navigation is validated and doEDMVersionConversion is on by default, we will only want to do ONE of
128 # TriggerMatchingCommonRun2Cfg(s) OR TriggerMatchingCommonRun2ToRun3Cfg
129 # Otherwise we are doubling up on the analysis trigger data in both the Run-2 and Run-3 formats.
130
131 # This sets up the Run-2 style matching during the derivation process
132 acc.merge(TriggerMatchingCommonRun2Cfg(
133 flags,
134 name = "PhysCommonTrigMatchNoTau",
135 OutputContainerPrefix = "TrigMatch_",
136 ChainNames = triggerListsHelper.Run2TriggerNamesNoTau))
137 acc.merge(TriggerMatchingCommonRun2Cfg(
138 flags,
139 name = "PhysCommonTrigMatchTau",
140 OutputContainerPrefix = "TrigMatch_",
141 ChainNames = triggerListsHelper.Run2TriggerNamesTau,
142 DRThreshold = 0.2))
143 # This sets up a conversion of the Run-2 trigger navigation to the Run-3 style,
144 # followed by Run-3 style navigation slimming for trigger-matching from DAOD.
145 # This function is a noop if doEDMVersionConversion=False
146 acc.merge(TriggerMatchingCommonRun2ToRun3Cfg(
147 flags,
148 TriggerList = triggerListsHelper.Run2TriggerNamesNoTau +
149 triggerListsHelper.Run2TriggerNamesTau))
150 if flags.Trigger.EDMVersion == 3:
151 # This sets up the Run-3 style navigation slimming for trigger-matching from DAOD
152 acc.merge(TriggerMatchingCommonRun3Cfg(
153 flags, TriggerList = triggerListsHelper.Run3TriggerNames))
154
155 return acc
156

Variable Documentation

◆ msg

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

Definition at line 12 of file PhysCommonConfig.py.