9 from AthenaConfiguration.ComponentAccumulator
import ComponentAccumulator
10 from AthenaConfiguration.ComponentFactory
import CompFactory
14 """Configure the tau truth matching wrapper"""
16 TauTruthMatchingWrapper = CompFactory.DerivationFramework.TauTruthMatchingWrapper
17 acc.addPublicTool(TauTruthMatchingWrapper(name = name, **kwargs), primary =
True)
22 """Configure the tau truth collection maker"""
24 TruthCollectionMakerTau = CompFactory.DerivationFramework.TruthCollectionMakerTau
25 acc.addPublicTool(TruthCollectionMakerTau(name, **kwargs), primary =
True)
30 """Configure the tau truth matching tool"""
32 TauTruthMatchingTool = CompFactory.TauAnalysisTools.TauTruthMatchingTool
33 acc.addPublicTool(TauTruthMatchingTool(name = name, **kwargs), primary =
True)
38 """Configure the BuildTruthTaus tool"""
40 BuildTruthTaus = CompFactory.TauAnalysisTools.BuildTruthTaus
41 acc.addPublicTool(BuildTruthTaus(name = name, **kwargs), primary =
True)
45 """Configure tau truth making and matching"""
48 if not flags.Input.isMC:
53 DFCommonTauTruthWrapperTools = []
57 name =
"DFCommonTauTruthBuilder",
58 WriteInvisibleFourMomentum =
True,
59 WriteVisibleNeutralFourMomentum =
True ))
62 name =
"DFCommonTauTruthCollectionMaker",
63 BuildTruthTaus = acc.getPublicTool(
"DFCommonTauTruthBuilder")))
64 DFCommonTauTruthWrapperTools.append(acc.getPublicTool(
"DFCommonTauTruthCollectionMaker"))
68 if "xAOD::TauJetContainer#TauJets" in flags.Input.TypedCollections:
71 name =
"DFCommonTauTruthMatchingTool",
72 WriteInvisibleFourMomentum =
True,
73 WriteVisibleNeutralFourMomentum =
True,
74 TruthJetContainerName =
"AntiKt4TruthDressedWZJets"))
77 name =
"DFCommonTauTruthMatchingWrapper",
78 TauTruthMatchingTool = DFCommonTauTruthMatchingTool,
79 TauContainerName =
"TauJets"))
80 DFCommonTauTruthWrapperTools.append(DFCommonTauTruthWrapperTool)
82 CommonAugmentation = CompFactory.DerivationFramework.CommonAugmentation
83 acc.addEventAlgo(CommonAugmentation(
"TauTruthCommonKernel", AugmentationTools = DFCommonTauTruthWrapperTools,
84 ExtraOutputs = {(
'xAOD::TruthParticleContainer' ,
'StoreGateSvc+TruthTaus' ),
85 (
'xAOD::IParticleContainer' ,
'StoreGateSvc+TruthTaus' )} ))