55def TopParentDecoratorCfg(flags, name="TopParentDecoratorAlg", **kwargs):
56 kwargs.setdefault("parents", "TruthTop")
57 kwargs.setdefault("decoratorPrefix", "parentTop")
58 kwargs.setdefault("parentPdgIds", [-6, 6])
59
60 kwargs.setdefault("cascades", ["TruthBoson", "TruthBosonsWithDecayParticles",
61 "TruthBottom", "TruthCharm",
62 "TruthTaus", "TruthElectrons",
63 "TruthForwardProtons", "TruthHFWithDecayParticles"])
64
65
66
67
68 kwargs.setdefault(
"warnMissingChildrenPdgIds",
set())
69 kwargs.setdefault("allowMissingChildrenPdgIds", {-11, 11})
70 kwargs.setdefault("missingChildrenFractionWarningThreshold", 0.001)
71
72
73 if "AntiKt" in kwargs.get("targetContainer", ""):
74
75 decay_pdgids = [24, 5, 4, 3, 2, 1, 11, 15]
76 kwargs.setdefault("cascadePdgIds", [-x for x in decay_pdgids] + decay_pdgids)
77
78 kwargs.setdefault("countChildrenInCascadeWithPdgIds",
79 {"nTopToWChildren": [-24, 24],
80 "nTopToBChildren": [-5, 5]})
81 else:
82 kwargs.setdefault("countChildrenInCascadeWithPdgIds",
83 {"nTopToWChildren": [-24, 24]})
84 kwargs.setdefault("vetoSoftLeptonCascade", False)
85 kwargs.setdefault("vetoSoftCharmCascade", False)
86
87 return TruthParentDecoratorCfg(flags, name, **kwargs)