ATLAS Offline Software
TrackStateOnSurfaceDecorator.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3 */
4 
6 // TrackToVertexWrapper.h, (c) ATLAS Detector software
8 
9 #ifndef DERIVATIONFRAMEWORK_TRACKSTATEONSURFACEDECORATOR_H
10 #define DERIVATIONFRAMEWORK_TRACKSTATEONSURFACEDECORATOR_H
11 
12 #include <string>
13 #include <vector>
14 
17 #include "GaudiKernel/ToolHandle.h"
18 #include "AthLinks/ElementLink.h"
32 
37 
39 
41 
42 class AtlasDetectorID;
43 class PixelID;
44 class SCT_ID;
45 class TRT_ID;
46 
47 namespace Trk {
48  class IUpdator;
49  class PrepRawData;
50 }
51 
52 namespace DerivationFramework {
53 
54  class TrackStateOnSurfaceDecorator : public extends<ExpressionParserUser<AthAlgTool>, IAugmentationTool> {
55  public:
56  using base_class::base_class;
57 
60  virtual StatusCode addBranches() const;
61 
62  private:
63 
64 
66  const std::vector<unsigned int>*,
68 
69  // --- Steering and configuration flags
70  Gaudi::Property<bool> m_storeHoles{this, "StoreHoles", true};
71  Gaudi::Property<bool> m_storeOutliers{this, "StoreOutliers", true};
72  Gaudi::Property<bool> m_storeTRT{this, "StoreTRT", false};
73  Gaudi::Property<bool> m_storeSCT{this, "StoreSCT", true};
74  Gaudi::Property<bool> m_storePixel{this, "StorePixel", true};
75  Gaudi::Property<bool> m_addPulls{this, "AddPulls", true};
76  Gaudi::Property<bool> m_addSurfaceInfo{this, "AddSurfaceInfo", true};
77  Gaudi::Property<bool> m_addPRD{this, "AddPRD", true};
78  Gaudi::Property<bool> m_addExtraEventInfo{this, "AddExtraEventInfo", true};
79 
80  // --- Configuration keys
82  { this, "EventInfoKey", "EventInfo", "" };
83  Gaudi::Property<std::string> m_sgName
84  { this, "DecorationPrefix", "IDDET1_",""};
86  { this, "ContainerName", "InDetTrackParticles", "" };
88  { this,"TRTPhaseKey","TRT_Phase", ""};
89  StringProperty m_selectionString
90  { this, "SelectionString", "", "track selections"};
91 
93  { this, "PixelMapName", "PixelClustersOffsets" , ""};
95  { this, "SctMapName", "SCT_ClustersOffsets" , ""};
97  { this, "TrtMapName", "TRT_DriftCirclesOffsets" , ""};
98 
100  {this, "PixelClustersName", "PixelClusters" ,"" };
102  {this, "SctClustersName", "SCT_Clusters" ,"" };
104  {this, "TrtDriftCirclesName", "TRT_DriftCircles" ,"" };
105 
107  { this,"PRDtoTrackMap","","option PRD-to-track association"};
108 
110  { this, "PixelMsosName", "PixelMSOSs", "" };
112  { this, "SctMsosName", "SCT_MSOSs", "" };
114  { this, "TrtMsosName", "TRT_MSOSs", ""};
115 
116 
117  // --- Read Cond Handle Key
118  // For P->T converter of SCT_Clusters
119  SG::ReadCondHandleKey<InDetDD::SiDetectorElementCollection> m_SCTDetEleCollKey{this, "SCTDetEleCollKey", "SCT_DetectorElementCollection", "Key of SiDetectorElementCollection for SCT"};
120 
121 
122  // --- Services and tools
123  const AtlasDetectorID* m_idHelper = nullptr;
124  const PixelID* m_pixId = nullptr;
125  const SCT_ID* m_sctId = nullptr;
126  const TRT_ID* m_trtId = nullptr;
127 
128  ToolHandle<Trk::IUpdator> m_updator {this, "Updator", "Trk::KalmanUpdator"};
129  ToolHandle<Trk::IResidualPullCalculator> m_residualPullCalculator
130  {this, "ResidualPullCalculator",
131  "Trk::ResidualPullCalculator/ResidualPullCalculator"};
132  ToolHandle<Trk::ITrackHoleSearchTool> m_holeSearchTool
133  {this, "HoleSearch", "InDet::InDetTrackHoleSearchTool/InDetHoleSearchTool"};
134  ToolHandle<Trk::IExtrapolator> m_extrapolator
135  {this, "TrackExtrapolator", "Trk::Extrapolator/AtlasExtrapolator"};
136  ToolHandle<ITRT_CalDbTool> m_trtcaldbTool {this, "TRT_CalDbTool", "TRT_CalDbTool"};
137  ToolHandle<ITRT_ToT_dEdx> m_TRTdEdxTool
138  {this, "TRT_ToT_dEdx", "InDet::TRT_ElectronPidTools/TRT_ToT_dEdx"};
139 
140  // --- Private other members
141  std::vector<SG::WriteDecorHandleKey<xAOD::EventInfo> > m_trtPhaseDecorKey;
147  std::vector<SG::WriteDecorHandleKey<xAOD::TrackParticleContainer> > m_trackTRTFloatDecorKeys;
153  std::vector<SG::WriteDecorHandleKey<xAOD::TrackParticleContainer> > m_trackPixFloatDecorKeys;
155  Gaudi::Property< std::vector<float> > m_pixelLayerRadii {this, "PixelLayerRadii", {29.5,50.5,88.5,122.5}, "Radii to extrapolate to for estimating track position on layers" };
156 
157 
158  };
159 }
160 
161 #endif // DERIVATIONFRAMEWORK_TRACKSTATEONSURFACEDECORATOR_H
ReadHandleKey.h
Property holding a SG store/key/clid from which a ReadHandle is made.
DerivationFramework::TrackStateOnSurfaceDecorator::m_residualPullCalculator
ToolHandle< Trk::IResidualPullCalculator > m_residualPullCalculator
Definition: TrackStateOnSurfaceDecorator.h:130
SG::WriteDecorHandleKey< xAOD::TrackParticleContainer >
PRDtoTrackMap.h
DerivationFramework::TrackStateOnSurfaceDecorator::kNPixFloatDecor
@ kNPixFloatDecor
Definition: TrackStateOnSurfaceDecorator.h:152
DerivationFramework::TrackStateOnSurfaceDecorator::addBranches
virtual StatusCode addBranches() const
Definition: TrackStateOnSurfaceDecorator.cxx:183
DerivationFramework::TrackStateOnSurfaceDecorator::kTrkIBLYDecor
@ kTrkIBLYDecor
Definition: TrackStateOnSurfaceDecorator.h:148
DerivationFramework::TrackStateOnSurfaceDecorator::m_pixelMapName
SG::ReadHandleKey< std::vector< unsigned int > > m_pixelMapName
Definition: TrackStateOnSurfaceDecorator.h:93
DerivationFramework::TrackStateOnSurfaceDecorator::kTRTusedHitsDecor
@ kTRTusedHitsDecor
Definition: TrackStateOnSurfaceDecorator.h:143
DerivationFramework::TrackStateOnSurfaceDecorator::kTRTdEdx_noHT_divByLDecor
@ kTRTdEdx_noHT_divByLDecor
Definition: TrackStateOnSurfaceDecorator.h:144
ComTime.h
IAugmentationTool.h
ExpressionParserUser.h
DerivationFramework::TrackStateOnSurfaceDecorator::m_trtPhaseKey
SG::ReadHandleKey< ComTime > m_trtPhaseKey
Definition: TrackStateOnSurfaceDecorator.h:88
DerivationFramework::TrackStateOnSurfaceDecorator::m_trtMapName
SG::ReadHandleKey< std::vector< unsigned int > > m_trtMapName
Definition: TrackStateOnSurfaceDecorator.h:97
DerivationFramework::TrackStateOnSurfaceDecorator::m_storeOutliers
Gaudi::Property< bool > m_storeOutliers
Definition: TrackStateOnSurfaceDecorator.h:71
DerivationFramework::TrackStateOnSurfaceDecorator::m_storeHoles
Gaudi::Property< bool > m_storeHoles
Definition: TrackStateOnSurfaceDecorator.h:70
DerivationFramework::TrackStateOnSurfaceDecorator::kTrkL2XDecor
@ kTrkL2XDecor
Definition: TrackStateOnSurfaceDecorator.h:151
IExtrapolator.h
DerivationFramework::TrackStateOnSurfaceDecorator::m_trtcaldbTool
ToolHandle< ITRT_CalDbTool > m_trtcaldbTool
Definition: TrackStateOnSurfaceDecorator.h:136
DerivationFramework::TrackStateOnSurfaceDecorator::m_addPulls
Gaudi::Property< bool > m_addPulls
Definition: TrackStateOnSurfaceDecorator.h:75
DerivationFramework::TrackStateOnSurfaceDecorator::m_extrapolator
ToolHandle< Trk::IExtrapolator > m_extrapolator
Definition: TrackStateOnSurfaceDecorator.h:135
DerivationFramework::TrackStateOnSurfaceDecorator::m_sctClustersName
SG::ReadHandleKey< xAOD::TrackMeasurementValidationContainer > m_sctClustersName
Definition: TrackStateOnSurfaceDecorator.h:102
DerivationFramework::TrackStateOnSurfaceDecorator::buildElementLink
ElementLink< xAOD::TrackMeasurementValidationContainer > buildElementLink(const Trk::PrepRawData *, const std::vector< unsigned int > *, const xAOD::TrackMeasurementValidationContainer *) const
Definition: TrackStateOnSurfaceDecorator.cxx:844
SG::ReadHandleKey< xAOD::EventInfo >
DerivationFramework::TrackStateOnSurfaceDecorator::m_trtId
const TRT_ID * m_trtId
Definition: TrackStateOnSurfaceDecorator.h:126
ITRT_ToT_dEdx.h
DerivationFramework::TrackStateOnSurfaceDecorator::kTrkL1XDecor
@ kTrkL1XDecor
Definition: TrackStateOnSurfaceDecorator.h:150
DerivationFramework::TrackStateOnSurfaceDecorator::m_sctMapName
SG::ReadHandleKey< std::vector< unsigned int > > m_sctMapName
Definition: TrackStateOnSurfaceDecorator.h:95
DerivationFramework::TrackStateOnSurfaceDecorator::kTrkL2ZDecor
@ kTrkL2ZDecor
Definition: TrackStateOnSurfaceDecorator.h:151
IUpdator.h
DerivationFramework::TrackStateOnSurfaceDecorator::m_addSurfaceInfo
Gaudi::Property< bool > m_addSurfaceInfo
Definition: TrackStateOnSurfaceDecorator.h:76
DerivationFramework::TrackStateOnSurfaceDecorator::m_idHelper
const AtlasDetectorID * m_idHelper
Definition: TrackStateOnSurfaceDecorator.h:123
DerivationFramework::TrackStateOnSurfaceDecorator::m_sctMsosName
SG::WriteHandleKey< xAOD::TrackStateValidationContainer > m_sctMsosName
Definition: TrackStateOnSurfaceDecorator.h:112
DerivationFramework::TrackStateOnSurfaceDecorator::kNTRTFloatDecor
@ kNTRTFloatDecor
Definition: TrackStateOnSurfaceDecorator.h:146
DerivationFramework::TrackStateOnSurfaceDecorator::m_prdToTrackMap
SG::ReadHandleKey< Trk::PRDtoTrackMap > m_prdToTrackMap
Definition: TrackStateOnSurfaceDecorator.h:107
DerivationFramework::TrackStateOnSurfaceDecorator::kTRTusedHits_noHT_divByLDecor
@ kTRTusedHits_noHT_divByLDecor
Definition: TrackStateOnSurfaceDecorator.h:145
DerivationFramework::TrackStateOnSurfaceDecorator::kTrkBLYDecor
@ kTrkBLYDecor
Definition: TrackStateOnSurfaceDecorator.h:149
SG::WriteHandleKey
Property holding a SG store/key/clid from which a WriteHandle is made.
Definition: StoreGate/StoreGate/WriteHandleKey.h:40
DerivationFramework::TrackStateOnSurfaceDecorator::m_storeTRT
Gaudi::Property< bool > m_storeTRT
Definition: TrackStateOnSurfaceDecorator.h:72
WriteDecorHandleKey.h
Property holding a SG store/key/clid/attr name from which a WriteDecorHandle is made.
DerivationFramework::TrackStateOnSurfaceDecorator::kTrkBLZDecor
@ kTrkBLZDecor
Definition: TrackStateOnSurfaceDecorator.h:149
DerivationFramework::TrackStateOnSurfaceDecorator::kTrkL1ZDecor
@ kTrkL1ZDecor
Definition: TrackStateOnSurfaceDecorator.h:150
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
AthAlgTool.h
DerivationFramework::TrackStateOnSurfaceDecorator::kTrkBLXDecor
@ kTrkBLXDecor
Definition: TrackStateOnSurfaceDecorator.h:149
WriteDecorHandle.h
Handle class for adding a decoration to an object.
DerivationFramework::TrackStateOnSurfaceDecorator::m_storePixel
Gaudi::Property< bool > m_storePixel
Definition: TrackStateOnSurfaceDecorator.h:74
DerivationFramework::TrackStateOnSurfaceDecorator::m_pixelLayerRadii
Gaudi::Property< std::vector< float > > m_pixelLayerRadii
Definition: TrackStateOnSurfaceDecorator.h:155
DerivationFramework::TrackStateOnSurfaceDecorator::m_TRTdEdxTool
ToolHandle< ITRT_ToT_dEdx > m_TRTdEdxTool
Definition: TrackStateOnSurfaceDecorator.h:138
ITRT_CalDbTool.h
abstract interface to TRT calibration constants
DerivationFramework::TrackStateOnSurfaceDecorator::kTrkIBLXDecor
@ kTrkIBLXDecor
Definition: TrackStateOnSurfaceDecorator.h:148
DerivationFramework
THE reconstruction tool.
Definition: ParticleSortingAlg.h:24
DerivationFramework::TrackStateOnSurfaceDecorator
Definition: TrackStateOnSurfaceDecorator.h:54
DerivationFramework::TrackStateOnSurfaceDecorator::kTRTdEdxDecor
@ kTRTdEdxDecor
Definition: TrackStateOnSurfaceDecorator.h:142
DataVector
Derived DataVector<T>.
Definition: DataVector.h:794
DerivationFramework::TrackStateOnSurfaceDecorator::m_trackTRTFloatDecorKeys
std::vector< SG::WriteDecorHandleKey< xAOD::TrackParticleContainer > > m_trackTRTFloatDecorKeys
Definition: TrackStateOnSurfaceDecorator.h:147
DerivationFramework::TrackStateOnSurfaceDecorator::m_updator
ToolHandle< Trk::IUpdator > m_updator
Definition: TrackStateOnSurfaceDecorator.h:128
DerivationFramework::TrackStateOnSurfaceDecorator::m_SCTDetEleCollKey
SG::ReadCondHandleKey< InDetDD::SiDetectorElementCollection > m_SCTDetEleCollKey
Definition: TrackStateOnSurfaceDecorator.h:119
DerivationFramework::TrackStateOnSurfaceDecorator::finalize
StatusCode finalize()
Definition: TrackStateOnSurfaceDecorator.cxx:177
IPRD_AssociationTool.h
ReadCondHandleKey.h
Trk::PrepRawData
Definition: PrepRawData.h:62
DerivationFramework::TrackStateOnSurfaceDecorator::m_trackTSOSMOSLinkDecorKey
SG::WriteDecorHandleKey< xAOD::TrackParticleContainer > m_trackTSOSMOSLinkDecorKey
Definition: TrackStateOnSurfaceDecorator.h:154
ITrackHoleSearchTool.h
Trk
Ensure that the ATLAS eigen extensions are properly loaded.
Definition: FakeTrackBuilder.h:9
DerivationFramework::TrackStateOnSurfaceDecorator::m_holeSearchTool
ToolHandle< Trk::ITrackHoleSearchTool > m_holeSearchTool
Definition: TrackStateOnSurfaceDecorator.h:133
SiDetectorElementCollection.h
DerivationFramework::TrackStateOnSurfaceDecorator::EPixFloatDecorKeys
EPixFloatDecorKeys
Definition: TrackStateOnSurfaceDecorator.h:148
DerivationFramework::TrackStateOnSurfaceDecorator::m_sctId
const SCT_ID * m_sctId
Definition: TrackStateOnSurfaceDecorator.h:125
EventInfo.h
TrackStateValidationContainer.h
IResidualPullCalculator.h
DerivationFramework::TrackStateOnSurfaceDecorator::m_addExtraEventInfo
Gaudi::Property< bool > m_addExtraEventInfo
Definition: TrackStateOnSurfaceDecorator.h:78
SG::ReadCondHandleKey< InDetDD::SiDetectorElementCollection >
DerivationFramework::TrackStateOnSurfaceDecorator::m_sgName
Gaudi::Property< std::string > m_sgName
Definition: TrackStateOnSurfaceDecorator.h:84
DerivationFramework::TrackStateOnSurfaceDecorator::m_trtMsosName
SG::WriteHandleKey< xAOD::TrackStateValidationContainer > m_trtMsosName
Definition: TrackStateOnSurfaceDecorator.h:114
DerivationFramework::TrackStateOnSurfaceDecorator::m_eventInfoKey
SG::ReadHandleKey< xAOD::EventInfo > m_eventInfoKey
Definition: TrackStateOnSurfaceDecorator.h:82
TRT_ID
Definition: TRT_ID.h:82
SCT_ID
Definition: SCT_ID.h:68
DerivationFramework::TrackStateOnSurfaceDecorator::m_addPRD
Gaudi::Property< bool > m_addPRD
Definition: TrackStateOnSurfaceDecorator.h:77
DerivationFramework::TrackStateOnSurfaceDecorator::m_storeSCT
Gaudi::Property< bool > m_storeSCT
Definition: TrackStateOnSurfaceDecorator.h:73
DerivationFramework::TrackStateOnSurfaceDecorator::m_trackPixFloatDecorKeys
std::vector< SG::WriteDecorHandleKey< xAOD::TrackParticleContainer > > m_trackPixFloatDecorKeys
Definition: TrackStateOnSurfaceDecorator.h:153
DerivationFramework::TrackStateOnSurfaceDecorator::initialize
StatusCode initialize()
Definition: TrackStateOnSurfaceDecorator.cxx:65
DerivationFramework::TrackStateOnSurfaceDecorator::m_pixelMsosName
SG::WriteHandleKey< xAOD::TrackStateValidationContainer > m_pixelMsosName
Definition: TrackStateOnSurfaceDecorator.h:110
DerivationFramework::TrackStateOnSurfaceDecorator::m_pixelClustersName
SG::ReadHandleKey< xAOD::TrackMeasurementValidationContainer > m_pixelClustersName
Definition: TrackStateOnSurfaceDecorator.h:100
TrackMeasurementValidationContainer.h
DerivationFramework::TrackStateOnSurfaceDecorator::m_trtPhaseDecorKey
std::vector< SG::WriteDecorHandleKey< xAOD::EventInfo > > m_trtPhaseDecorKey
Definition: TrackStateOnSurfaceDecorator.h:141
DerivationFramework::TrackStateOnSurfaceDecorator::m_selectionString
StringProperty m_selectionString
Definition: TrackStateOnSurfaceDecorator.h:90
PixelID
Definition: PixelID.h:67
DerivationFramework::TrackStateOnSurfaceDecorator::kTrkIBLZDecor
@ kTrkIBLZDecor
Definition: TrackStateOnSurfaceDecorator.h:148
DerivationFramework::TrackStateOnSurfaceDecorator::kTrkL2YDecor
@ kTrkL2YDecor
Definition: TrackStateOnSurfaceDecorator.h:151
DerivationFramework::TrackStateOnSurfaceDecorator::m_trtDCName
SG::ReadHandleKey< xAOD::TrackMeasurementValidationContainer > m_trtDCName
Definition: TrackStateOnSurfaceDecorator.h:104
DerivationFramework::TrackStateOnSurfaceDecorator::ETRTFloatDecor
ETRTFloatDecor
Definition: TrackStateOnSurfaceDecorator.h:142
DerivationFramework::TrackStateOnSurfaceDecorator::m_containerName
SG::ReadHandleKey< xAOD::TrackParticleContainer > m_containerName
Definition: TrackStateOnSurfaceDecorator.h:86
AtlasDetectorID
This class provides an interface to generate or decode an identifier for the upper levels of the dete...
Definition: AtlasDetectorID.h:52
TrackParticleContainer.h
DerivationFramework::TrackStateOnSurfaceDecorator::kTrkL1YDecor
@ kTrkL1YDecor
Definition: TrackStateOnSurfaceDecorator.h:150
DerivationFramework::TrackStateOnSurfaceDecorator::m_pixId
const PixelID * m_pixId
Definition: TrackStateOnSurfaceDecorator.h:124