ATLAS Offline Software
Loading...
Searching...
No Matches
RingSetConf_v1.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3*/
4#ifndef XAODCALORINGS_VERSIONS_RINGSETCONF_V1_H
5#define XAODCALORINGS_VERSIONS_RINGSETCONF_V1_H
6
7// std includes:
8#include <vector>
9#include <iosfwd>
10
11// Athena framework includes:
12#include "CaloGeoHelpers/CaloSampling.h"
14
15// EDM include(s):
18
19// local includes:
21
22namespace xAOD {
23
24// Forward declare the container type:
25class RingSetConf_v1;
27
36
37 public:
38
41
49 struct RawConf {
51 unsigned nRings;
53 std::vector<CaloSampling::CaloSample> layers;
55 float etaWidth;
57 float phiWidth;
71 unsigned layerStartIdx;
73 unsigned layerEndIdx;
77 unsigned sectionEndIdx;
78
81
84 RawConf();
92 RawConf(const unsigned nRings,
93 const std::vector<CaloSampling::CaloSample> &layers,
94 const float etaWidth, const float phiWidth,
95 const float cellMaxDEtaDist, const float cellMaxDPhiDist,
98 const bool doEtaAxesDivision = false,
99 const bool doPhiAxesDivision = false);
103 RawConf(const unsigned nRings,
104 const std::vector<CaloSampling::CaloSample> &layers,
105 const float etaWidth, const float phiWidth,
106 const float cellMaxDEtaDist, const float cellMaxDPhiDist,
109 const bool doEtaAxesDivision,
110 const bool doPhiAxesDivision,
111 const unsigned layerStartIdx,
112 const unsigned layerEndIdx,
113 const unsigned sectionStartIdx,
114 const unsigned sectionEndIdx);
118 RawConf(const RingSetConf_v1 &rsConf);
120
121 };
122
124 typedef std::vector<RawConf> RawConfCollection;
126
132 static bool isEMSection (const std::vector<CaloSampling::CaloSample> &layers);
133 static bool isHADSection(const std::vector<CaloSampling::CaloSample> &layers);
134 static bool isPSLayer (const std::vector<CaloSampling::CaloSample> &layers);
135 static bool isEM1Layer (const std::vector<CaloSampling::CaloSample> &layers);
136 static bool isEM2Layer (const std::vector<CaloSampling::CaloSample> &layers);
137 static bool isEM3Layer (const std::vector<CaloSampling::CaloSample> &layers);
138 static bool isHAD1Layer (const std::vector<CaloSampling::CaloSample> &layers);
139 static bool isHAD2Layer (const std::vector<CaloSampling::CaloSample> &layers);
140 static bool isHAD3Layer (const std::vector<CaloSampling::CaloSample> &layers);
145 const std::vector<CaloSampling::CaloSample> &layers);
147 const std::vector<CaloSampling::CaloSample> &layers);
151 static void print( const RawConf &raw, std::ostream &stream);
153
156 static unsigned totalNumberOfRings( const RawConfCollection &clRingsConf );
160 static void getEdges( const RawConfCollection &clRingsConf,
161 const Ringer::CalJointSection sec,
162 unsigned &startEdge,
163 unsigned &endEdge);
167 static void getEdges( const RawConfCollection &clRingsConf,
168 const Ringer::CalJointLayer layer,
169 unsigned &startEdge,
170 unsigned &endEdge);
174 static void addRawConfColBounderies( RawConfCollection &clRingsConf );
177 static void print( const RawConfCollection &raw, std::ostream &stream );
179
182 static void fillRingSetConfContainer(
183 const RawConfCollection &rawConfCol,
188 static void getRawConfCol(RawConfCollection &rawConfCol,
191
192
195
202 RingSetConf_v1(const RingSetConf_v1& ringset);
206 RingSetConf_v1(const unsigned nRings,
207 const std::vector<CaloSampling::CaloSample> &rsLayers,
208 const float etaWidth, const float phiWidth,
209 const float cellMaxDEtaDist, const float cellMaxDPhiDist,
212 const bool doEtaAxesDivision, const bool doPhiAxesDivision,
213 const unsigned layerStartIdx, const unsigned layerEndIdx,
214 const unsigned sectionStartIdx, const unsigned sectionEndIdx);
218 RingSetConf_v1(const RawConf &confStruct);
220
221
225
228
233 unsigned nRings() const;
239 void setNRings(unsigned nRings);
241
244
247 unsigned nLayers() const;
253 const std::vector< CaloSampling::CaloSample >& layers() const;
259 void setLayers(const std::vector< CaloSampling::CaloSample > &layers);
263 CaloSampling::CaloSample layerAt(const unsigned idx) const;
271 void clearLayers();
273
276
283 float etaWidth() const;
291 float phiWidth() const;
297 void setEtaWidth(float etaWidth);
309 float cellMaxDEtaDist() const;
315 float cellMaxDPhiDist() const;
333 bool doEtaAxesDivision() const;
345 bool doPhiAxesDivision() const;
353
356
373
377
384 unsigned layerStartIdx() const;
385
391 unsigned sectionStartIdx() const;
392
400 unsigned layerEndIdx() const;
401
409 unsigned sectionEndIdx() const;
410
436
438
441 void print( std::ostream &stream ) const;
443
446
451
454
457 RingSetConf_v1& operator=(const RingSetConf_v1& clrings);
459
460};
461
464//==============================================================================
465inline
467
468//==============================================================================
469inline
471 SG::AuxElement(ringsetconf)
472{
473 this->makePrivateStore(ringsetconf);
474}
475
476//==============================================================================
477inline
479 : nRings(0),
480 etaWidth(0),
481 phiWidth(0),
484 calJointLayer(Ringer::CalJointLayer::UnknownJointLayer),
485 calJointSection(Ringer::CalJointSection::UnknownJointSection),
486 doEtaAxesDivision(false),
487 doPhiAxesDivision(false),
488 layerStartIdx(0),
489 layerEndIdx(0),
491 sectionEndIdx(0){;}
492
493
494} // End of namespace xAOD
495
496#include "xAODCore/BaseInfo.h"
498
499#endif // XAODCALORINGS_VERSIONS_RINGSETCONF_V1_H
500
Base class for elements of a container that can have aux data.
#define SG_BASE(D, B)
Declare that class D derives from class B.
An STL vector of pointers that by default owns its pointed-to elements.
Base class for elements of a container that can have aux data.
Definition AuxElement.h:483
void makePrivateStore()
Create a new (empty) private store for this object.
const SG::AuxVectorData * container() const
Return the container holding this element.
AuxElement()
Default constructor.
Class holding the RingSet configuration used for the Reconstruction.
Ringer::CalJointSection calJointSection() const
Retrieve this RingSet conf CalJointSection.
unsigned layerEndIdx() const
Returns end of section index for this RingSet Configuration when this configuration is concatened int...
void setEtaWidth(float etaWidth)
Set etaWidth.
unsigned layerStartIdx() const
Returns start of layer index for this RingSet Configuration when this configuration is concatened int...
const RingSetConf_v1::RawConf getRawConf() const
Retrieve raw RingSet Configuration struct.
CaloSampling::CaloSample layerAt(const unsigned idx) const
Get ith layer.
std::vector< RawConf > RawConfCollection
typedef The raw configuration structure data holder
static bool isPSLayer(const std::vector< CaloSampling::CaloSample > &layers)
void setCellMaxDEtaDist(float cellMaxDEtaDist)
Set maxCellDEtaDist.
static bool isEMSection(const std::vector< CaloSampling::CaloSample > &layers)
Static methods:
static bool isHADSection(const std::vector< CaloSampling::CaloSample > &layers)
unsigned nRings() const
Get nRings.
static bool isEM3Layer(const std::vector< CaloSampling::CaloSample > &layers)
float cellMaxDEtaDist() const
Return the maximun cell distance in eta w.r.t seed.
static Ringer::CalJointLayer whichLayer(const std::vector< CaloSampling::CaloSample > &layers)
unsigned sectionEndIdx() const
Returns end of section index for this RingSet Configuration when this configuration is concatened int...
static void print(const RawConf &raw, std::ostream &stream)
Prints rawConf.
unsigned nLayers() const
RingSet layers size:
RingSetConf_v1 & operator=(const RingSetConf_v1 &clrings)
Assignment Operator.
float cellMaxDPhiDist() const
Return the maximun cell distance in phi w.r.t seed.
static Ringer::CalJointSection whichSection(const std::vector< CaloSampling::CaloSample > &layers)
void setLayerEndIdx(unsigned layerEndIdx)
Set end layer configuration index.
static void getRawConfCol(RawConfCollection &rawConfCol, const RingSetConfContainer_v1 *container)
Retrieve RawConfCollection from RingSetConf container.
void addLayer(const CaloSampling::CaloSample c)
Add layer.
static bool isHAD2Layer(const std::vector< CaloSampling::CaloSample > &layers)
void setSectionEndIdx(unsigned sectionEndIdx)
Set end section configuration index.
static bool isHAD3Layer(const std::vector< CaloSampling::CaloSample > &layers)
static bool isHAD1Layer(const std::vector< CaloSampling::CaloSample > &layers)
void setCalJointSection(Ringer::CalJointSection calJointSection)
Set this RingSet CalJointSection.
float etaWidth() const
Returns the etaWidth configuration step used for this RingSet.
void setdoPhiAxesDivision(bool doPhiAxesDivision)
Set doPhiAxesDivision.
bool doEtaAxesDivision() const
Return the etaAxesDivision configuration.
void clearLayers()
Clear layers.
unsigned sectionStartIdx() const
Returns start of section index for this RingSet Configuration when this configuration is concatened i...
void setSectionStartIdx(unsigned sectionEndIdx)
Set start section configuration index.
void setLayers(const std::vector< CaloSampling::CaloSample > &layers)
set layers
RingSetConf_v1()
Empty ctor:
static bool isEM1Layer(const std::vector< CaloSampling::CaloSample > &layers)
static void getEdges(const RawConfCollection &clRingsConf, const Ringer::CalJointSection sec, unsigned &startEdge, unsigned &endEdge)
Get CalJointSection start and end edges.
float phiWidth() const
Returns the phiWidth configuration step used for this RingSet.
void setLayerStartIdx(unsigned layerStartIdx)
Set start layer configuration index.
static void fillRingSetConfContainer(const RawConfCollection &rawConfCol, RingSetConfContainer_v1 &container)
Creates RingSetConfContainer from RawConfCollection.
void setCellMaxDPhiDist(float cellMaxDPhiDist)
Set maxCellDPhiDist.
static void addRawConfColBounderies(RawConfCollection &clRingsConf)
Add to RawConfCollection its JointLayer/JointSection bounderies.
const std::vector< CaloSampling::CaloSample > & layers() const
get layers
Ringer::CalJointLayer calJointLayer() const
Retrieve this RingSet conf CalJointLayer.
void setPhiWidth(float phiWidth)
Set phiWidth.
bool doPhiAxesDivision() const
Return the phiAxesDivision configuration.
void setNRings(unsigned nRings)
Set nRings.
void setCalJointLayer(Ringer::CalJointLayer calJointLayer)
Set this RingSet CalJointLayer.
void setdoEtaAxesDivision(bool doEtaAxesDivision)
Set doEtaAxesDivision.
static bool isEM2Layer(const std::vector< CaloSampling::CaloSample > &layers)
static unsigned totalNumberOfRings(const RawConfCollection &clRingsConf)
Get the totalNumber of Rings contained in this configuration:
Namespace dedicated for Ringer utilities.
CalJointLayer
the joint calorimeter layers.
CalJointSection
the joint calorimeter sections.
Forward declaration.
ICaloAffectedTool is abstract interface for tools checking if 4 mom is in calo affected region.
DataVector< xAOD::RingSetConf_v1 > RingSetConfContainer_v1
The container is a simple typedef for now.
unsigned sectionEndIdx
Hold the end of this section on a non-segmented representation:
float cellMaxDEtaDist
Maximum distance cell in eta to seed.
unsigned sectionStartIdx
Hold the start of this section on a non-segmented representation:
bool doPhiAxesDivision
Hold the option of phi axes division.
float cellMaxDPhiDist
Maximum distance cell in phi to seed.
bool doEtaAxesDivision
Hold the option of eta axes division.
Ringer::CalJointSection calJointSection
The Calorimeter Joint Section (see CaloRingsDefs.h)
RawConf()
Configuration Struct ctors.
Ringer::CalJointLayer calJointLayer
The Calorimeter Joint Layer of this RingSet (see CaloRingsDefs.h)
unsigned nRings
Ringset number of Rings.
float etaWidth
Ring Width in eta.
unsigned layerStartIdx
Hold the start of this layer on a non-segmented representation:
float phiWidth
Ring Width in phi.
std::vector< CaloSampling::CaloSample > layers
Ringset layers.
unsigned layerEndIdx
Hold the end of this layer on a non-segmented representation: