ATLAS Offline Software
SiLayerBuilderImpl.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2023 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef INDETTRACKINGGEOMETRY_SILAYERBUILDERIMPL_H
6 #define INDETTRACKINGGEOMETRY_SILAYERBUILDERIMPL_H
7 
8 // Athena
12 // Amg
14 // Trk
18 // STL
19 #include <vector>
20 #include <utility> //for std::pair
21 
22 class PixelID;
23 class SCT_ID;
24 
25 #ifndef TRKDETDESCR_TAKESMALLERBIGGER
26 #define TRKDETDESCR_TAKESMALLERBIGGER
27 #define takeSmaller(current,test) current = current < test ? current : test
28 #define takeBigger(current,test) current = current > test ? current : test
29 #define takeSmallerBigger(cSmallest, cBiggest, test) takeSmaller(cSmallest, test); takeBigger(cBiggest, test)
30 #endif
31 
32 namespace InDetDD {
33  class SiDetectorManager;
34 }
35 
36 namespace Trk {
37  class Surface;
38  class CylinderLayer;
39  class DiscLayer;
40  class BinnedLayerMaterial;
41  typedef std::pair< SharedObject<Surface>, Amg::Vector3D > SurfaceOrderPosition;
42 }
43 
44 namespace InDet {
45 
60 
61  public:
62 
64  virtual ~SiLayerBuilderImpl() = default;
65 
67  virtual StatusCode initialize() override;
69  virtual StatusCode finalize() override;
70 
71  protected:
73  SiLayerBuilderImpl(const std::string&,const std::string&,const IInterface*);
74 
75  void registerSurfacesToLayer(Trk::BinnedArraySpan<Trk::Surface * const >& layerSurfaces, Trk::Layer& lay) const;
76 
77  std::unique_ptr<const std::vector<Trk::CylinderLayer*> >
78  cylindricalLayersImpl(const InDetDD::SiDetectorElementCollection& siDetElementCollection) const;
79 
80  std::unique_ptr<std::vector< Trk::DiscLayer*> >
81  createDiscLayersImpl(const InDetDD::SiDetectorElementCollection& siDetElementCollection, std::unique_ptr<std::vector< Trk::DiscLayer*> > discLayers = nullptr) const;
82 
83  std::unique_ptr<std::vector< Trk::DiscLayer*> >
84  createRingLayersImpl(const InDetDD::SiDetectorElementCollection& siDetElementCollection) const;
85 
86  std::unique_ptr<std::vector<Trk::CylinderLayer*> >
87  dressCylinderLayers(const std::vector<Trk::CylinderLayer* >& dLayers) const;
88 
90  const Trk::BinnedLayerMaterial barrelLayerMaterial(double r,
91  double hz) const;
92 
94  const Trk::BinnedLayerMaterial endcapLayerMaterial(double rMin,
95  double rMax) const;
96 
98  BooleanProperty m_pixelCase{this, "PixelCase", true};
99  const InDetDD::SiDetectorManager *m_siMgr{};
100  StringProperty m_siMgrLocation{this, "SiDetManagerLocation", "Pixel"};
101  const PixelID *m_pixIdHelper{};
102  const SCT_ID *m_sctIdHelper{};
103 
104  BooleanProperty m_setLayerAssociation{this, "SetLayerAssociation", true};
105 
106  // For the Active Barrel Material
107  // barrel layer section
108  DoubleArrayProperty m_barrelAdditionalLayerR{this, "BarrelAdditionalLayerRadii", {} };
109  IntegerArrayProperty m_barrelAdditionalLayerType{this, "BarrelAdditionalLayerType", {} };
110  UnsignedIntegerProperty m_barrelLayerBinsZ{this, "BarrelLayerBinsZ", 100};
111  UnsignedIntegerProperty m_barrelLayerBinsPhi{this, "BarrelLayerBinsPhi", 1};
112  DoubleProperty m_barrelEnvelope{this, "BarrelEnvelope", 0.1};
113  DoubleProperty m_barrelEdbTolerance{this, "BarrelEdbTolerance", 0.05};
114 
115  // For the Active Endcap Material
116  DoubleArrayProperty m_endcapAdditionalLayerPosZ{this, "EndcapAdditionalLayerPositionsZ", {} };
117  IntegerArrayProperty m_endcapAdditionalLayerType{this,"EndcapAdditionalLayerType" , {} };
118  UnsignedIntegerProperty m_endcapLayerBinsR{this, "EndcapLayerBinsR", 100};
119  UnsignedIntegerProperty m_endcapLayerBinsPhi{this, "EndcapLayerBinsPhi", 1};
120  DoubleProperty m_endcapEnvelope{this, "EndcapEnvelope", 0.1};
121  BooleanProperty m_endcapComplexRingBinning{this, "EndcapComplexRingBinning", true};
122 
123  StringProperty m_identification{this, "Identification", "Pixel"};
124 
125  BooleanProperty m_runGeometryValidation{this, "GeometryValidation", true};
126 
127  IntegerArrayProperty m_layerIndicesBarrel{this, "LayerIndicesBarrel", {} };
128  IntegerArrayProperty m_layerIndicesEndcap{this, "LayerIndicesEndcap", {} };
129  BooleanProperty m_useRingLayout{this, "UseRingLayout", false};
130  BooleanProperty m_addMoreSurfaces{this, "AddMoreSurfaces", false};
131 
132  // Properties only in SiLayerBuilderCond
133  SG::ReadCondHandleKey<InDetDD::SiDetectorElementCollection> m_SCT_ReadKey{this, "SCT_ReadKey", "SCT_DetectorElementCollection", "Key of output SiDetectorElementCollection for SCT"};
134  SG::ReadCondHandleKey<InDetDD::SiDetectorElementCollection> m_PixelReadKey{this, "PixelReadKey", "PixelDetectorElementCollection", "Key of output SiDetectorElementCollection for Pixel"};
135 
136 
137 
138  };
139 
140 } // end of namespace
141 
142 
143 #endif // INDETTRACKINGGEOMETRY_SILAYERBUILDERIMPL_H
beamspotman.r
def r
Definition: beamspotman.py:676
python.tests.PyTestsLib.finalize
def finalize(self)
_info( "content of StoreGate..." ) self.sg.dump()
Definition: PyTestsLib.py:53
InDetDD::SiDetectorElementCollection
Definition: SiDetectorElementCollection.h:30
ATLAS_NOT_THREAD_SAFE
#define ATLAS_NOT_THREAD_SAFE
getNoisyStrip() Find noisy strips from hitmaps and write out into xml/db formats
Definition: checker_macros.h:212
InDet
DUMMY Primary Vertex Finder.
Definition: VP1ErrorUtils.h:36
BinnedArray.h
initialize
void initialize()
Definition: run_EoverP.cxx:894
Surface
Definition: Trigger/TrigAccel/TrigCudaFitter/src/Surface.h:7
GeoPrimitives.h
InDet::SiLayerBuilderImpl
Definition: SiLayerBuilderImpl.h:59
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
AthAlgTool.h
Trk::BinnedLayerMaterial
Definition: BinnedLayerMaterial.h:33
SharedObject.h
Trk
Ensure that the ATLAS eigen extensions are properly loaded.
Definition: FakeTrackBuilder.h:9
SiDetectorElementCollection.h
Amg::Vector3D
Eigen::Matrix< double, 3, 1 > Vector3D
Definition: GeoPrimitives.h:47
SG::ReadCondHandleKey< InDetDD::SiDetectorElementCollection >
SCT_ID
Definition: SCT_ID.h:68
InDetDD
Message Stream Member.
Definition: FakeTrackBuilder.h:8
InDet::SiLayerBuilderImpl::~SiLayerBuilderImpl
virtual ~SiLayerBuilderImpl()=default
Destructor.
InDetDD::SiDetectorManager
Definition: SiDetectorManager.h:60
TrackingGeometry.h
fitman.hz
def hz
Definition: fitman.py:516
AthAlgTool
Definition: AthAlgTool.h:26
checker_macros.h
Define macros for attributes used to control the static checker.
PixelID
Definition: PixelID.h:67
Trk::BinnedArraySpan
std::span< T > BinnedArraySpan
Definition: BinnedArray.h:34
Trk::SurfaceOrderPosition
std::pair< SharedObject< Surface >, Amg::Vector3D > SurfaceOrderPosition
Definition: HGTD_LayerBuilderCond.h:36
Trk::Layer
Definition: Layer.h:73