ATLAS Offline Software
InDetPerfNtuple_TruthToReco.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2021 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef INDET__PERF__NTUPLE_TRUTHTORECO__H
6 #define INDET__PERF__NTUPLE_TRUTHTORECO__H
7 
8 #include "InDetPerfNtuple.h"
11 #include "xAODTracking/Vertex.h"
12 #include <cmath> // std::isnan()
13 
15 public:
16  InDetPerfNtuple_TruthToReco(InDetPlotBase* pParent, const std::string& dirName, const std::string & treeName);
17 
18  void fillTree();
19  void fillTrack(const xAOD::TrackParticle& track, const xAOD::Vertex* vtx, const int truthMatchRanking = -1);
20  void fillTruth(const xAOD::TruthParticle& truth);
21 
25 
26 private:
27  const float m_undefinedValue{-9999};
28 
30 
31  //Truth variables
45 
46  //Track variables
61 
62  //Track fit errors
71 
72  //More track variables
75 
76  //Track summary variables
120 
121  //Flags
126 };
127 
128 #endif // INDET__PERF__NTUPLE_TRUTHTORECO__H
InDetPerfNtuple_TruthToReco::m_expectInnermostPixelLayerHit
InDetPerfNtupleBranch< int > m_expectInnermostPixelLayerHit
Definition: InDetPerfNtuple_TruthToReco.h:83
InDetPerfNtuple_TruthToReco::m_track_theta
InDetPerfNtupleBranch< float > m_track_theta
Definition: InDetPerfNtuple_TruthToReco.h:56
InDetPerfNtuple_TruthToReco::m_track_qOverP
InDetPerfNtupleBranch< float > m_track_qOverP
Definition: InDetPerfNtuple_TruthToReco.h:57
InDetPerfNtuple_TruthToReco
Definition: InDetPerfNtuple_TruthToReco.h:14
InDetPerfNtuple
This class is a base class for the actual ntuples used when writing IDPVM ntuples.
Definition: InDetPerfNtuple.h:11
InDetPerfNtuple_TruthToReco::m_track_nDoF
InDetPerfNtupleBranch< float > m_track_nDoF
Definition: InDetPerfNtuple_TruthToReco.h:74
InDetPerfNtuple_TruthToReco::m_undefinedValue
const float m_undefinedValue
Definition: InDetPerfNtuple_TruthToReco.h:27
InDetPerfNtuple_TruthToReco::fillTrackSummaryInfo
void fillTrackSummaryInfo(const xAOD::TrackParticle &track)
Definition: InDetPerfNtuple_TruthToReco.cxx:187
SG::Accessor
Helper class to provide type-safe access to aux data.
Definition: Control/AthContainers/AthContainers/Accessor.h:68
InDetPerfNtuple_TruthToReco::m_numberOfPixelSharedHits
InDetPerfNtupleBranch< int > m_numberOfPixelSharedHits
Definition: InDetPerfNtuple_TruthToReco.h:96
InDetPerfNtuple_TruthToReco::m_numberOfBLayerOutliers
InDetPerfNtupleBranch< int > m_numberOfBLayerOutliers
Definition: InDetPerfNtuple_TruthToReco.h:79
InDetPerfNtuple_TruthToReco::m_numberOfPixelHits
InDetPerfNtupleBranch< int > m_numberOfPixelHits
Definition: InDetPerfNtuple_TruthToReco.h:93
InDetPerfNtuple_TruthToReco::m_track_phi
InDetPerfNtupleBranch< float > m_track_phi
Definition: InDetPerfNtuple_TruthToReco.h:55
InDetPerfNtuple_TruthToReco::m_track_truthMatchProb
InDetPerfNtupleBranch< float > m_track_truthMatchProb
Definition: InDetPerfNtuple_TruthToReco.h:49
InDetPerfNtuple_TruthToReco::m_track_truthMatchRanking
InDetPerfNtupleBranch< int > m_track_truthMatchRanking
Definition: InDetPerfNtuple_TruthToReco.h:48
InDetPerfNtuple_TruthToReco::fillTrack
void fillTrack(const xAOD::TrackParticle &track, const xAOD::Vertex *vtx, const int truthMatchRanking=-1)
Definition: InDetPerfNtuple_TruthToReco.cxx:122
InDetPerfNtuple_TruthToReco::m_numberOfGangedFlaggedFakes
InDetPerfNtupleBranch< int > m_numberOfGangedFlaggedFakes
Definition: InDetPerfNtuple_TruthToReco.h:99
InDetPerfNtuple_TruthToReco::m_numberOfTRTHighThresholdHits
InDetPerfNtupleBranch< int > m_numberOfTRTHighThresholdHits
Definition: InDetPerfNtuple_TruthToReco.h:112
InDetPerfNtuple_TruthToReco::m_numberOfNextToInnermostPixelLayerHits
InDetPerfNtupleBranch< int > m_numberOfNextToInnermostPixelLayerHits
Definition: InDetPerfNtuple_TruthToReco.h:89
InDetPerfNtuple_TruthToReco::m_numberOfBLayerHits
InDetPerfNtupleBranch< int > m_numberOfBLayerHits
Definition: InDetPerfNtuple_TruthToReco.h:78
InDetPerfNtuple_TruthToReco::m_hasTrack
InDetPerfNtupleBranch< int > m_hasTrack
Definition: InDetPerfNtuple_TruthToReco.h:123
InDetPerfNtuple_TruthToReco::m_trackErr_d0
InDetPerfNtupleBranch< float > m_trackErr_d0
Definition: InDetPerfNtuple_TruthToReco.h:64
InDetPerfNtuple_TruthToReco::m_truth_theta
InDetPerfNtupleBranch< float > m_truth_theta
Definition: InDetPerfNtuple_TruthToReco.h:41
InDetPerfNtuple_TruthToReco::m_truth_z0sin
InDetPerfNtupleBranch< float > m_truth_z0sin
Definition: InDetPerfNtuple_TruthToReco.h:44
InDetPerfNtuple_TruthToReco::m_numberOfNextToInnermostPixelLayerOutliers
InDetPerfNtupleBranch< int > m_numberOfNextToInnermostPixelLayerOutliers
Definition: InDetPerfNtuple_TruthToReco.h:90
InDetPerfNtuple_TruthToReco::m_truth_pt
InDetPerfNtupleBranch< float > m_truth_pt
Definition: InDetPerfNtuple_TruthToReco.h:37
InDetPerfNtuple_TruthToReco::m_trackErr_z0
InDetPerfNtupleBranch< float > m_trackErr_z0
Definition: InDetPerfNtuple_TruthToReco.h:65
InDetPerfNtuple_TruthToReco::m_track_patternInfo
InDetPerfNtupleBranch< unsigned long > m_track_patternInfo
Definition: InDetPerfNtuple_TruthToReco.h:47
InDetPerfNtuple_TruthToReco::m_track_z0sin
InDetPerfNtupleBranch< float > m_track_z0sin
Definition: InDetPerfNtuple_TruthToReco.h:59
InDetPerfNtuple_TruthToReco::m_numberOfTRTHighThresholdHitsTotal
InDetPerfNtupleBranch< int > m_numberOfTRTHighThresholdHitsTotal
Definition: InDetPerfNtuple_TruthToReco.h:113
InDetPerfNtuple_TruthToReco::m_numberOfTRTHighThresholdOutliers
InDetPerfNtupleBranch< int > m_numberOfTRTHighThresholdOutliers
Definition: InDetPerfNtuple_TruthToReco.h:114
InDetPerfNtuple_TruthToReco::m_numberOfPixelDeadSensors
InDetPerfNtupleBranch< int > m_numberOfPixelDeadSensors
Definition: InDetPerfNtuple_TruthToReco.h:100
InDetPerfNtuple_TruthToReco::m_numberOfBLayerSplitHits
InDetPerfNtupleBranch< int > m_numberOfBLayerSplitHits
Definition: InDetPerfNtuple_TruthToReco.h:81
InDetPerfNtuple_TruthToReco::m_truth_eta
InDetPerfNtupleBranch< float > m_truth_eta
Definition: InDetPerfNtuple_TruthToReco.h:36
InDetPerfNtuple_TruthToReco::m_numberOfSCTDeadSensors
InDetPerfNtupleBranch< int > m_numberOfSCTDeadSensors
Definition: InDetPerfNtuple_TruthToReco.h:107
InDetPlotBase
Mixin class to give extra capabilities to plots such as ATH_MSG and an easier booking interface,...
Definition: InDetPlotBase.h:33
InDetPerfNtuple_TruthToReco::m_numberOfSCTSpoiltHits
InDetPerfNtupleBranch< int > m_numberOfSCTSpoiltHits
Definition: InDetPerfNtuple_TruthToReco.h:108
InDetPerfNtuple_TruthToReco::m_numberOfSCTDoubleHoles
InDetPerfNtupleBranch< int > m_numberOfSCTDoubleHoles
Definition: InDetPerfNtuple_TruthToReco.h:105
InDetPerfNtuple_TruthToReco::m_truth_qOverP
InDetPerfNtupleBranch< float > m_truth_qOverP
Definition: InDetPerfNtuple_TruthToReco.h:42
InDetPerfNtuple_TruthToReco::m_acc_selectedByPileupSwitch
SG::AuxElement::Accessor< bool > m_acc_selectedByPileupSwitch
Definition: InDetPerfNtuple_TruthToReco.h:24
InDetPerfNtuple_TruthToReco::m_numberOfInnermostPixelLayerSharedHits
InDetPerfNtupleBranch< int > m_numberOfInnermostPixelLayerSharedHits
Definition: InDetPerfNtuple_TruthToReco.h:86
InDetPerfNtuple_TruthToReco::m_numberOfTRTDeadStraws
InDetPerfNtupleBranch< int > m_numberOfTRTDeadStraws
Definition: InDetPerfNtuple_TruthToReco.h:115
InDetPerfNtuple_TruthToReco::m_numberOfInnermostPixelLayerOutliers
InDetPerfNtupleBranch< int > m_numberOfInnermostPixelLayerOutliers
Definition: InDetPerfNtuple_TruthToReco.h:85
xAOD::TruthParticle_v1
Class describing a truth particle in the MC record.
Definition: TruthParticle_v1.h:37
InDetPerfNtuple_TruthToReco::m_numberOfNextToInnermostPixelLayerSplitHits
InDetPerfNtupleBranch< int > m_numberOfNextToInnermostPixelLayerSplitHits
Definition: InDetPerfNtuple_TruthToReco.h:92
InDetPerfNtuple_TruthToReco::m_numberOfGangedPixels
InDetPerfNtupleBranch< int > m_numberOfGangedPixels
Definition: InDetPerfNtuple_TruthToReco.h:98
InDetPerfNtuple_TruthToReco::m_numberOfSCTOutliers
InDetPerfNtupleBranch< int > m_numberOfSCTOutliers
Definition: InDetPerfNtuple_TruthToReco.h:103
InDetPerfNtuple_TruthToReco::m_truth_z0
InDetPerfNtupleBranch< float > m_truth_z0
Definition: InDetPerfNtuple_TruthToReco.h:39
InDetPerfNtuple_TruthToReco::m_numberOfPixelHoles
InDetPerfNtupleBranch< int > m_numberOfPixelHoles
Definition: InDetPerfNtuple_TruthToReco.h:95
dumpFileToPlots.treeName
string treeName
Definition: dumpFileToPlots.py:20
InDetPerfNtuple_TruthToReco::fillTruth
void fillTruth(const xAOD::TruthParticle &truth)
Definition: InDetPerfNtuple_TruthToReco.cxx:97
InDetPerfNtuple_TruthToReco::m_truth_phi
InDetPerfNtupleBranch< float > m_truth_phi
Definition: InDetPerfNtuple_TruthToReco.h:40
Vertex.h
InDetPerfNtuple_TruthToReco::m_numberOfSCTHoles
InDetPerfNtupleBranch< int > m_numberOfSCTHoles
Definition: InDetPerfNtuple_TruthToReco.h:104
InDetPerfNtuple_TruthToReco::m_track_eta
InDetPerfNtupleBranch< float > m_track_eta
Definition: InDetPerfNtuple_TruthToReco.h:51
InDetPerfNtuple_TruthToReco::m_pixeldEdx
InDetPerfNtupleBranch< float > m_pixeldEdx
Definition: InDetPerfNtuple_TruthToReco.h:119
InDetPerfNtuple_TruthToReco::m_track_pt
InDetPerfNtupleBranch< float > m_track_pt
Definition: InDetPerfNtuple_TruthToReco.h:52
InDetPerfNtuple_TruthToReco::m_trackErr_z0sin
InDetPerfNtupleBranch< float > m_trackErr_z0sin
Definition: InDetPerfNtuple_TruthToReco.h:70
InDetPerfNtuple_TruthToReco::m_hasTruth
InDetPerfNtupleBranch< int > m_hasTruth
Definition: InDetPerfNtuple_TruthToReco.h:122
InDetPerfNtuple_TruthToReco::m_numberOfContribPixelLayers
InDetPerfNtupleBranch< int > m_numberOfContribPixelLayers
Definition: InDetPerfNtuple_TruthToReco.h:77
InDetPerfNtuple_TruthToReco::m_truth_selectedByPileupSwitch
InDetPerfNtupleBranch< int > m_truth_selectedByPileupSwitch
Definition: InDetPerfNtuple_TruthToReco.h:32
InDetPerfNtuple_TruthToReco::m_numberOfInnermostPixelLayerHits
InDetPerfNtupleBranch< int > m_numberOfInnermostPixelLayerHits
Definition: InDetPerfNtuple_TruthToReco.h:84
InDetPerfNtuple_TruthToReco::m_track_z0sin_wrt_primvtx
InDetPerfNtupleBranch< float > m_track_z0sin_wrt_primvtx
Definition: InDetPerfNtuple_TruthToReco.h:60
InDetPerfNtuple_TruthToReco::m_track_chiSquared
InDetPerfNtupleBranch< float > m_track_chiSquared
Definition: InDetPerfNtuple_TruthToReco.h:73
InDetPerfNtuple_TruthToReco::m_truth_d0
InDetPerfNtupleBranch< float > m_truth_d0
Definition: InDetPerfNtuple_TruthToReco.h:38
InDetPerfNtuple_TruthToReco::m_numberOfSCTHits
InDetPerfNtupleBranch< int > m_numberOfSCTHits
Definition: InDetPerfNtuple_TruthToReco.h:102
InDetPerfNtuple_TruthToReco::m_numberOfSCTSharedHits
InDetPerfNtupleBranch< int > m_numberOfSCTSharedHits
Definition: InDetPerfNtuple_TruthToReco.h:106
InDetPerfNtuple_TruthToReco::m_trackErr_qOverP
InDetPerfNtupleBranch< float > m_trackErr_qOverP
Definition: InDetPerfNtuple_TruthToReco.h:68
InDetPerfNtuple_TruthToReco::m_track_qOverPt
InDetPerfNtupleBranch< float > m_track_qOverPt
Definition: InDetPerfNtuple_TruthToReco.h:58
InDetPerfNtuple_TruthToReco::m_numberOfPixelOutliers
InDetPerfNtupleBranch< int > m_numberOfPixelOutliers
Definition: InDetPerfNtuple_TruthToReco.h:94
InDetPerfNtuple_TruthToReco::m_passedTrackSelection
InDetPerfNtupleBranch< int > m_passedTrackSelection
Definition: InDetPerfNtuple_TruthToReco.h:125
InDetPerfNtuple_TruthToReco::m_numberOfTRTSharedHits
InDetPerfNtupleBranch< int > m_numberOfTRTSharedHits
Definition: InDetPerfNtuple_TruthToReco.h:118
InDetPerfNtuple_TruthToReco::m_trackErr_phi
InDetPerfNtupleBranch< float > m_trackErr_phi
Definition: InDetPerfNtuple_TruthToReco.h:66
InDetPerfNtuple_TruthToReco::InDetPerfNtuple_TruthToReco
InDetPerfNtuple_TruthToReco(InDetPlotBase *pParent, const std::string &dirName, const std::string &treeName)
Definition: InDetPerfNtuple_TruthToReco.cxx:9
InDetPerfNtuple_TruthToReco::m_numberOfBLayerSharedHits
InDetPerfNtupleBranch< int > m_numberOfBLayerSharedHits
Definition: InDetPerfNtuple_TruthToReco.h:80
InDetPerfNtuple_TruthToReco::m_acc_passedTrackSelection
SG::AuxElement::Accessor< bool > m_acc_passedTrackSelection
Definition: InDetPerfNtuple_TruthToReco.h:23
InDetPerfNtuple_TruthToReco::m_numberOfTRTTubeHits
InDetPerfNtupleBranch< int > m_numberOfTRTTubeHits
Definition: InDetPerfNtuple_TruthToReco.h:116
InDetPerfNtuple_TruthToReco::m_numberOfPixelSplitHits
InDetPerfNtupleBranch< int > m_numberOfPixelSplitHits
Definition: InDetPerfNtuple_TruthToReco.h:97
InDetPerfNtuple_TruthToReco::m_expectNextToInnermostPixelLayerHit
InDetPerfNtupleBranch< int > m_expectNextToInnermostPixelLayerHit
Definition: InDetPerfNtuple_TruthToReco.h:88
xAOD::Vertex_v1
Class describing a Vertex.
Definition: Vertex_v1.h:42
InDetPerfNtuple_TruthToReco::m_numberOfTRTHoles
InDetPerfNtupleBranch< int > m_numberOfTRTHoles
Definition: InDetPerfNtuple_TruthToReco.h:111
InDetPerfNtupleBranch< int >
InDetPerfNtuple.h
InDetPerfNtuple_TruthToReco::m_truth_charge
InDetPerfNtupleBranch< float > m_truth_charge
Definition: InDetPerfNtuple_TruthToReco.h:35
InDetPerfNtuple_TruthToReco::m_numberOfTRTHits
InDetPerfNtupleBranch< int > m_numberOfTRTHits
Definition: InDetPerfNtuple_TruthToReco.h:109
InDetPerfNtuple_TruthToReco::m_numberOfInnermostPixelLayerSplitHits
InDetPerfNtupleBranch< int > m_numberOfInnermostPixelLayerSplitHits
Definition: InDetPerfNtuple_TruthToReco.h:87
InDetPerfNtuple_TruthToReco::m_track_d0
InDetPerfNtupleBranch< float > m_track_d0
Definition: InDetPerfNtuple_TruthToReco.h:53
InDetPerfNtuple_TruthToReco::m_truth_barcode
InDetPerfNtupleBranch< int > m_truth_barcode
Definition: InDetPerfNtuple_TruthToReco.h:34
InDetPerfNtuple_TruthToReco::m_trackErr_pt
InDetPerfNtupleBranch< float > m_trackErr_pt
Definition: InDetPerfNtuple_TruthToReco.h:63
InDetPerfNtuple_TruthToReco::m_passedTruthSelection
InDetPerfNtupleBranch< int > m_passedTruthSelection
Definition: InDetPerfNtuple_TruthToReco.h:124
xAOD::track
@ track
Definition: TrackingPrimitives.h:512
xAOD::TrackParticle_v1
Class describing a TrackParticle.
Definition: TrackParticle_v1.h:43
InDetPerfNtuple_TruthToReco::m_trackErr_theta
InDetPerfNtupleBranch< float > m_trackErr_theta
Definition: InDetPerfNtuple_TruthToReco.h:67
InDetPerfNtuple_TruthToReco::m_trackErr_qOverPt
InDetPerfNtupleBranch< float > m_trackErr_qOverPt
Definition: InDetPerfNtuple_TruthToReco.h:69
InDetPerfNtuple_TruthToReco::m_numberOfTRTOutliers
InDetPerfNtupleBranch< int > m_numberOfTRTOutliers
Definition: InDetPerfNtuple_TruthToReco.h:110
InDetPerfNtuple_TruthToReco::m_numberOfPixelSpoiltHits
InDetPerfNtupleBranch< int > m_numberOfPixelSpoiltHits
Definition: InDetPerfNtuple_TruthToReco.h:101
InDetPerfNtuple_TruthToReco::fillTree
void fillTree()
Definition: InDetPerfNtuple_TruthToReco.cxx:322
TruthParticle.h
InDetPerfNtuple_TruthToReco::m_truth_pdgId
InDetPerfNtupleBranch< int > m_truth_pdgId
Definition: InDetPerfNtuple_TruthToReco.h:33
InDetPerfNtuple_TruthToReco::m_expectBLayerHit
InDetPerfNtupleBranch< int > m_expectBLayerHit
Definition: InDetPerfNtuple_TruthToReco.h:82
InDetPerfNtuple_TruthToReco::m_truth_qOverPt
InDetPerfNtupleBranch< float > m_truth_qOverPt
Definition: InDetPerfNtuple_TruthToReco.h:43
InDetPerfNtuple_TruthToReco::m_numberOfNextToInnermostPixelLayerSharedHits
InDetPerfNtupleBranch< int > m_numberOfNextToInnermostPixelLayerSharedHits
Definition: InDetPerfNtuple_TruthToReco.h:91
TrackParticleContainer.h
InDetPerfNtuple_TruthToReco::m_numberOfTRTXenonHits
InDetPerfNtupleBranch< int > m_numberOfTRTXenonHits
Definition: InDetPerfNtuple_TruthToReco.h:117
InDetPerfNtuple_TruthToReco::m_track_charge
InDetPerfNtupleBranch< float > m_track_charge
Definition: InDetPerfNtuple_TruthToReco.h:50
InDetPerfNtuple_TruthToReco::m_track_z0
InDetPerfNtupleBranch< float > m_track_z0
Definition: InDetPerfNtuple_TruthToReco.h:54
InDetPerfNtuple_TruthToReco::m_acc_passedTruthSelection
SG::AuxElement::Accessor< bool > m_acc_passedTruthSelection
Definition: InDetPerfNtuple_TruthToReco.h:22