ATLAS Offline Software
InDetToXAODSpacePointConversion.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3 */
4 
10 
13 
14 namespace InDet {
15 
17  ISvcLocator *pSvcLocator)
18  : AthReentrantAlgorithm(name, pSvcLocator)
19  {}
20 
22  {
23  ATH_MSG_DEBUG("Initializing " << name() << " ...");
24 
26 
30 
34 
37 
40 
42  ATH_CHECK(detStore()->retrieve(m_pixelID,"PixelID"));
43  ATH_CHECK(detStore()->retrieve(m_stripID,"SCT_ID"));
44  }
45 
46  return StatusCode::SUCCESS;
47  }
48 
50  {
51  ATH_MSG_DEBUG("Executing " << name() << " ...");
52 
53  // Conds
55  const InDet::BeamSpotData* beamSpot = *beamSpotHandle;
56  auto vertex = beamSpot->beamVtx().position();
57 
58  // Cluster Containers if requested
59  std::unique_ptr< xAOD::PixelClusterContainer > pixel_cluster_xaod_container = std::make_unique< xAOD::PixelClusterContainer >();
60  std::unique_ptr< xAOD::PixelClusterAuxContainer > pixel_cluster_xaod_aux_container = std::make_unique< xAOD::PixelClusterAuxContainer >();
61  pixel_cluster_xaod_container->setStore( pixel_cluster_xaod_aux_container.get() );
62 
63  std::unique_ptr< xAOD::StripClusterContainer > strip_cluster_xaod_container = std::make_unique< xAOD::StripClusterContainer >();
64  std::unique_ptr< xAOD::StripClusterAuxContainer > strip_cluster_xaod_aux_container = std::make_unique< xAOD::StripClusterAuxContainer >();
65  strip_cluster_xaod_container->setStore( strip_cluster_xaod_aux_container.get() );
66 
67  // Convert
68  if (m_processPixel.value()) {
69  ATH_CHECK( convertPixel(ctx, pixel_cluster_xaod_container.get()) );
70  }
71 
72  if (m_processStrip.value()) {
73  std::unordered_map<Identifier, std::size_t> mapClusters{};
75  strip_cluster_xaod_container.get(),
76  mapClusters) );
78  strip_cluster_xaod_container.get(),
79  mapClusters) );
80  }
81 
82  // Save optional clusters
83  if (m_convertClusters) {
84  if (m_processPixel.value()) {
86  ATH_CHECK( pixel_cluster_xaod_handle.record( std::move(pixel_cluster_xaod_container),
87  std::move(pixel_cluster_xaod_aux_container) ) );
88  }
89 
90  if (m_processStrip.value()) {
92  ATH_CHECK( strip_cluster_xaod_handle.record( std::move(strip_cluster_xaod_container),
93  std::move(strip_cluster_xaod_aux_container) ) );
94  }
95  }
96 
97  return StatusCode::SUCCESS;
98  }
99 
101  xAOD::PixelClusterContainer* cluster_xaod_container) const
102  {
103  static const SG::AuxElement::Accessor< ElementLink< ::SpacePointCollection > > linkAcc("pixelSpacePointLink");
104 
105  const InDetDD::SiDetectorElementCollection* pixElements = nullptr;
106  if (m_convertClusters) {
108  if (not pixelDetEleHandle.isValid()) {
109  ATH_MSG_FATAL(m_pixelDetEleCollKey.fullKey() << " is not available.");
110  return StatusCode::FAILURE;
111  }
112  pixElements = pixelDetEleHandle.cptr();
113  }
114 
115  // Input
117  ATH_CHECK( pixel_handle.isValid() );
118  const ::SpacePointContainer* pixel_container = pixel_handle.cptr();
119 
120  // Output
121  std::unique_ptr< xAOD::SpacePointContainer > pixel_xaod_container = std::make_unique< xAOD::SpacePointContainer >();
122  std::unique_ptr< xAOD::SpacePointAuxContainer > pixel_xaod_aux_container = std::make_unique< xAOD::SpacePointAuxContainer >();
123  pixel_xaod_container->setStore( pixel_xaod_aux_container.get() );
124 
125  pixel_xaod_container->reserve(pixel_container->size());
126  pixel_xaod_aux_container->reserve(pixel_container->size());
127 
128  // Conversion
129  for (const ::SpacePointCollection *spc : *pixel_container) {
130  for (const Trk::SpacePoint *sp : *spc) {
131  const InDet::PixelSpacePoint *indetSP = dynamic_cast<const InDet::PixelSpacePoint *>(sp);
132 
133  pixel_xaod_container->push_back( new xAOD::SpacePoint() );
134  ATH_CHECK( TrackingUtilities::convertTrkToXaodPixelSpacePoint(*indetSP, *pixel_xaod_container->back()) );
135 
136  // Also make cluster object, if requested
137  if (m_convertClusters) {
138  const std::pair<const Trk::PrepRawData*, const Trk::PrepRawData*>& clusterList = sp->clusterList();
139  const InDet::PixelCluster* theCluster = dynamic_cast<const InDet::PixelCluster*>(clusterList.first);
140  if (theCluster == nullptr) {
141  ATH_MSG_FATAL("Cannot cast InDet::PixelCluster");
142  }
143 
144  auto clusterId = clusterList.first->identify();
145  const InDetDD::SiDetectorElement *element = pixElements->getDetectorElement(m_pixelID->wafer_hash(m_pixelID->wafer_id(clusterId)));
146  if ( element == nullptr ) {
147  ATH_MSG_FATAL( "Invalid pixel detector element for cluster identifier " << clusterId );
148  return StatusCode::FAILURE;
149  }
150 
151  xAOD::PixelCluster * pixelCl = new xAOD::PixelCluster();
152  cluster_xaod_container->push_back(pixelCl);
153  ATH_CHECK( TrackingUtilities::convertInDetToXaodCluster(*theCluster, *element, *pixelCl) );
154  pixel_xaod_container->back()->setMeasurements( {cluster_xaod_container->back()} );
155  }
156 
157  // Add link to this space point
158  ElementLink< ::SpacePointCollection > link(indetSP, *spc);
159  linkAcc(*pixel_xaod_container->back()) = link;
160  }
161  }
162 
163  // Store
165  ATH_CHECK( pixel_xaod_handle.record( std::move(pixel_xaod_container), std::move(pixel_xaod_aux_container) ) );
166 
167  return StatusCode::SUCCESS;
168  }
169 
171  const Amg::Vector3D& vertex,
172  xAOD::StripClusterContainer* cluster_xaod_container,
173  std::unordered_map<Identifier, std::size_t>& mapClusters) const
174  {
175  const InDetDD::SiDetectorElementCollection* stripElements = nullptr;
176  if (m_convertClusters) {
178  if (not stripDetEleHandle.isValid()) {
179  ATH_MSG_FATAL(m_stripDetEleCollKey.fullKey() << " is not available.");
180  return StatusCode::FAILURE;
181  }
182  stripElements = stripDetEleHandle.cptr();
183  }
184 
185  static const SG::AuxElement::Accessor< ElementLink< ::SpacePointCollection > > linkAcc("sctSpacePointLink");
186 
187  // Input
189  ATH_CHECK( strip_handle.isValid() );
190  const ::SpacePointContainer* strip_container = strip_handle.cptr();
191 
192  // Output
193  std::unique_ptr< xAOD::SpacePointContainer > strip_xaod_container = std::make_unique< xAOD::SpacePointContainer >();
194  std::unique_ptr< xAOD::SpacePointAuxContainer > strip_xaod_aux_container = std::make_unique< xAOD::SpacePointAuxContainer >();
195  strip_xaod_container->setStore( strip_xaod_aux_container.get() );
196 
197  strip_xaod_container->reserve(strip_container->size());
198  strip_xaod_aux_container->reserve(strip_container->size());
199 
200  // Conversion
201  for (const ::SpacePointCollection *spc : *strip_container) {
202  for (const Trk::SpacePoint *sp : *spc) {
203  const InDet::SCT_SpacePoint *indetSP = dynamic_cast<const InDet::SCT_SpacePoint *>(sp);
204 
205  strip_xaod_container->push_back( new xAOD::SpacePoint() );
206  ATH_CHECK( TrackingUtilities::convertTrkToXaodStripSpacePoint(*indetSP, vertex, *strip_xaod_container->back()) );
207 
208  // Also make cluster object, if requested
209  if (m_convertClusters) {
210  const std::pair<const Trk::PrepRawData*, const Trk::PrepRawData*>& clusterList = sp->clusterList();
211  const InDet::SCT_Cluster* theCluster1 = dynamic_cast<const InDet::SCT_Cluster*>(clusterList.first);
212  const InDet::SCT_Cluster* theCluster2 = dynamic_cast<const InDet::SCT_Cluster*>(clusterList.second);
213  if (theCluster1 == nullptr or
214  theCluster2 == nullptr) {
215  ATH_MSG_FATAL("Cannot cast InDet::SCT_Cluster");
216  }
217 
218  auto clusterId1 = clusterList.first->identify();
219  auto clusterId2 = clusterList.second->identify();
220  const InDetDD::SiDetectorElement *element1 = stripElements->getDetectorElement(m_stripID->wafer_hash(m_stripID->wafer_id(clusterId1)));
221  const InDetDD::SiDetectorElement *element2 = stripElements->getDetectorElement(m_stripID->wafer_hash(m_stripID->wafer_id(clusterId2)));
222  if ( element1 == nullptr ) {
223  ATH_MSG_FATAL( "Invalid strip detector element for cluster (1) identifiers " << clusterId1 );
224  return StatusCode::FAILURE;
225  }
226  if ( element2 == nullptr ) {
227  ATH_MSG_FATAL( "Invalid strip detector element for cluster (2) identifiers " << clusterId2 );
228  return StatusCode::FAILURE;
229  }
230  //tries to insert an entry with key clusterId. Returns false and does nothing if the key already exists.
231  auto insertEntry = [&mapClusters, cluster_xaod_container](const auto & clusterId)-> bool{
232  const auto & [p,inserted] = mapClusters.try_emplace(clusterId, cluster_xaod_container->size());
233  return inserted;
234  };
235  // if cluster is not there, add entry and add cluster to container
236  if (insertEntry(clusterId1)){
237  xAOD::StripCluster * stripCl1 = new xAOD::StripCluster();
238  cluster_xaod_container->push_back(stripCl1);
239  ATH_CHECK( TrackingUtilities::convertInDetToXaodCluster(*theCluster1, *element1, *stripCl1) );
240  }
241  if (insertEntry(clusterId2)) {
242  xAOD::StripCluster * stripCl2 = new xAOD::StripCluster();
243  cluster_xaod_container->push_back(stripCl2);
244  ATH_CHECK( TrackingUtilities::convertInDetToXaodCluster(*theCluster2, *element2, *stripCl2) );
245  }
246  // Get the clusters so that we can add a link to them
247  xAOD::StripCluster * stripCl1 = cluster_xaod_container->at(mapClusters[clusterId1]);
248  xAOD::StripCluster * stripCl2 = cluster_xaod_container->at(mapClusters[clusterId2]);
249  strip_xaod_container->back()->setMeasurements( {stripCl1, stripCl2} );
250  }
251 
252  // Add link to this space point
253  ElementLink< ::SpacePointCollection > link(indetSP, *spc);
254  linkAcc(*strip_xaod_container->back()) = link;
255  }
256  }
257 
258  // Store
260  ATH_CHECK( strip_xaod_handle.record( std::move(strip_xaod_container), std::move(strip_xaod_aux_container) ) );
261 
262  return StatusCode::SUCCESS;
263  }
264 
265 
267  const Amg::Vector3D& vertex,
268  xAOD::StripClusterContainer* cluster_xaod_container,
269  std::unordered_map<Identifier, std::size_t>& mapClusters) const
270  {
271  const InDetDD::SiDetectorElementCollection* stripElements = nullptr;
272  if (m_convertClusters) {
274  if (not stripDetEleHandle.isValid()) {
275  ATH_MSG_FATAL(m_stripDetEleCollKey.fullKey() << " is not available.");
276  return StatusCode::FAILURE;
277  }
278  stripElements = stripDetEleHandle.cptr();
279  }
280 
281  // Inputs
283  ATH_CHECK( strip_overlap_handle.isValid() );
284  const ::SpacePointOverlapCollection* strip_overlap_container = strip_overlap_handle.cptr();
285 
286  // Outputs
287  std::unique_ptr< xAOD::SpacePointContainer > strip_overlap_xaod_container = std::make_unique< xAOD::SpacePointContainer >();
288  std::unique_ptr< xAOD::SpacePointAuxContainer > strip_overlap_xaod_aux_container = std::make_unique< xAOD::SpacePointAuxContainer >();
289  strip_overlap_xaod_container->setStore( strip_overlap_xaod_aux_container.get() );
290 
291  strip_overlap_xaod_container->reserve(strip_overlap_container->size());
292  strip_overlap_xaod_aux_container->reserve(strip_overlap_container->size());
293 
294  // Conversion
295  static const SG::AuxElement::Accessor< ElementLink< ::SpacePointOverlapCollection > > stripSpacePointLinkAcc("stripOverlapSpacePointLink");
296 
297  for (const Trk::SpacePoint *sp : *strip_overlap_container) {
298  const InDet::SCT_SpacePoint *indetSP = dynamic_cast<const InDet::SCT_SpacePoint *>(sp);
299 
300  strip_overlap_xaod_container->push_back( new xAOD::SpacePoint() );
301  ATH_CHECK( TrackingUtilities::convertTrkToXaodStripSpacePoint(*indetSP, vertex, *strip_overlap_xaod_container->back()) );
302 
303  // Also make cluster object, if requested
304  if (m_convertClusters) {
305  const std::pair<const Trk::PrepRawData*, const Trk::PrepRawData*>& clusterList = sp->clusterList();
306  const InDet::SCT_Cluster* theCluster1 = dynamic_cast<const InDet::SCT_Cluster*>(clusterList.first);
307  const InDet::SCT_Cluster* theCluster2 = dynamic_cast<const InDet::SCT_Cluster*>(clusterList.second);
308  if (theCluster1 == nullptr or
309  theCluster2 == nullptr) {
310  ATH_MSG_FATAL("Cannot cast InDet::SCT_Cluster");
311  }
312 
313  auto clusterId1 = clusterList.first->identify();
314  auto clusterId2 = clusterList.second->identify();
315  const InDetDD::SiDetectorElement *element1 = stripElements->getDetectorElement(m_stripID->wafer_hash(m_stripID->wafer_id(clusterId1)));
316  const InDetDD::SiDetectorElement *element2 = stripElements->getDetectorElement(m_stripID->wafer_hash(m_stripID->wafer_id(clusterId2)));
317 
318  if ( element1 == nullptr ) {
319  ATH_MSG_FATAL( "Invalid strip detector element for cluster (1) identifiers " << clusterId1 );
320  return StatusCode::FAILURE;
321  }
322  if ( element2 == nullptr ) {
323  ATH_MSG_FATAL( "Invalid strip detector element for cluster (2) identifiers " << clusterId2 );
324  return StatusCode::FAILURE;
325  }
326  //tries to insert an entry with key clusterId. Returns false and does nothing if the key already exists.
327  auto insertEntry = [&mapClusters, cluster_xaod_container](const auto & clusterId)-> bool{
328  const auto & [p,inserted] = mapClusters.try_emplace(clusterId, cluster_xaod_container->size());
329  return inserted;
330  };
331  if (insertEntry(clusterId1)) {
332  xAOD::StripCluster * stripCl1 = new xAOD::StripCluster();
333  cluster_xaod_container->push_back(stripCl1);
334  ATH_CHECK( TrackingUtilities::convertInDetToXaodCluster(*theCluster1, *element1, *stripCl1) );
335  }
336  if (insertEntry(clusterId2)) {
337  xAOD::StripCluster * stripCl2 = new xAOD::StripCluster();
338  cluster_xaod_container->push_back(stripCl2);
339  ATH_CHECK( TrackingUtilities::convertInDetToXaodCluster(*theCluster2, *element2, *stripCl2) );
340  }
341 
342  xAOD::StripCluster * stripCl1 = cluster_xaod_container->at(mapClusters[clusterId1]);
343  xAOD::StripCluster * stripCl2 = cluster_xaod_container->at(mapClusters[clusterId2]);
344  strip_overlap_xaod_container->back()->setMeasurements( {stripCl1, stripCl2} );
345  }
346 
347  ElementLink< ::SpacePointOverlapCollection > TrkLink(sp, *strip_overlap_container);
348  stripSpacePointLinkAcc( *strip_overlap_xaod_container->back() ) = TrkLink;
349  }
350 
351  // Store
353  ATH_CHECK( strip_overlap_xaod_handle.record( std::move(strip_overlap_xaod_container), std::move(strip_overlap_xaod_aux_container) ) );
354 
355  return StatusCode::SUCCESS;
356  }
357 
358 }
DataVector::reserve
void reserve(size_type n)
Attempt to preallocate enough memory for a specified number of elements.
InDet::InDetToXAODSpacePointConversion::m_beamSpotKey
SG::ReadCondHandleKey< InDet::BeamSpotData > m_beamSpotKey
Definition: InDetToXAODSpacePointConversion.h:57
python.PyKernel.retrieve
def retrieve(aClass, aKey=None)
Definition: PyKernel.py:110
InDet::InDetToXAODSpacePointConversion::convertPixel
StatusCode convertPixel(const EventContext &ctx, xAOD::PixelClusterContainer *cluster_xaod_container) const
Definition: InDetToXAODSpacePointConversion.cxx:100
Trk::SpacePoint
Definition: Tracking/TrkEvent/TrkSpacePoint/TrkSpacePoint/SpacePoint.h:35
InDet::InDetToXAODSpacePointConversion::m_processStrip
Gaudi::Property< bool > m_processStrip
Definition: InDetToXAODSpacePointConversion.h:84
TrackingUtilities::convertInDetToXaodCluster
StatusCode convertInDetToXaodCluster(const InDet::PixelCluster &indetCluster, const InDetDD::SiDetectorElement &element, xAOD::PixelCluster &xaodCluster)
Definition: ClusterConversionUtilities.cxx:52
ATH_MSG_FATAL
#define ATH_MSG_FATAL(x)
Definition: AthMsgStreamMacros.h:34
InDet::InDetToXAODSpacePointConversion::InDetToXAODSpacePointConversion
InDetToXAODSpacePointConversion(const std::string &name, ISvcLocator *pSvcLocator)
Constructor with parameters:
Definition: InDetToXAODSpacePointConversion.cxx:16
InDet::InDetToXAODSpacePointConversion::m_outSpacepointsStrip
SG::WriteHandleKey< xAOD::SpacePointContainer > m_outSpacepointsStrip
Definition: InDetToXAODSpacePointConversion.h:74
InDetDD::SiDetectorElementCollection
Definition: SiDetectorElementCollection.h:30
SG::ReadCondHandle
Definition: ReadCondHandle.h:44
SG::ReadHandle::cptr
const_pointer_type cptr()
Dereference the pointer.
InDet::InDetToXAODSpacePointConversion::m_outClustersPixel
SG::WriteHandleKey< xAOD::PixelClusterContainer > m_outClustersPixel
Definition: InDetToXAODSpacePointConversion.h:67
SG::Accessor
Helper class to provide type-safe access to aux data.
Definition: Control/AthContainers/AthContainers/Accessor.h:68
SG::ReadHandle
Definition: StoreGate/StoreGate/ReadHandle.h:70
InDet
Primary Vertex Finder.
Definition: VP1ErrorUtils.h:36
InDet::InDetToXAODSpacePointConversion::m_inSpacepointsStrip
SG::ReadHandleKey< ::SpacePointContainer > m_inSpacepointsStrip
Definition: InDetToXAODSpacePointConversion.h:62
InDet::InDetToXAODSpacePointConversion::m_inSpacepointsPixel
SG::ReadHandleKey< ::SpacePointContainer > m_inSpacepointsPixel
Definition: InDetToXAODSpacePointConversion.h:60
SG::ReadCondHandle::isValid
bool isValid()
Definition: ReadCondHandle.h:206
InDet::InDetToXAODSpacePointConversion::m_pixelID
const PixelID * m_pixelID
Definition: InDetToXAODSpacePointConversion.h:86
xAOD::SpacePoint_v1
Definition: SpacePoint_v1.h:29
InDet::InDetToXAODSpacePointConversion::convertStripOverlap
StatusCode convertStripOverlap(const EventContext &ctx, const Amg::Vector3D &vertex, xAOD::StripClusterContainer *cluster_xaod_container, std::unordered_map< Identifier, std::size_t > &mapClusters) const
Definition: InDetToXAODSpacePointConversion.cxx:266
InDet::PixelSpacePoint
Definition: PixelSpacePoint.h:31
TrackingUtilities::convertTrkToXaodPixelSpacePoint
StatusCode convertTrkToXaodPixelSpacePoint(const InDet::PixelSpacePoint &trkSpacePoint, xAOD::SpacePoint &xaodSpacePoint)
Definition: SpacePointConversionUtilities.cxx:12
PrepRawData.h
PixelID::wafer_id
Identifier wafer_id(int barrel_ec, int layer_disk, int phi_module, int eta_module) const
For a single crystal.
Definition: PixelID.h:364
AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >::detStore
const ServiceHandle< StoreGateSvc > & detStore() const
The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.
Definition: AthCommonDataStore.h:95
AthReentrantAlgorithm
An algorithm that can be simultaneously executed in multiple threads.
Definition: AthReentrantAlgorithm.h:83
SG::makeHandle
SG::ReadCondHandle< T > makeHandle(const SG::ReadCondHandleKey< T > &key, const EventContext &ctx=Gaudi::Hive::currentContext())
Definition: ReadCondHandle.h:270
InDet::InDetToXAODSpacePointConversion::convertStrip
StatusCode convertStrip(const EventContext &ctx, const Amg::Vector3D &vertex, xAOD::StripClusterContainer *cluster_xaod_container, std::unordered_map< Identifier, std::size_t > &mapClusters) const
Definition: InDetToXAODSpacePointConversion.cxx:170
xAOD::StripCluster
StripCluster_v1 StripCluster
Define the version of the strip cluster class.
Definition: StripCluster.h:13
xAOD::AuxContainerBase::reserve
virtual void reserve(size_t size) override
Reserve a given size for the arrays.
Definition: AuxContainerBase.cxx:533
SCT_ClusterCollection.h
InDet::InDetToXAODSpacePointConversion::m_outSpacepointsPixel
SG::WriteHandleKey< xAOD::SpacePointContainer > m_outSpacepointsPixel
Definition: InDetToXAODSpacePointConversion.h:72
python.utils.AtlRunQueryDQUtils.p
p
Definition: AtlRunQueryDQUtils.py:210
PixelID::wafer_hash
IdentifierHash wafer_hash(Identifier wafer_id) const
wafer hash from id
Definition: PixelID.h:387
InDet::InDetToXAODSpacePointConversion::m_outSpacepointsOverlap
SG::WriteHandleKey< xAOD::SpacePointContainer > m_outSpacepointsOverlap
Definition: InDetToXAODSpacePointConversion.h:76
xAOD::PixelCluster
PixelCluster_v1 PixelCluster
Define the version of the pixel cluster class.
Definition: Event/xAOD/xAODInDetMeasurement/xAODInDetMeasurement/PixelCluster.h:13
InDet::InDetToXAODSpacePointConversion::m_outClustersStrip
SG::WriteHandleKey< xAOD::StripClusterContainer > m_outClustersStrip
Definition: InDetToXAODSpacePointConversion.h:69
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
xAOD::StripCluster_v1
Definition: StripCluster_v1.h:17
ATH_CHECK
#define ATH_CHECK
Definition: AthCheckMacros.h:40
SCT_ID::wafer_hash
IdentifierHash wafer_hash(const Identifier &wafer_id) const
wafer hash from id - optimized
Definition: SCT_ID.h:492
PixelClusterCollection.h
InDet::SCT_Cluster
Definition: InnerDetector/InDetRecEvent/InDetPrepRawData/InDetPrepRawData/SCT_Cluster.h:34
DataVector::back
const T * back() const
Access the last element in the collection as an rvalue.
DataVector
Derived DataVector<T>.
Definition: DataVector.h:794
InDet::InDetToXAODSpacePointConversion::m_convertClusters
Gaudi::Property< bool > m_convertClusters
Definition: InDetToXAODSpacePointConversion.h:82
ClusterConversionUtilities.h
SG::ReadHandle::isValid
virtual bool isValid() override final
Can the handle be successfully dereferenced?
TrackingUtilities::convertTrkToXaodStripSpacePoint
StatusCode convertTrkToXaodStripSpacePoint(const InDet::SCT_SpacePoint &trkSpacePoint, const Amg::Vector3D &vertex, xAOD::SpacePoint &xaodSpacePoint)
Definition: SpacePointConversionUtilities.cxx:43
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:228
SiCluster.h
InDetDD::SiDetectorElement
Definition: SiDetectorElement.h:109
DataVector::push_back
value_type push_back(value_type pElem)
Add an element to the end of the collection.
SG::CondHandleKey::initialize
StatusCode initialize(bool used=true)
InDet::SCT_SpacePoint
Definition: SCT_SpacePoint.h:31
Amg::Vector3D
Eigen::Matrix< double, 3, 1 > Vector3D
Definition: GeoPrimitives.h:47
InDet::PixelCluster
Definition: InnerDetector/InDetRecEvent/InDetPrepRawData/InDetPrepRawData/PixelCluster.h:49
SG::WriteHandle
Definition: StoreGate/StoreGate/WriteHandle.h:76
Trk::vertex
@ vertex
Definition: MeasurementType.h:21
InDet::BeamSpotData
Definition: BeamSpotData.h:21
xAOD::PixelCluster_v1
Definition: PixelCluster_v1.h:17
xAOD::SpacePointContainer
SpacePointContainer_v1 SpacePointContainer
Define the version of the space point container.
Definition: Event/xAOD/xAODInDetMeasurement/xAODInDetMeasurement/SpacePointContainer.h:14
SG::WriteHandle::record
StatusCode record(std::unique_ptr< T > data)
Record a const object to the store.
InDet::InDetToXAODSpacePointConversion::m_inSpacepointsOverlap
SG::ReadHandleKey< ::SpacePointOverlapCollection > m_inSpacepointsOverlap
Definition: InDetToXAODSpacePointConversion.h:64
InDet::InDetToXAODSpacePointConversion::execute
virtual StatusCode execute(const EventContext &ctx) const override
Definition: InDetToXAODSpacePointConversion.cxx:49
python.BuildSignatureFlags.beamSpot
AthConfigFlags beamSpot(AthConfigFlags flags, str instanceName, str recoMode)
Definition: BuildSignatureFlags.py:454
InDet::InDetToXAODSpacePointConversion::m_pixelDetEleCollKey
SG::ReadCondHandleKey< InDetDD::SiDetectorElementCollection > m_pixelDetEleCollKey
Definition: InDetToXAODSpacePointConversion.h:79
SpacePointConversionUtilities.h
DataVector::at
const T * at(size_type n) const
Access an element, as an rvalue.
SCT_ID::wafer_id
Identifier wafer_id(int barrel_ec, int layer_disk, int phi_module, int eta_module, int side) const
For a single side of module.
Definition: SCT_ID.h:464
InDet::InDetToXAODSpacePointConversion::m_processPixel
Gaudi::Property< bool > m_processPixel
Definition: InDetToXAODSpacePointConversion.h:83
InDet::InDetToXAODSpacePointConversion::m_stripDetEleCollKey
SG::ReadCondHandleKey< InDetDD::SiDetectorElementCollection > m_stripDetEleCollKey
Definition: InDetToXAODSpacePointConversion.h:80
DataVector::size
size_type size() const noexcept
Returns the number of elements in the collection.
InDetDD::SiDetectorElementCollection::getDetectorElement
const SiDetectorElement * getDetectorElement(const IdentifierHash &hash) const
Definition: SiDetectorElementCollection.cxx:15
InDet::InDetToXAODSpacePointConversion::m_stripID
const SCT_ID * m_stripID
Definition: InDetToXAODSpacePointConversion.h:87
InDetToXAODSpacePointConversion.h
InDet::InDetToXAODSpacePointConversion::initialize
virtual StatusCode initialize() override
Definition: InDetToXAODSpacePointConversion.cxx:21
SG::ReadCondHandle::cptr
const_pointer_type cptr()
Definition: ReadCondHandle.h:67