Skip to content
Snippets Groups Projects
Commit e674226f authored by James Catmore's avatar James Catmore Committed by Tadej Novak
Browse files

Consistently use CommonAugmentation instead of DerivationKernel for common DAOD augmentations

Consistently use CommonAugmentation instead of DerivationKernel for common DAOD augmentations

We noticed during the CA migration of the derivation framework that the cut flow book-keepers were registering cuts from a variety of algorithms that were not involved in event selection. This was because in a few places DerivationKernel (an AthFilterAlgorithm with setFilterPassed explicitly set) was used in writing common augmentations, whereas the correct thing to do is to use CommonAugmentation, which does the same job but doesn't register a cut. This MR implements that correction. Although this issue impacts both the legacy configuration and the CA version, the fix is only applied in the CA.
parent 90175b60
No related branches found
No related tags found
No related merge requests found
......@@ -380,8 +380,8 @@ def AddLargeRJetD2Cfg():
theTruthD2Decorator = acc.getPrimaryAndMerge(TruthD2DecoratorCfg(name = "TruthD2Decorator",
JetContainerKey = "AntiKt10TruthSoftDropBeta100Zcut10Jets",
DecorationName = "D2"))
DerivationKernel = CompFactory.DerivationFramework.DerivationKernel
acc.addEventAlgo(DerivationKernel("TRUTHD2Kernel", AugmentationTools = [theTruthD2Decorator] ))
TruthD2DecoratorKernel = CompFactory.DerivationFramework.CommonAugmentation
acc.addEventAlgo(TruthD2DecoratorKernel("TRUTHD2Kernel", AugmentationTools = [theTruthD2Decorator] ))
return acc
# Truth energy density tools
......@@ -418,8 +418,8 @@ def AddTruthEnergyDensityCfg():
)
acc.addPublicTool(DFCommonTruthEDDecorator, primary = True)
DerivationKernel = CompFactory.DerivationFramework.DerivationKernel
acc.addEventAlgo(DerivationKernel("DFCommonTruthEDKernel", AugmentationTools = [DFCommonTruthEDDecorator] ))
DFCommonTruthEDKernel = CompFactory.DerivationFramework.CommonAugmentation
acc.addEventAlgo(DFCommonTruthEDKernel("DFCommonTruthEDKernel", AugmentationTools = [DFCommonTruthEDDecorator] ))
return acc
......@@ -453,7 +453,7 @@ def AddMiniTruthCollectionLinksCfg(ConfigFlags, **kwargs):
RecoCollection="Muons",
TargetCollections=["TruthMuons","TruthPhotons","TruthElectrons"]))
aug_tools += [ muon_relink ]
acc.addEventAlgo(CompFactory.DerivationFramework.DerivationKernel(
acc.addEventAlgo(CompFactory.DerivationFramework.CommonAugmentation(
"MiniCollectionTruthLinkKernel",
AugmentationTools = aug_tools ))
return acc
......
......@@ -111,7 +111,7 @@ def AddTauWPDecorationCfg(ConfigFlags, **kwargs):
acc = ComponentAccumulator()
TauWPDecoratorWrapper = CompFactory.DerivationFramework.TauWPDecoratorWrapper
DerivationKernel = CompFactory.DerivationFramework.DerivationKernel
TauWPDecoratorKernel = CompFactory.DerivationFramework.CommonAugmentation
if (evetoFixTag=="v1"):
evetoTauWPDecorator = CompFactory.TauWPDecorator(name = f"{prefix}TauWPDecoratorEleRNN",
......@@ -130,8 +130,8 @@ def AddTauWPDecorationCfg(ConfigFlags, **kwargs):
TauContainerName = "TauJets",
TauWPDecorator = evetoTauWPDecorator)
acc.addPublicTool(evetoTauWPDecoratorWrapper)
acc.addEventAlgo(DerivationKernel(name = f"{prefix}TauWPDecorator",
AugmentationTools = [evetoTauWPDecoratorWrapper]))
acc.addEventAlgo(TauWPDecoratorKernel(name = f"{prefix}TauWPDecorator",
AugmentationTools = [evetoTauWPDecoratorWrapper]))
return(acc)
......@@ -188,4 +188,4 @@ def AddMuonRemovalTauAODReRecoAlgCfg(flags, **kwargs):
officialTools = tools_after
)
result.addEventAlgo(myTauAODRunnerAlg)
return result
\ No newline at end of file
return result
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment