ATLAS Offline Software
Loading...
Searching...
No Matches
METTruthAssociator.cxx
Go to the documentation of this file.
1
2
3/*
4 Copyright (C) 2002-2023 CERN for the benefit of the ATLAS collaboration
5*/
6
7// METTruthAssociator.cxx
8// Implementation file for class METTruthAssociator
9//
10// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
11//
12// Author: P Loch, S Resconi, TJ Khoo, AS Mete, MA Klein
14
15// METReconstruction includes
17
19
20// xAOD EDM
29
30// Helpers
32//#include "xAODEgamma/EgammaTruthxAODHelpers.h"
35
36// DeltaR calculation
38
39namespace met {
40
41 using namespace xAOD;
42
44
45 // Constructors
51
52 // Destructor
55 = default;
56
57 // Athena algtool's Hooks
60 {
62 ATH_MSG_VERBOSE ("Initializing " << name() << "...");
63 //initialise ReadHandleKeys
64 ATH_CHECK( m_recoElKey.initialize());
65 ATH_CHECK( m_recoJetKey.initialize());
66 ATH_CHECK( m_recoMuKey.initialize());
67 ATH_CHECK( m_recoGamKey.initialize());
68 ATH_CHECK( m_recoTauKey.initialize());
69 ATH_CHECK( m_truthEventKey.initialize());
70
71 return StatusCode::SUCCESS;
72 }
73
75 {
76 ATH_MSG_VERBOSE ("Finalizing " << name() << "...");
77 return StatusCode::SUCCESS;
78 }
79
80 // executeTool
83 {
84 ATH_MSG_VERBOSE ("In execute: " << name() << "...");
85
86 ATH_CHECK( associateJets(metMap) );
87
89 if (!electronCont.isValid()) {
90 ATH_MSG_WARNING("Unable to retrieve input electron container " << m_recoElKey.key());
91 return StatusCode::FAILURE;
92 }
93
94 ATH_MSG_DEBUG("Successfully retrieved electron collection");
95 if(fillAssocMap(metMap,electronCont.cptr()).isFailure()) {
96 ATH_MSG_WARNING("Unable to fill map with electron container " << m_recoElKey.key());
97 return StatusCode::FAILURE;
98 }
99
101 if (!photonCont.isValid()) {
102 ATH_MSG_WARNING("Unable to retrieve input photon container " << m_recoGamKey.key());
103 return StatusCode::FAILURE;
104 }
105
106 ATH_MSG_DEBUG("Successfully retrieved photon collection");
107 if(fillAssocMap(metMap,photonCont.cptr()).isFailure()) {
108 ATH_MSG_WARNING("Unable to fill map with photon container " << m_recoGamKey.key());
109 return StatusCode::FAILURE;
110 }
111
113 if (!muonCont.isValid()) {
114 ATH_MSG_WARNING("Unable to retrieve input muon container " << m_recoMuKey.key());
115 return StatusCode::FAILURE;
116 }
117
118 ATH_MSG_DEBUG("Successfully retrieved muon collection");
119 if(fillAssocMap(metMap,muonCont.cptr()).isFailure()) {
120 ATH_MSG_WARNING("Unable to fill map with muon container " << m_recoMuKey.key());
121 return StatusCode::FAILURE;
122 }
123
125 if (!tauCont.isValid()) {
126 ATH_MSG_WARNING("Unable to retrieve input tau container " << m_recoTauKey.key());
127 return StatusCode::FAILURE;
128 }
129 ATH_MSG_DEBUG("Successfully retrieved tau collection");
130 if(fillAssocMap(metMap,tauCont.cptr()).isFailure()) {
131 ATH_MSG_WARNING("Unable to fill map with tau container " << m_recoTauKey.key());
132 return StatusCode::FAILURE;
133 }
134
135 if( computeSoftTerms(metCont,metMap).isFailure() ) {
136 ATH_MSG_WARNING("Unable to build truth core soft terms.");
137 return StatusCode::FAILURE;
138 }
139
140 return StatusCode::SUCCESS;
141 }
142
143 //*********************************************************************************************************
144 // Build jet and soft contributions
145
147 {
148 // Retrieve the jet container
150 if (!jetCont.isValid()) {
151 ATH_MSG_WARNING("Unable to retrieve input jet container " << m_recoJetKey.key());
152 return StatusCode::FAILURE;
153 }
154 ATH_MSG_DEBUG("Successfully retrieved jet collection");
155
156 // Create jet associations
157 std::vector<const IParticle*> chargedTruth;
158 std::vector<const IParticle*> jetTruth;
159 std::vector<ElementLink<IParticleContainer> > jetconst;
160 jetTruth.reserve(20);
161 for(const auto *const jet : *jetCont) {
162 jetTruth.clear();
163 jetconst.clear();
166 if(!cacc_ghosttruth.isAvailable(*jet)) {
167 ATH_MSG_WARNING("Failed to extract ghost truth particles from jet");
168 } else {
169 for (const auto& el : cacc_ghosttruth(*jet)) {
170 if(el.isValid()) {
171 const xAOD::TruthParticle *truth = static_cast<const xAOD::TruthParticle*>(*el);
172 ATH_MSG_VERBOSE("Jet contains truth particle " << truth);
173 if(fabs(truth->charge())>1e-6) {
174 trkvec += *truth;
175 }
176 if(!truth->isMuon()) {
177 jetconst.push_back(el);
178 jetTruth.push_back(truth);
179 truthvec += *truth;
180 }
181 }
182 }
183 }
184
185 MissingETComposition::add(metMap,jet,jetconst,trkvec);
186 MissingETComposition::insert(metMap,jet,jet,jetTruth);
187 ATH_MSG_VERBOSE("Added association " << metMap->findIndex(jet) << " pointing to jet " << jet);
188 ATH_MSG_VERBOSE("Jet pt, eta, phi = " << jet->pt() << ", " << jet->eta() << "," << jet->phi() );
189 ATH_MSG_VERBOSE("Jet truthvec pt = " << truthvec.cpt() );
190 ATH_MSG_VERBOSE("Jet trkvec pt = " << trkvec.cpt() );
191 }
192
194 ATH_MSG_DEBUG("Added miscellaneous association");
195
196 return StatusCode::SUCCESS;
197 }
198
200 {
201 // Add MET terms to the container
202 // Always do this in order that the terms exist even if the method fails
204 metCont->push_back(metCoreAllTruth);
205 MissingET* metCoreChargedTruth = new MissingET(0.,0.,0.,"SoftTruthChargedCore",MissingETBase::Source::softEvent() | MissingETBase::Source::truthInt() | MissingETBase::Source::Category::ID);
206 metCont->push_back(metCoreChargedTruth);
208 metCont->push_back(metCoreChargedCentralTruth);
209
210 ATH_MSG_VERBOSE("Added core terms.");
211
212 // Retrieve the truth container
214 if (!truthEventCont.isValid()) {
215 ATH_MSG_WARNING("Unable to retrieve input truthEvent container " << m_truthEventKey.key());
216 return StatusCode::FAILURE;
217 }
218
219 // First truth event is the hard scatter
220 const TruthEvent* hsevent = truthEventCont->front();
222 for(size_t itp=0; itp<hsevent->nTruthParticles(); ++itp) {
223 const xAOD::TruthParticle* tp = hsevent->truthParticle(itp);
224 if(tp) {
225 truthParticleCont.push_back(tp);
226 ATH_MSG_VERBOSE("Extracted truth particle with index " << tp->index() );
227 }
228 }
229
230 const IParticleContainer* uniqueTruth = metMap->getUniqueSignals(truthParticleCont.asDataVector(),MissingETBase::UsageHandler::TruthParticle);
231 ATH_MSG_VERBOSE("Extracted " << uniqueTruth->size() << "/" << truthParticleCont.size()
232 << " unique truth particles.");
233 for(const auto *const part : *uniqueTruth) {
234 const xAOD::TruthParticle* truth = static_cast<const xAOD::TruthParticle*>(part);
235 // stable
236 if(!truth->isGenStable()) continue;
237 // interacting
238 if(!MC::isInteracting(truth->pdgId())) continue;
239 if(truth->pt()<1 || fabs(truth->eta())>5) continue;
240 ATH_MSG_VERBOSE("Accepted soft truth particle with pt " << truth->pt()
241 << " status " << truth->status()
242 << " pdgId " << truth->pdgId() );
243 if(fabs(truth->charge())>1e-6) {
244 // in ID acceptance
245 if(fabs(truth->eta())<2.5) *metCoreChargedCentralTruth += truth;
246 *metCoreChargedTruth += truth;
247 }
248 if(!truth->isMuon()) *metCoreAllTruth += truth;
249 }
250 delete uniqueTruth;
251 return StatusCode::SUCCESS;
252 }
253
254 //*********************************************************************************************************
255 // Get constituents
257 std::vector<const xAOD::IParticle*>& truthlist) const
258 {
259 switch(obj->type()) {
261 return extractTruthFromElectron(obj,truthlist);
263 return extractTruthFromPhoton(obj,truthlist);
264 case xAOD::Type::Muon:
265 return extractTruthFromMuon(obj,truthlist);
266 case xAOD::Type::Tau:
267 return extractTruthFromTau(obj,truthlist);
268 default:
269 ATH_MSG_WARNING("Invalid object type " << obj->type() << " passed to extractTruthParticle");
270 break;
271 }
272
273 return StatusCode::FAILURE;
274 }
275
277 std::vector<const xAOD::IParticle*>& truthlist) const
278 {
279 const xAOD::Electron* el = static_cast<const xAOD::Electron*>(obj);
280 // El --> TruthParticles
282 if(eltruth && eltruth->isGenStable())
283 truthlist.push_back(eltruth);
284
285 // for(size_t iTrk=0; iTrk<el->nTrackParticles(); ++iTrk) {
286 // const TrackParticle* eltrk = EgammaHelpers::getOriginalTrackParticleFromGSF(el->trackParticle(iTrk));
287 // const xAOD::IParticle* truth(0);
288 // if(eltrk) truth = TruthHelpers::getTruthParticle( *eltrk );
289 // if(truth && truth!=eltruth) truthlist.push_back(truth);
290 // }
291
292 // Retrieve the truth container
294 if (!truthEventCont.isValid()) {
295 ATH_MSG_WARNING("Unable to retrieve input truthEvent container " << m_truthEventKey.key());
296 return StatusCode::SUCCESS;
297 }
298
299
300 // First truth event is the hard scatter
301 const TruthEvent* hsevent = truthEventCont->front();
303 for(size_t itp=0; itp<hsevent->nTruthParticles(); ++itp) {
304 const xAOD::TruthParticle* tp = hsevent->truthParticle(itp);
305 if(tp) {
306 truthParticleCont.push_back(tp);
307 }
308 }
309
310 for(const auto truth : truthParticleCont) {
311 if(truth->pt()<1) continue;
312 // stable
313 if(!truth->isGenStable()) continue;
314 // interacting
315 if(!MC::isInteracting(truth->pdgId())) continue;
316 float etasize = 0.025/2;
317 float phisize = 0.025/2;
318 bool isSuperCluster = false;
319 float Rsize = 0.;
320 switch(el->caloCluster()->clusterSize()) {
322 etasize *= 5; phisize *=5;
323 break;
325 etasize *= 3; phisize *=5;
326 break;
328 etasize *= 3; phisize *=7;
329 break;
331 isSuperCluster = true;
332 Rsize = el->caloCluster()->getMomentValue( xAOD::CaloCluster::SECOND_R );
333 if (Rsize<0.) {ATH_MSG_VERBOSE("Invalid SECOND_R moment retrieved!");}
334 break;
335 default:
336 ATH_MSG_WARNING("Unexpected electron cluster size " << el->caloCluster()->clusterSize() << " received!");
337 continue;
338 }
339 float deltaEta(fabs(truth->eta()-el->caloCluster()->eta()));
340 float deltaPhi(fabs(truth->p4().DeltaPhi(el->caloCluster()->p4())));
341 if( (isSuperCluster && (deltaEta*deltaEta+deltaPhi*deltaPhi)<Rsize*Rsize ) ||
342 (deltaEta<etasize && deltaPhi<phisize) ) {
343 bool skip(false);
344 for(const auto& truthobj : truthlist) {
345 const xAOD::TruthParticle *truth2 = static_cast<const xAOD::TruthParticle*>(truthobj);
346 if(truth==truth2) { skip = true; break;}
347 }
348 if(!skip) {
349 truthlist.push_back(truth);
350 }
351 }
352 }
353
354 return StatusCode::SUCCESS;
355 }
356
358 std::vector<const xAOD::IParticle*>& truthlist) const
359 {
360 const xAOD::Photon* ph = static_cast<const xAOD::Photon*>(obj);
361 // Ph --> TruthParticles
363 if(phtruth && phtruth->isGenStable())
364 truthlist.push_back(phtruth);
365
366 // std::vector<const xAOD::TrackParticle*> phtrks;
367 // for(size_t iVtx=0; iVtx<ph->nVertices(); ++iVtx) {
368 // const xAOD::Vertex* phvx = ph->vertex(iVtx);
369 // for(size_t iTrk=0; iTrk<phvx->nTrackParticles(); ++iTrk) {
370 // const xAOD::TrackParticle* phtrk = EgammaHelpers::getOriginalTrackParticleFromGSF(phvx->trackParticle(iTrk));
371 // bool duplicate = false;
372 // for(const auto& gamtrk : phtrks) {
373 // if( (duplicate = (phtrk == gamtrk)) ) {
374 // ATH_MSG_VERBOSE("Veto duplicate track");
375 // break;
376 // }
377 // }
378 // if(!duplicate) {
379 // const xAOD::IParticle* truth(0);
380 // if(phtrk) truth = TruthHelpers::getTruthParticle( *phtrk );
381 // if(truth && truth!=phtruth) truthlist.push_back(truth);
382 // }
383 // }
384 // }
385
386 // Retrieve the truth container
388 if (!truthEventCont.isValid()) {
389 ATH_MSG_WARNING("Unable to retrieve input truthEvent container " << m_truthEventKey.key());
390 return StatusCode::SUCCESS;
391 }
392
393 // First truth event is the hard scatter
394 const TruthEvent* hsevent = truthEventCont->front();
396 for(size_t itp=0; itp<hsevent->nTruthParticles(); ++itp) {
397 const xAOD::TruthParticle* tp = hsevent->truthParticle(itp);
398 if(tp) {
399 truthParticleCont.push_back(tp);
400 }
401 }
402
403 for(const auto truth : truthParticleCont) {
404 if(!truth || truth->pt()<1) continue;
405 // stable
406 if(!truth->isGenStable()) continue;
407 // interacting
408 if(!MC::isInteracting(truth->pdgId())) continue;
409 float etasize(0.025/2);
410 float phisize(0.025/2);
411 bool isSuperCluster = false;
412 float Rsize = 0.;
413 switch(ph->caloCluster()->clusterSize()) {
416 etasize *= 5; phisize *=5;
417 break;
421 etasize *= 3; phisize *=5;
422 break;
425 etasize *= 3; phisize *=7;
426 break;
428 isSuperCluster = true;
430 if (Rsize<0.) {ATH_MSG_VERBOSE("Invalid SECOND_R moment retrieved!");}
431 break;
432 default:
433 ATH_MSG_WARNING("Unexpected photon cluster size " << ph->caloCluster()->clusterSize() << " received!");
434 continue;
435 }
436 float deltaEta(fabs(truth->eta()-ph->caloCluster()->eta()));
437 float deltaPhi(fabs(truth->p4().DeltaPhi(ph->caloCluster()->p4())));
438 if( (isSuperCluster && (deltaEta*deltaEta+deltaPhi*deltaPhi)<Rsize*Rsize ) ||
439 (deltaEta<etasize && deltaPhi<phisize) ) {
440 bool skip(false);
441 for(const auto& truthobj : truthlist) {
442 const xAOD::TruthParticle *truth2 = static_cast<const xAOD::TruthParticle*>(truthobj);
443 if(truth==truth2) { skip = true; break;}
444 }
445 if(!skip) {
446 truthlist.push_back(truth);
447 }
448 }
449 }
450
451 return StatusCode::SUCCESS;
452 }
453
455 std::vector<const xAOD::IParticle*>& truthlist)
456 {
457 const xAOD::Muon* mu = static_cast<const xAOD::Muon*>(obj);
458 const TrackParticle* trk = mu->primaryTrackParticle();
459 const xAOD::TruthParticle* truth(nullptr);
460 if(trk) truth = TruthHelpers::getTruthParticle( *trk );
461 if(truth && truth->isGenStable())
462 truthlist.push_back(truth);
463 return StatusCode::SUCCESS;
464 }
465
467 std::vector<const xAOD::IParticle*>& truthlist) const
468 {
469 const TauJet* tau = static_cast<const TauJet*>(obj);
470 const Jet* seedjet = *tau->jetLink();
471 std::vector<ElementLink<IParticleContainer> > jetconst = cacc_ghosttruth(*seedjet);
472 for(const auto& truth : jetconst) {
473 if(truth) {
474 // TEMP: use jet seed axis
475 // taus will provide an accessor
476 if(!xAOD::P4Helpers::isInDeltaR(*seedjet,**truth,0.2,m_useRapidity)) continue;
477 truthlist.push_back(*truth);
478 }
479 }
480 return StatusCode::SUCCESS;
481 }
482
483 //*********************************************************************************************************
484 // Override fill map method to use the extracted truth particles
485
487 const xAOD::IParticleContainer* hardObjs) const
488 // std::vector<const xAOD::IParticle*>& mutracks)
489 {
490 std::vector<const IParticle*> constlist;
491 constlist.reserve(20);
492 std::vector<const IParticle*> hardObjs_tmp;
493 for(const auto *const obj : *hardObjs) {
494 hardObjs_tmp.push_back(obj);
495 }
496 std::sort(hardObjs_tmp.begin(),hardObjs_tmp.end(),greaterPt);
497
498 for(const auto& obj : hardObjs_tmp) {
499 if(obj->pt()<5e3 && obj->type()!=xAOD::Type::Muon) continue;
500 constlist.clear();
501 ATH_MSG_VERBOSE( "Object type, pt, eta, phi = " << obj->type() << ", " << obj->pt() << ", " << obj->eta() << "," << obj->phi() );
502 ATH_CHECK( this->extractTruthParticles(obj,constlist) );
503
504 // MissingETBase::Types::constvec_t chrgvec;
505 // MissingETBase::Types::constvec_t truthvec;
506
507 for(const auto& truthobj : constlist) {
508 const xAOD::TruthParticle *truth = static_cast<const xAOD::TruthParticle*>(truthobj);
509 ATH_MSG_VERBOSE("Matched truth particle with pt " << truth->pt()
510 << " status " << truth->status()
511 << " pdgId " << truth->pdgId()
512 << " charge " << truth->charge());
513 ATH_MSG_VERBOSE("DeltaR to hard object: " << xAOD::P4Helpers::deltaR(*truth,*obj,m_useRapidity));
514
515 // if(fabs(truth->charge())>1e-9)
516 // chrgvec += MissingETBase::Types::constvec_t(*truth);
517 // if(!truth->isMuon())
518 // truthvec += MissingETBase::Types::constvec_t(*truth);
519 }
520 // ATH_MSG_VERBOSE("Charged truth constvec: sumpt " << chrgvec.sumpt());
521 // ATH_MSG_VERBOSE("Calo truth constvec: sumpt " << truthvec.sumpt());
522
523 MissingETComposition::insert(metMap,obj,constlist);
524 ATH_MSG_VERBOSE("\n\n");
525 }
526 return StatusCode::SUCCESS;
527 }
528
529}
#define ATH_CHECK
Evaluate an expression and check for errors.
#define ATH_MSG_VERBOSE(x)
#define ATH_MSG_WARNING(x)
#define ATH_MSG_DEBUG(x)
DataVector adapter that acts like it holds const pointers.
defines an "iterator" over instances of a given type in StoreGateSvc
ATLAS-specific HepMC functions.
DataVector adapter that acts like it holds const pointers.
value_type push_back(value_type pElem)
Add an element to the end of the collection.
const DV * asDataVector() const
Return a pointer to this object, as a const DataVector.
value_type push_back(value_type pElem)
Add an element to the end of the collection.
size_type size() const noexcept
Returns the number of elements in the collection.
SG::ConstAccessor< T, ALLOC > ConstAccessor
Definition AuxElement.h:569
virtual bool isValid() override final
Can the handle be successfully dereferenced?
const_pointer_type cptr()
Dereference the pointer.
AsgTool(const std::string &name)
Constructor specifying the tool instance's name.
Definition AsgTool.cxx:58
virtual StatusCode initialize() override
Dummy implementation of the initialisation function.
static bool greaterPt(const xAOD::IParticle *part1, const xAOD::IParticle *part2)
METAssociator(const std::string &name)
static StatusCode extractTruthFromMuon(const xAOD::IParticle *obj, std::vector< const xAOD::IParticle * > &truthlist)
SG::ReadHandleKey< xAOD::JetContainer > m_recoJetKey
SG::ReadHandleKey< xAOD::TruthEventContainer > m_truthEventKey
StatusCode extractTruthParticles(const xAOD::IParticle *obj, std::vector< const xAOD::IParticle * > &truthlist) const
SG::ReadHandleKey< xAOD::ElectronContainer > m_recoElKey
StatusCode computeSoftTerms(xAOD::MissingETContainer *metCont, xAOD::MissingETAssociationMap *metMap) const
METTruthAssociator()
Default constructor:
StatusCode initialize()
Dummy implementation of the initialisation function.
StatusCode extractTruthFromElectron(const xAOD::IParticle *obj, std::vector< const xAOD::IParticle * > &truthlist) const
SG::ReadHandleKey< xAOD::TauJetContainer > m_recoTauKey
StatusCode extractTruthFromPhoton(const xAOD::IParticle *obj, std::vector< const xAOD::IParticle * > &truthlist) const
StatusCode executeTool(xAOD::MissingETContainer *metCont, xAOD::MissingETAssociationMap *metMap) const
SG::ReadHandleKey< xAOD::MuonContainer > m_recoMuKey
SG::ReadHandleKey< xAOD::PhotonContainer > m_recoGamKey
StatusCode associateJets(xAOD::MissingETAssociationMap *metMap) const
StatusCode extractTruthFromTau(const xAOD::IParticle *obj, std::vector< const xAOD::IParticle * > &truthlist) const
StatusCode fillAssocMap(xAOD::MissingETAssociationMap *metMap, const xAOD::IParticleContainer *hardObjs) const final
ClusterSize clusterSize() const
Get cluster size.
double getMomentValue(MomentType type) const
Retrieve individual moment - no check for existance! Returns -999 on error.
virtual double eta() const
The pseudorapidity ( ) of the particle.
@ SECOND_R
Second Moment in .
virtual FourMom_t p4() const
The full 4-momentum of the particle.
const xAOD::CaloCluster * caloCluster(size_t index=0) const
Pointer to the xAOD::CaloCluster/s that define the electron candidate.
Class providing the definition of the 4-vector interface.
const IParticleContainer * getUniqueSignals(const IParticleContainer *signals, MissingETBase::UsageHandler::Policy p=MissingETBase::UsageHandler::TrackCluster) const
Extract a container of constituents that are not in jets.
const JetLink_t & jetLink() const
const TruthParticle * truthParticle(size_t index) const
Get a pointer to one of the truth particles.
size_t nTruthParticles() const
Get the number of truth particles.
int status() const
Status code.
int pdgId() const
PDG ID code.
virtual double pt() const override final
The transverse momentum ( ) of the particle.
bool isGenStable() const
Check if this is generator stable particle.
double charge() const
Physical charge.
virtual double eta() const override final
The pseudorapidity ( ) of the particle.
bool isMuon() const
Whether the particle is a muon (or antimuon)
bool isInteracting(const T &p)
Identify if the particle with given PDG ID would not interact with the detector, i....
xAOD::MissingETAssociation_v1::ConstVec constvec_t
Type for constituent vector.
@ VIEW_ELEMENTS
this data object is a view, it does not own its elmts
static const SG::AuxElement::ConstAccessor< std::vector< ElementLink< IParticleContainer > > > cacc_ghosttruth("GhostTruth")
void sort(typename DataModel_detail::iterator< DVL > beg, typename DataModel_detail::iterator< DVL > end)
Specialization of sort for DataVector/List.
@ Photon
The object is a photon.
Definition ObjectType.h:47
@ Muon
The object is a muon.
Definition ObjectType.h:48
@ Electron
The object is an electron.
Definition ObjectType.h:46
@ Tau
The object is a tau (jet)
Definition ObjectType.h:49
bool isInDeltaR(const xAOD::IParticle &p1, const xAOD::IParticle &p2, double dR, bool useRapidity=true)
Check if 2 xAOD::IParticle are in a cone.
double deltaR(double rapidity1, double phi1, double rapidity2, double phi2)
from bare bare rapidity,phi
const xAOD::TruthParticle * getTruthParticle(const xAOD::IParticle &p)
Return the truthParticle associated to the given IParticle (if any)
Jet_v1 Jet
Definition of the current "jet version".
MissingET_v1 MissingET
Version control by type defintion.
setSAddress setEtaMS setDirPhiMS setDirZMS setBarrelRadius setEndcapAlpha setEndcapRadius setInterceptInner setEtaMap setEtaBin setIsTgcFailure setDeltaPt deltaPhi
TrackParticle_v1 TrackParticle
Reference the current persistent version:
TauJet_v3 TauJet
Definition of the current "tau version".
TruthEvent_v1 TruthEvent
Typedef to implementation.
Definition TruthEvent.h:17
TruthParticle_v1 TruthParticle
Typedef to implementation.
Muon_v1 Muon
Reference the current persistent version:
Photon_v1 Photon
Definition of the current "egamma version".
MissingETAssociationMap_v1 MissingETAssociationMap
Version control by type defintion.
Electron_v1 Electron
Definition of the current "egamma version".
DataVector< IParticle > IParticleContainer
Simple convenience declaration of IParticleContainer.
@ Calo
Indicator for MET terms reconstructed from calorimeter signals alone.
@ ID
Indicator for MET terms reconstructed from inner detector (ID) tracks alone.
static Types::bitmask_t truthInt(Region reg=Region::FullAcceptance)
Standard bit pattern indicating effective true MET.
static Types::bitmask_t softEvent(Region reg=Region::FullAcceptance)
Standard MET term from reconstructed soft event.
@ Central
Indicator for MET contribution from the central region.
static bool addMiscAssociation(MissingETAssociationMap *pMap)
Add an association to hold objects not associated to any jet.
static bool insert(MissingETComponentMap *pMap, const MissingET *pMET, const IParticle *pPart, MissingETBase::Types::weight_t weight=MissingETBase::Types::weight_t())
Insert contributing signal or physics object by pointer, with optional kinematic weight object.
static bool add(MissingETComponentMap *pMap, const MissingET *pMET, MissingETBase::Types::bitmask_t sw=MissingETBase::Status::clearedStatus())
Adding a MissingET object to the map.