ATLAS Offline Software
Loading...
Searching...
No Matches
HGTD_LayerBuilderCond.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// HGTD_LayerBuilderCond.h, (c) ATLAS Detector software
8
9#ifndef HGTD_TRACKINGGEOMETRY_HGTDLAYERBUILDERCOND_H
10#define HGTD_TRACKINGGEOMETRY_HGTDLAYERBUILDERCOND_H
11
12// Athena
15
16// Amg
18// Trk
22// STL
23#include <memory>
24#include <vector>
25//
27
28class HGTD_ID;
30
31namespace Trk {
32 class Surface;
33 class CylinderLayer;
34 class DiscLayer;
35 class PlaneLayer;
37 typedef std::pair< std::shared_ptr<Surface>, Amg::Vector3D > SurfaceOrderPosition;
38}
39
47
48//This class in not thread safe although the checker does nor readily see this.
49//The issue is that the input is still modifiable. For details see discussion in
50//https://gitlab.cern.ch/atlas/athena/-/merge_requests/79401#note_9399034
51class ATLAS_NOT_THREAD_SAFE HGTD_LayerBuilderCond : public extends<AthAlgTool, Trk::ILayerBuilderCond> {
52
53 public:
54
56 HGTD_LayerBuilderCond(const std::string&,const std::string&,const IInterface*);
57
60
62 virtual StatusCode initialize() override;
63
65 virtual std::unique_ptr<const std::vector<Trk::CylinderLayer*> >
66 cylindricalLayers(const EventContext& ctx,
67 SG::WriteCondHandle<Trk::TrackingGeometry>& whandle) const override final;
68
70 virtual std::unique_ptr<const std::vector<Trk::DiscLayer*> >
71 discLayers(const EventContext& ctx,
72 SG::WriteCondHandle<Trk::TrackingGeometry>& whandle) const override final;
73
75 virtual std::unique_ptr<const std::vector<Trk::PlaneLayer*> >
76 planarLayers(const EventContext& ctx,
77 SG::WriteCondHandle<Trk::TrackingGeometry>& whandle) const override final;
78
80 virtual const std::string& identification() const override final;
81
82 private:
85 const Trk::BinnedLayerMaterial discLayerMaterial(double rMin, double rMax) const;
86
88 void registerSurfacesToLayer( std::span<Trk::Surface * const>& surfaces,const Trk::Layer& layer) const;
89
90 static void evaluateBestBinning(std::vector<Trk::SurfaceOrderPosition>& surfaces,
91 std::vector<float>& rBins,
92 float& maxRadius,
93 std::vector<std::vector<float>>& phiBins) ;
94
97
99
101
104
107
109
110 SG::ReadCondHandleKey<InDetDD::HGTD_DetectorElementCollection>
112 this,
113 "HGTD_ReadKey",
114 "HGTD_DetectorElementCollection",
115 "Key of output HGTD_DetectorElementCollection for HGTD"
116 };
117};
118
119inline std::unique_ptr<const std::vector<Trk::CylinderLayer*> >
122{
123 return nullptr;
124}
125
126inline std::unique_ptr<const std::vector<Trk::PlaneLayer*> >
129{
130 return nullptr;
131}
132
133inline const std::string& HGTD_LayerBuilderCond::identification() const
134{ return m_identification; }
135
136#endif // HGTD_TRACKINGGEOMETRY_HGTDLAYERBUILDERCOND_H
DataVector< HGTD_DetectorElement > HGTD_DetectorElementCollection
Define macros for attributes used to control the static checker.
#define ATLAS_NOT_THREAD_SAFE
getNoisyStrip() Find noisy strips from hitmaps and write out into xml/db formats
The Detector manager has methods to retrieve the Identifier helper and methods to retrieve the detect...
This is an Identifier helper class for the HGTD subdetector.
Definition HGTD_ID.h:47
virtual const std::string & identification() const override final
Name identification.
virtual std::unique_ptr< const std::vector< Trk::PlaneLayer * > > planarLayers(const EventContext &ctx, SG::WriteCondHandle< Trk::TrackingGeometry > &whandle) const override final
LayerBuilder interface method - returning Planar-like layers.
int m_phiBins
set the number of bins
bool m_setLayerAssociation
Set Layer Association.
bool m_runGeometryValidation
run geometry validation
float m_discEnvelopeR
set disc envelope
float m_discThickness
set disc thickness
virtual std::unique_ptr< const std::vector< Trk::DiscLayer * > > discLayers(const EventContext &ctx, SG::WriteCondHandle< Trk::TrackingGeometry > &whandle) const override final
LayerBuilder interface method - returning Endcap-like layers.
SG::ReadCondHandle< InDetDD::HGTD_DetectorElementCollection > retrieveHGTDdetElements(const EventContext &ctx) const
helper method to construct HGTD materia
void registerSurfacesToLayer(std::span< Trk::Surface *const > &surfaces, const Trk::Layer &layer) const
HGTD_LayerBuilderCond(const std::string &, const std::string &, const IInterface *)
AlgTool style constructor.
virtual ~HGTD_LayerBuilderCond()
Destructor.
int m_rBins
set the number of bins
const HGTD_ID * m_hgtdHelper
HGTD Id Helper.
std::string m_identification
string identification
const HGTD_DetectorManager * m_hgtdMgr
the HGTD Detector Manager
static void evaluateBestBinning(std::vector< Trk::SurfaceOrderPosition > &surfaces, std::vector< float > &rBins, float &maxRadius, std::vector< std::vector< float > > &phiBins)
virtual std::unique_ptr< const std::vector< Trk::CylinderLayer * > > cylindricalLayers(const EventContext &ctx, SG::WriteCondHandle< Trk::TrackingGeometry > &whandle) const override final
LayerBuilder interface method - returning Barrel-like layers.
SG::ReadCondHandleKey< InDetDD::HGTD_DetectorElementCollection > m_HGTD_ReadKey
const Trk::BinnedLayerMaterial discLayerMaterial(double rMin, double rMax) const
layer association
It extends the LayerMaterialProperties base class.
Class to describe a cylindrical detector layer for tracking, it inhertis from both,...
Class to describe a disc-like detector layer for tracking, it inhertis from both, Layer base class an...
Definition DiscLayer.h:45
Class to describe a planar detector layer for tracking, it inhertis from both, Layer base class and P...
Definition PlaneLayer.h:40
Abstract Base Class for tracking surfaces.
Eigen::Matrix< double, 3, 1 > Vector3D
Message Stream Member.
Forward declaration.
Ensure that the ATLAS eigen extensions are properly loaded.
std::pair< std::shared_ptr< Surface >, Amg::Vector3D > SurfaceOrderPosition
STL namespace.
void initialize()
#define private