CMS 3D CMS Logo

EcalBarrelGeometry.h
Go to the documentation of this file.
1 #ifndef EcalBarrelGeometry_h
2 #define EcalBarrelGeometry_h
3 
16 #include <vector>
17 #include <atomic>
18 
20 public:
21  typedef std::vector<TruncatedPyramid> CellVec;
22 
26 
31 
32  typedef EZArrayFL<EEDetId> OrderedListOfEEDetId; // like an stl vector: begin(), end(), [i]
33 
34  typedef std::vector<OrderedListOfEEDetId*> VecOrdListEEDetIdPtr;
35 
37 
38  typedef EBDetId DetIdType;
39 
41 
42  enum { k_NumberOfShapes = 17 };
43 
45 
46  static std::string dbString() { return "PEcalBarrelRcd"; }
47 
48  unsigned int numberOfShapes() const override { return k_NumberOfShapes; }
49  unsigned int numberOfParametersPerShape() const override { return k_NumberOfParametersPerShape; }
50 
52 
53  ~EcalBarrelGeometry() override;
54 
55  int getNumXtalsPhiDirection() const { return _nnxtalPhi; }
56 
57  int getNumXtalsEtaDirection() const { return _nnxtalEta; }
58 
59  const std::vector<int>& getEtaBaskets() const { return _EtaBaskets; }
60 
61  int getBasketSizeInPhi() const { return _PhiBaskets; }
62 
63  void setNumXtalsPhiDirection(const int& nnxtalPhi) { _nnxtalPhi = nnxtalPhi; }
64 
65  void setNumXtalsEtaDirection(const int& nnxtalEta) { _nnxtalEta = nnxtalEta; }
66 
67  void setEtaBaskets(const std::vector<int>& EtaBaskets) { _EtaBaskets = EtaBaskets; }
68 
69  void setBasketSizeInPhi(const int& PhiBaskets) { _PhiBaskets = PhiBaskets; }
70 
72 
73  // Get closest cell, etc...
74 
75  DetId getClosestCell(const GlobalPoint& r) const override;
76 
77  CaloSubdetectorGeometry::DetIdSet getCells(const GlobalPoint& r, double dR) const override;
78 
80 
81  static std::string hitString() { return "EcalHitsEB"; }
82 
83  static std::string producerTag() { return "EcalBarrel"; }
84 
85  static unsigned int numberOfAlignments() { return 36; }
86 
87  static unsigned int alignmentTransformIndexLocal(const DetId& id);
88 
89  static unsigned int alignmentTransformIndexGlobal(const DetId& id);
90 
91  static DetId detIdFromLocalAlignmentIndex(unsigned int iLoc);
92 
93  static void localCorners(Pt3DVec& lc, const CCGFloat* pv, unsigned int i, Pt3D& ref);
94 
95  void newCell(const GlobalPoint& f1,
96  const GlobalPoint& f2,
97  const GlobalPoint& f3,
98  const CCGFloat* parm,
99  const DetId& detId) override;
100 
101  bool present(const DetId& id) const override;
102 
103 protected:
104  // Modify the RawPtr class
105  const CaloCellGeometry* getGeometryRawPtr(uint32_t index) const override;
106 
107 private:
110 
113 
118  std::vector<int> _EtaBaskets;
119 
122 
123  mutable std::atomic<EZMgrFL<EEDetId>*> m_borderMgr;
124 
125  mutable std::atomic<VecOrdListEEDetIdPtr*> m_borderPtrVec;
127  mutable std::atomic<bool> m_check;
128 
130 };
131 
132 #endif
CaloCellGeometry::Pt3DVec
std::vector< Pt3D > Pt3DVec
Definition: CaloCellGeometry.h:55
EcalBarrelNumberingScheme
Definition: EcalBarrelNumberingScheme.h:10
EZArrayFL.h
PEcalBarrelRcd.h
mps_fire.i
i
Definition: mps_fire.py:428
EcalBarrelGeometry::Pt3DVec
CaloCellGeometry::Pt3DVec Pt3DVec
Definition: EcalBarrelGeometry.h:25
CaloCellGeometry::CCGFloat
float CCGFloat
Definition: CaloCellGeometry.h:52
EcalBarrelGeometry::getClosestEndcapCells
const OrderedListOfEEDetId * getClosestEndcapCells(EBDetId id) const
Definition: EcalBarrelGeometry.cc:338
EcalBarrelGeometry::CCGFloat
CaloCellGeometry::CCGFloat CCGFloat
Definition: EcalBarrelGeometry.h:23
EcalBarrelGeometry::AlignedRecord
EcalBarrelGeometryRecord AlignedRecord
Definition: EcalBarrelGeometry.h:28
CaloSubdetectorGeometry::DetIdSet
std::set< DetId > DetIdSet
Definition: CaloSubdetectorGeometry.h:27
EcalBarrelGeometry::setBasketSizeInPhi
void setBasketSizeInPhi(const int &PhiBaskets)
Definition: EcalBarrelGeometry.h:69
EcalBarrelGeometry::Pt3D
CaloCellGeometry::Pt3D Pt3D
Definition: EcalBarrelGeometry.h:24
EcalBarrelGeometry::~EcalBarrelGeometry
~EcalBarrelGeometry() override
Definition: EcalBarrelGeometry.cc:33
EBDetId
Definition: EBDetId.h:17
EcalBarrelGeometry::getBasketSizeInPhi
int getBasketSizeInPhi() const
Definition: EcalBarrelGeometry.h:61
EcalBarrelGeometry::setEtaBaskets
void setEtaBaskets(const std::vector< int > &EtaBaskets)
Definition: EcalBarrelGeometry.h:67
CCGFloat
CaloCellGeometry::CCGFloat CCGFloat
Definition: CaloCellGeometry.cc:4
EcalBarrelGeometry::numberOfAlignments
static unsigned int numberOfAlignments()
Definition: EcalBarrelGeometry.h:85
EBDetId.h
EEDetId.h
EcalBarrelGeometry::alignmentTransformIndexGlobal
static unsigned int alignmentTransformIndexGlobal(const DetId &id)
Definition: EcalBarrelGeometry.cc:59
EcalBarrelGeometry::PGeometryRecord
PEcalBarrelRcd PGeometryRecord
Definition: EcalBarrelGeometry.h:30
EcalBarrelGeometry::alignmentTransformIndexLocal
static unsigned int alignmentTransformIndexLocal(const DetId &id)
Definition: EcalBarrelGeometry.cc:45
EcalBarrelGeometry::NumberingScheme
EcalBarrelNumberingScheme NumberingScheme
Definition: EcalBarrelGeometry.h:36
EcalBarrelGeometry::_nnxtalPhi
int _nnxtalPhi
Definition: EcalBarrelGeometry.h:112
EZArrayFL
Definition: EZArrayFL.h:20
EcalBarrelGeometry::setNumXtalsEtaDirection
void setNumXtalsEtaDirection(const int &nnxtalEta)
Definition: EcalBarrelGeometry.h:65
EcalBarrelGeometry::avgRadiusXYFrontFaceCenter
CCGFloat avgRadiusXYFrontFaceCenter() const
Definition: EcalBarrelGeometry.cc:419
EcalBarrelGeometry::getCells
CaloSubdetectorGeometry::DetIdSet getCells(const GlobalPoint &r, double dR) const override
Get a list of all cells within a dR of the given cell.
Definition: EcalBarrelGeometry.cc:266
EcalBarrelGeometryRecord
Definition: EcalBarrelGeometryRecord.h:23
EcalBarrelGeometry::m_borderPtrVec
std::atomic< VecOrdListEEDetIdPtr * > m_borderPtrVec
Definition: EcalBarrelGeometry.h:125
Pt3D
CaloCellGeometry::Pt3D Pt3D
Definition: CaloCellGeometry.cc:5
DetId
Definition: DetId.h:17
EcalBarrelGeometry::_EtaBaskets
std::vector< int > _EtaBaskets
Definition: EcalBarrelGeometry.h:118
CaloSubdetectorGeometry::CCGFloat
CaloCellGeometry::CCGFloat CCGFloat
Definition: CaloSubdetectorGeometry.h:25
EcalBarrelGeometry::getNumXtalsEtaDirection
int getNumXtalsEtaDirection() const
Definition: EcalBarrelGeometry.h:57
EcalBarrelGeometry::numberOfParametersPerShape
unsigned int numberOfParametersPerShape() const override
Definition: EcalBarrelGeometry.h:49
EcalBarrelGeometry::OrderedListOfEEDetId
EZArrayFL< EEDetId > OrderedListOfEEDetId
Definition: EcalBarrelGeometry.h:32
TruncatedPyramid.h
EcalBarrelGeometryRecord.h
EcalBarrelGeometry::m_check
std::atomic< bool > m_check
Definition: EcalBarrelGeometry.h:127
EcalBarrelGeometry::m_radius
CCGFloat m_radius
Definition: EcalBarrelGeometry.h:126
Point3DBase< float, GlobalTag >
EcalBarrelGeometry::DetIdType
EBDetId DetIdType
Definition: EcalBarrelGeometry.h:38
CaloCellGeometry::Pt3D
HepGeom::Point3D< CCGFloat > Pt3D
Definition: CaloCellGeometry.h:54
EcalBarrelGeometry::getClosestCell
DetId getClosestCell(const GlobalPoint &r) const override
Definition: EcalBarrelGeometry.cc:63
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
EcalBarrelGeometry::getNumXtalsPhiDirection
int getNumXtalsPhiDirection() const
Definition: EcalBarrelGeometry.h:55
PEcalBarrelRcd
Definition: PEcalBarrelRcd.h:5
EcalBarrelGeometry::producerTag
static std::string producerTag()
Definition: EcalBarrelGeometry.h:83
CaloSubdetectorGeometry.h
EcalBarrelGeometry::k_NumberOfShapes
Definition: EcalBarrelGeometry.h:42
EcalBarrelGeometry::setNumXtalsPhiDirection
void setNumXtalsPhiDirection(const int &nnxtalPhi)
Definition: EcalBarrelGeometry.h:63
EcalBarrelNumberingScheme.h
EcalBarrelGeometry
Definition: EcalBarrelGeometry.h:19
CaloCellGeometry
Definition: CaloCellGeometry.h:50
DeadROC_duringRun.f2
f2
Definition: DeadROC_duringRun.py:220
thread_safety_macros.h
EcalBarrelGeometry::newCell
void newCell(const GlobalPoint &f1, const GlobalPoint &f2, const GlobalPoint &f3, const CCGFloat *parm, const DetId &detId) override
Definition: EcalBarrelGeometry.cc:412
EBAlignmentRcd.h
MetAnalyzer.pv
def pv(vc)
Definition: MetAnalyzer.py:7
EcalBarrelGeometry::detIdFromLocalAlignmentIndex
static DetId detIdFromLocalAlignmentIndex(unsigned int iLoc)
Definition: EcalBarrelGeometry.cc:55
EcalBarrelGeometry::present
bool present(const DetId &id) const override
is this detid present in the geometry?
Definition: EcalBarrelGeometry.cc:441
EcalBarrelGeometry::_nnxtalEta
int _nnxtalEta
Definition: EcalBarrelGeometry.h:109
IdealGeometryRecord.h
EcalBarrelGeometry::hitString
static std::string hitString()
Definition: EcalBarrelGeometry.h:81
alignCSCRings.r
r
Definition: alignCSCRings.py:93
EcalBarrelGeometry::dbString
static std::string dbString()
Definition: EcalBarrelGeometry.h:46
EcalBarrelGeometry::getGeometryRawPtr
const CaloCellGeometry * getGeometryRawPtr(uint32_t index) const override
Definition: EcalBarrelGeometry.cc:435
EcalBarrelGeometry::m_cellVec
CellVec m_cellVec
Definition: EcalBarrelGeometry.h:129
EBAlignmentRcd
Definition: EBAlignmentRcd.h:6
CaloSubdetectorGeometry
Definition: CaloSubdetectorGeometry.h:22
EBDetId::kSizeForDenseIndexing
Definition: EBDetId.h:155
EcalBarrelGeometry::k_NumberOfCellsForCorners
Definition: EcalBarrelGeometry.h:40
AlignmentPI::index
index
Definition: AlignmentPayloadInspectorHelper.h:46
EcalBarrelGeometry::numberOfShapes
unsigned int numberOfShapes() const override
Definition: EcalBarrelGeometry.h:48
EcalBarrelGeometry::CellVec
std::vector< TruncatedPyramid > CellVec
Definition: EcalBarrelGeometry.h:21
Pt3DVec
CaloCellGeometry::Pt3DVec Pt3DVec
Definition: CaloCellGeometry.cc:6
EcalBarrelGeometry::_PhiBaskets
int _PhiBaskets
Definition: EcalBarrelGeometry.h:121
EcalBarrelGeometry::localCorners
static void localCorners(Pt3DVec &lc, const CCGFloat *pv, unsigned int i, Pt3D &ref)
Definition: EcalBarrelGeometry.cc:401
HGC3DClusterGenMatchSelector_cfi.dR
dR
Definition: HGC3DClusterGenMatchSelector_cfi.py:7
EcalBarrelGeometry::m_borderMgr
std::atomic< EZMgrFL< EEDetId > * > m_borderMgr
Definition: EcalBarrelGeometry.h:123
DeadROC_duringRun.f1
f1
Definition: DeadROC_duringRun.py:219
EcalBarrelGeometry::IdealRecord
IdealGeometryRecord IdealRecord
Definition: EcalBarrelGeometry.h:27
EcalBarrelGeometry::VecOrdListEEDetIdPtr
std::vector< OrderedListOfEEDetId * > VecOrdListEEDetIdPtr
Definition: EcalBarrelGeometry.h:34
CMS_THREAD_GUARD
#define CMS_THREAD_GUARD(_var_)
Definition: thread_safety_macros.h:6
EcalBarrelGeometry::EcalBarrelGeometry
EcalBarrelGeometry()
Definition: EcalBarrelGeometry.cc:20
IdealGeometryRecord
Definition: IdealGeometryRecord.h:25
EcalBarrelGeometry::getEtaBaskets
const std::vector< int > & getEtaBaskets() const
Definition: EcalBarrelGeometry.h:59
EcalBarrelGeometry::AlignmentRecord
EBAlignmentRcd AlignmentRecord
Definition: EcalBarrelGeometry.h:29
EcalBarrelGeometry::k_NumberOfParametersPerShape
Definition: EcalBarrelGeometry.h:44