16 int extended_label = -1;
21 vector<const xAOD::TruthParticle*> partons;
22 bool success =
jet.getAssociatedObjects(
"GhostPartons", partons);
24 for(
auto it = partons.begin(); it != partons.end(); it++) {
27 if((*it)->e() > e_max) {
28 label = (*it)->absPdgId();
29 extended_label = (*it)->pdgId();
32 dr_max = (*it)->p4().DeltaR(
jet.p4());
37 jet.setAttribute(
"PartonTruthLabelID",
label);
38 jet.setAttribute(
"PartonExtendedTruthLabelID", extended_label);
39 jet.setAttribute(
"PartonTruthLabelPt", pt_max);
40 jet.setAttribute(
"PartonTruthLabelEnergy", e_max);
41 jet.setAttribute(
"PartonTruthLabelDR", dr_max);
#define ATH_MSG_VERBOSE(x)
ATLAS-specific HepMC functions.
int modifyJet(xAOD::Jet &jet) const
Modify a single jet. This is obsolete and set to be removed.
std::string label(const std::string &format, int i)
The namespace of all packages in PhysicsAnalysis/JetTagging.
Jet_v1 Jet
Definition of the current "jet version".