ATLAS Offline Software
TauxAODHelpers.h
Go to the documentation of this file.
1 // Dear emacs, this is -*- c++ -*-
2 
3 /*
4  Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
5 */
6 
7 // $Id: TauxAODHelpers.h 740338 2016-04-14 16:03:58Z griffith $
8 #ifndef XAOD_TAUXAODHELPERS_H
9 #define XAOD_TAUXAODHELPERS_H
10 
11 //Truth Includes
14 
17 
18 #include "xAODTau/TauJet.h"
20 
21 #include <cstddef>
22 #include <set>
23 #include <vector>
24 
25 namespace xAOD {
26 
27  namespace TauHelpers{
28 
29  // @brief Access to element link to object of type T stored in auxdata
30  template<class T>
31  const T* getLink(const xAOD::IParticle*, const std::string&, bool debug = false);
32 
34  const xAOD::TruthParticle* getTruthParticle(const xAOD::IParticle*, bool debug = false);
35 
36  //means to bypass the tauTrack
37  std::vector< ElementLink< xAOD::TrackParticleContainer > > allTrackParticleLinks(const xAOD::TauJet* tau);
39  std::vector< ElementLink< xAOD::TrackParticleContainer > > trackParticleLinksWithMask(const xAOD::TauJet* tau, xAOD::TauTrack::TrackFlagType mask);
40 
41  //means to get a non-const TauTrack
45  std::vector<xAOD::TauTrack*> tauTracksNonConstWithMask( const xAOD::TauJet* tau, xAOD::TauTrackContainer* trackCont, xAOD::TauTrack::TrackFlagType mask );
46  std::vector<xAOD::TauTrack*> allTauTracksNonConst( const xAOD::TauJet* tau, xAOD::TauTrackContainer* trackCont );
47 
48  //* @brief Obtain the CaloCluster within dRMax of the tau candidate */
49  std::vector<const xAOD::IParticle*> clusters(const xAOD::TauJet& tau, double dRMax);
50 
51  //* @brief Obtain the CaloVertexedTopoCluster within dRMax of the tau candidate */
52  std::vector<xAOD::CaloVertexedTopoCluster> vertexedClusters(const xAOD::TauJet& tau, double dRMax);
53 
54  }// TauHelpers
55 
56 } // namespace xAOD
57 
59 
60 #endif // XAOD_TAUXAODHELPERS_H
xAOD::TauJetParameters::TauTrackFlag
TauTrackFlag
Enum for tau track flags.
Definition: TauDefs.h:400
TauxAODHelpers.icc
xAOD::TauHelpers::tauTrackNonConstWithMask
xAOD::TauTrack * tauTrackNonConstWithMask(const xAOD::TauJet *tau, xAOD::TauTrackContainer *trackCont, int index, xAOD::TauTrack::TrackFlagType mask)
Definition: TauxAODHelpers.cxx:48
xAOD::TauHelpers::trackParticleLinksWithMask
std::vector< ElementLink< xAOD::TrackParticleContainer > > trackParticleLinksWithMask(const xAOD::TauJet *tau, xAOD::TauTrack::TrackFlagType mask)
Definition: TauxAODHelpers.cxx:28
index
Definition: index.py:1
TruthParticleContainer.h
xAOD::TauJetParameters::classifiedCharged
@ classifiedCharged
Definition: TauDefs.h:406
xAOD::TauHelpers::getLink
const T * getLink(const xAOD::IParticle *, const std::string &, bool debug=false)
xAOD
ICaloAffectedTool is abstract interface for tools checking if 4 mom is in calo affected region.
Definition: ICaloAffectedTool.h:24
xAOD::TauHelpers::clusters
std::vector< const xAOD::IParticle * > clusters(const xAOD::TauJet &tau, double dRMax)
Definition: TauxAODHelpers.cxx:93
TauTrackContainer.h
xAOD::IParticle
Class providing the definition of the 4-vector interface.
Definition: Event/xAOD/xAODBase/xAODBase/IParticle.h:41
python.utils.AtlRunQueryLookup.mask
string mask
Definition: AtlRunQueryLookup.py:460
xAOD::TauHelpers::allTauTracksNonConst
std::vector< xAOD::TauTrack * > allTauTracksNonConst(const xAOD::TauJet *tau, xAOD::TauTrackContainer *trackCont)
Definition: TauxAODHelpers.cxx:85
xAOD::TauHelpers::tauTrackNonConst
xAOD::TauTrack * tauTrackNonConst(const xAOD::TauJet *tau, xAOD::TauTrackContainer *trackCont, int index, xAOD::TauJetParameters::TauTrackFlag flag=xAOD::TauJetParameters::TauTrackFlag::classifiedCharged)
Definition: TauxAODHelpers.cxx:41
xAOD::TauHelpers::getTruthParticle
const xAOD::TruthParticle * getTruthParticle(const xAOD::IParticle *, bool debug=false)
return the truthParticle associated to the given IParticle (if any)
Definition: TauxAODHelpers.cxx:10
xAOD::TauHelpers::allTrackParticleLinks
std::vector< ElementLink< xAOD::TrackParticleContainer > > allTrackParticleLinks(const xAOD::TauJet *tau)
Definition: TauxAODHelpers.cxx:16
xAOD::TruthParticle_v1
Class describing a truth particle in the MC record.
Definition: TruthParticle_v1.h:37
xAOD::TauJet_v3
Class describing a tau jet.
Definition: TauJet_v3.h:41
master.flag
bool flag
Definition: master.py:29
xAOD::TauHelpers::trackParticleLinks
std::vector< ElementLink< xAOD::TrackParticleContainer > > trackParticleLinks(const xAOD::TauJet *tau, xAOD::TauJetParameters::TauTrackFlag flag=xAOD::TauJetParameters::TauTrackFlag::classifiedCharged)
Definition: TauxAODHelpers.cxx:22
DataVector
Derived DataVector<T>.
Definition: DataVector.h:581
debug
const bool debug
Definition: MakeUncertaintyPlots.cxx:53
xAOD::TauTrack_v1::TrackFlagType
uint16_t TrackFlagType
Definition: TauTrack_v1.h:61
xAOD::TauHelpers::tauTracksNonConst
std::vector< xAOD::TauTrack * > tauTracksNonConst(const xAOD::TauJet *tau, xAOD::TauTrackContainer *trackCont, xAOD::TauJetParameters::TauTrackFlag flag=xAOD::TauJetParameters::TauTrackFlag::classifiedCharged)
Definition: TauxAODHelpers.cxx:70
xAOD::TauHelpers::tauTracksNonConstWithMask
std::vector< xAOD::TauTrack * > tauTracksNonConstWithMask(const xAOD::TauJet *tau, xAOD::TauTrackContainer *trackCont, xAOD::TauTrack::TrackFlagType mask)
Definition: TauxAODHelpers.cxx:76
TrackParticle.h
xAOD::TauTrack_v1
Definition: TauTrack_v1.h:27
TauJet.h
TruthParticle.h
TrackParticleContainer.h
xAOD::TauHelpers::vertexedClusters
std::vector< xAOD::CaloVertexedTopoCluster > vertexedClusters(const xAOD::TauJet &tau, double dRMax)
Definition: TauxAODHelpers.cxx:108