ATLAS Offline Software
StripSpacePointFormationAlgBase.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef ACTSTRK_DATAPREPARATION_StripSpacePointFormationAlgBase_H
6 #define ACTSTRK_DATAPREPARATION_StripSpacePointFormationAlgBase_H
7 
9 #include "GaudiKernel/ToolHandle.h"
11 
15 
17 
21 
25 
26 #include <string>
27 
28 #include "src/Cache.h"
29 #include "SPCacheId.h"
30 
31 namespace ActsTrk {
44 
45  template <bool useCache>
47  public:
49 
51  ISvcLocator* pSvcLocator);
52  virtual ~StripSpacePointFormationAlgBase() = default;
53  virtual StatusCode initialize() override;
54  virtual StatusCode execute (const EventContext& ctx) const override;
55  virtual StatusCode finalize() override;
57 
58  private:
60 
65 
67 
68  SG::ReadHandleKey<xAOD::StripClusterContainer> m_stripClusterContainerKey{this, "StripClusters", "", "name of the input strip cluster container"};
70 
72 
73  SG::ReadCondHandleKey<InDet::BeamSpotData> m_beamSpotKey { this, "BeamSpotKey", "BeamSpotData", "SG key for beam spot" };
75 
77  SG::ReadCondHandleKey<InDetDD::SiDetectorElementCollection> m_stripDetEleCollKey{this, "StripDetectorElements", "ITkStripDetectorElementCollection", "Key of input SiDetectorElementCollection for Strip"};
79  SG::ReadCondHandleKey<InDet::SiElementPropertiesTable> m_stripPropertiesKey{this, "StripElementPropertiesTable", "ITkStripElementPropertiesTable", "Key of input SiElementPropertiesTable for Strip"};
81 
83 
84  SG::WriteHandleKey<xAOD::SpacePointContainer> m_stripSpacePointContainerKey{this, "StripSpacePoints", "", "name of the output strip space point container"};
85  SG::WriteHandleKey<xAOD::SpacePointContainer> m_stripOverlapSpacePointContainerKey{this, "StripOverlapSpacePoints", "", "name of the strip overlap strip space point container"};
87 
89 
90  ToolHandle<ActsTrk::IStripSpacePointFormationTool> m_spacePointMakerTool{this, "SpacePointFormationTool", "", "Tool dedicated to the creation of pixel space points"};
93  ToolHandle<GenericMonitoringTool> m_monTool{this, "MonTool", "", "Monitoring tool"};
95 
97 
98  Gaudi::Property< bool > m_processOverlapForStrip{this, "ProcessOverlapForStrip", true, "Enable production of eta/phi overlapping strip space points."};
100 
101  //caching
107 
108  Cache_WriteHandleKey m_SPCache{this,"SPCache",""};
110 
111  Cache_WriteHandleKey m_OSPCache{this,"OSPCache",""};
113 
114  void fillSpacepoints(xAOD::SpacePointContainer* cont, std::vector<StripSP>& input, const xAOD::StripClusterContainer* inputClusters, unsigned int indexBase=0) const;
115 
116  private:
117  enum EStat {
121  kNStat
122  };
123 
124  mutable std::array<std::atomic<unsigned int>, kNStat> m_stat ATLAS_THREAD_SAFE {};
125  };
126 
127 }
128 
130 
131 #endif // ACTSTRKSPACEPOINTFORMATION_StripSpacePointFormationAlgBase_H
ReadHandleKey.h
Property holding a SG store/key/clid from which a ReadHandle is made.
ActsTrk::StripSpacePointFormationAlgBase< true >::Cache_WriteHandle
typename Cache::Handles< xAOD::SpacePoint >::WriteHandle Cache_WriteHandle
Definition: StripSpacePointFormationAlgBase.h:106
ActsTrk::StripSpacePointFormationAlgBase::m_stripSpacePointContainerKey
SG::WriteHandleKey< xAOD::SpacePointContainer > m_stripSpacePointContainerKey
Definition: StripSpacePointFormationAlgBase.h:84
SiElementPropertiesTable.h
ActsTrk::StripSpacePointFormationAlgBase::StripSpacePointFormationAlgBase
StripSpacePointFormationAlgBase(const std::string &name, ISvcLocator *pSvcLocator)
SG::UpdateHandleKey
Property holding a SG store/key/clid from which an UpdateHandle is made.
Definition: UpdateHandleKey.h:40
ActsTrk::StripSpacePointFormationAlgBase::~StripSpacePointFormationAlgBase
virtual ~StripSpacePointFormationAlgBase()=default
ActsTrk::StripSpacePointFormationAlgBase::kNOverlapSpacePoints
@ kNOverlapSpacePoints
Definition: StripSpacePointFormationAlgBase.h:120
ActsTrk::StripSpacePointFormationAlgBase::m_stripPropertiesKey
SG::ReadCondHandleKey< InDet::SiElementPropertiesTable > m_stripPropertiesKey
To get strip module neighbours.
Definition: StripSpacePointFormationAlgBase.h:79
SG::ReadHandleKey< xAOD::StripClusterContainer >
AthReentrantAlgorithm
An algorithm that can be simultaneously executed in multiple threads.
Definition: AthReentrantAlgorithm.h:83
ActsTrk::StripSpacePointFormationAlgBase< true >::Cache_BackendUpdateHandleKey
typename Cache::Handles< xAOD::SpacePoint >::BackendUpdateHandleKey Cache_BackendUpdateHandleKey
Definition: StripSpacePointFormationAlgBase.h:103
ActsTrk::StripSpacePointFormationAlgBase::kNSpacePoints
@ kNSpacePoints
Definition: StripSpacePointFormationAlgBase.h:119
ActsTrk::StripSpacePointFormationAlgBase< true >::Cache_BackendUpdateHandle
typename Cache::Handles< xAOD::SpacePoint >::BackendUpdateHandle Cache_BackendUpdateHandle
Definition: StripSpacePointFormationAlgBase.h:104
ActsTrk::StripSpacePointFormationAlgBase::fillSpacepoints
void fillSpacepoints(xAOD::SpacePointContainer *cont, std::vector< StripSP > &input, const xAOD::StripClusterContainer *inputClusters, unsigned int indexBase=0) const
ActsTrk::StripSpacePointFormationAlgBase::kNStat
@ kNStat
Definition: StripSpacePointFormationAlgBase.h:121
SPCacheId.h
GenericMonitoringTool.h
ActsTrk::StripSpacePointFormationAlgBase::m_spacePointMakerTool
ToolHandle< ActsTrk::IStripSpacePointFormationTool > m_spacePointMakerTool
For space point formation.
Definition: StripSpacePointFormationAlgBase.h:91
ActsTrk::StripSpacePointFormationAlgBase::StripSpacePointFormationAlgBase
StripSpacePointFormationAlgBase(const StripSpacePointFormationAlgBase &)=delete
SG::WriteHandleKey
Property holding a SG store/key/clid from which a WriteHandle is made.
Definition: StoreGate/StoreGate/WriteHandleKey.h:40
ActsTrk::StripSpacePointFormationAlgBase::StripSpacePointFormationAlgBase
StripSpacePointFormationAlgBase()=delete
StripSpacePointFormationAlgBase.icc
ActsTrk::StripSpacePointFormationAlgBase< true >::Cache_IDC
typename Cache::Handles< xAOD::SpacePoint >::IDC Cache_IDC
Definition: StripSpacePointFormationAlgBase.h:102
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
PlotPulseshapeFromCool.input
input
Definition: PlotPulseshapeFromCool.py:106
ActsTrk::StripSpacePointFormationAlgBase::m_SPCache
Cache_WriteHandleKey m_SPCache
Definition: StripSpacePointFormationAlgBase.h:108
ActsTrk::StripSpacePointFormationAlgBase::m_OSPCacheBackend
Cache_BackendUpdateHandleKey m_OSPCacheBackend
Definition: StripSpacePointFormationAlgBase.h:112
ActsTrk::StripSpacePointFormationAlgBase::finalize
virtual StatusCode finalize() override
ActsTrk::StripSpacePointFormationAlgBase::initialize
virtual StatusCode initialize() override
ActsTrk::StripSpacePointFormationAlgBase
Definition: StripSpacePointFormationAlgBase.h:46
DataVector
Derived DataVector<T>.
Definition: DataVector.h:794
ActsTrk::StripSpacePointFormationAlgBase::m_stripClusterContainerKey
SG::ReadHandleKey< xAOD::StripClusterContainer > m_stripClusterContainerKey
Definition: StripSpacePointFormationAlgBase.h:68
ReadCondHandleKey.h
AthReentrantAlgorithm.h
WriteHandleKey.h
Property holding a SG store/key/clid from which a WriteHandle is made.
SpacePointAuxContainer.h
ActsTrk::StripSpacePointFormationAlgBase< true >::EStat
EStat
Definition: StripSpacePointFormationAlgBase.h:117
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:228
Cache.h
ActsTrk::StripSpacePointFormationAlgBase::operator=
StripSpacePointFormationAlgBase & operator=(const StripSpacePointFormationAlgBase &)=delete
SG::UpdateHandle
Definition: UpdateHandle.h:94
ActsTrk::StripSpacePointFormationAlgBase::m_stripOverlapSpacePointContainerKey
SG::WriteHandleKey< xAOD::SpacePointContainer > m_stripOverlapSpacePointContainerKey
Definition: StripSpacePointFormationAlgBase.h:85
SiDetectorElementCollection.h
ActsTrk::StripSpacePointFormationAlgBase::m_stripDetEleCollKey
SG::ReadCondHandleKey< InDetDD::SiDetectorElementCollection > m_stripDetEleCollKey
To get detector elements.
Definition: StripSpacePointFormationAlgBase.h:77
SG::ReadCondHandleKey< InDet::BeamSpotData >
ActsTrk::StripSpacePointFormationAlgBase< true >::Cache_WriteHandleKey
typename Cache::Handles< xAOD::SpacePoint >::WriteHandleKey Cache_WriteHandleKey
Definition: StripSpacePointFormationAlgBase.h:105
SG::WriteHandle
Definition: StoreGate/StoreGate/WriteHandle.h:76
ActsTrk::StripSpacePointFormationAlgBase::m_beamSpotKey
SG::ReadCondHandleKey< InDet::BeamSpotData > m_beamSpotKey
To get beam spot data.
Definition: StripSpacePointFormationAlgBase.h:74
SpacePointContainer.h
StripClusterContainer.h
ActsTrk::StripSpacePointFormationAlgBase::m_SPCacheBackend
Cache_BackendUpdateHandleKey m_SPCacheBackend
Definition: StripSpacePointFormationAlgBase.h:109
ActsTrk::StripSpacePointFormationAlgBase::m_monTool
ToolHandle< GenericMonitoringTool > m_monTool
For monitoring.
Definition: StripSpacePointFormationAlgBase.h:93
ActsTrk::StripSpacePointFormationAlgBase::kNClusters
@ kNClusters
Definition: StripSpacePointFormationAlgBase.h:118
ActsTrk
The AlignStoreProviderAlg loads the rigid alignment corrections and pipes them through the readout ge...
Definition: MuonDetectorBuilderTool.cxx:54
ActsTrk::StripSpacePointFormationAlgBase::execute
virtual StatusCode execute(const EventContext &ctx) const override
BeamSpotData.h
IdentifiableContainerMT
Definition: IdentifiableContainerMT.h:30
ActsTrk::StripSpacePointFormationAlgBase::ATLAS_THREAD_SAFE
std::array< std::atomic< unsigned int >, kNStat > m_stat ATLAS_THREAD_SAFE
Definition: StripSpacePointFormationAlgBase.h:124
ActsTrk::StripSpacePointFormationAlgBase::m_OSPCache
Cache_WriteHandleKey m_OSPCache
Definition: StripSpacePointFormationAlgBase.h:111
ActsTrk::StripSpacePointFormationAlgBase::m_processOverlapForStrip
Gaudi::Property< bool > m_processOverlapForStrip
Definition: StripSpacePointFormationAlgBase.h:98
IStripSpacePointFormationTool.h