ATLAS Offline Software
Loading...
Searching...
No Matches
ActsTrk::CaloBlueprintNodeBuilder Class Reference

Builds the Calo Blueprint Node. More...

#include <CaloBlueprintNodeBuilder.h>

Inheritance diagram for ActsTrk::CaloBlueprintNodeBuilder:
Collaboration diagram for ActsTrk::CaloBlueprintNodeBuilder:

Public Member Functions

StatusCode initialize () override
StatusCode finalize () override
std::shared_ptr< Acts::Experimental::BlueprintNode > buildBlueprintNode (const Acts::GeometryContext &gctx, std::shared_ptr< Acts::Experimental::BlueprintNode > &&childNode) override
 Build the Itk Blueprint Node.

Private Member Functions

void fillMaps (caloSampleSurfaceMap_t &caloSampleSurfaceMap, caloSampleDDEElementsMap_t &caloSampleDDEElementsMap) const
 fillMaps fills two maps.
void fillCaloDimensionsMap (caloDimensionMap_t &caloDimensionsMap, caloSampleDDEElementsMap_t &caloSampleDDEElementsMap) const
 fillCaloDimensionsMap fills a map of calorimeter dimensions for each sampling layer.
void generateCylinderSurfaces (caloSampleSurfaceMap_t &caloSampleSurfaceMap, caloSampleDDEElementsMap_t &caloSampleDDEElementsMap) const
 generateCylinderSurfaces generates cylindrical surfaces for each calo sampling.
std::shared_ptr< Acts::CylinderSurface > generateCylinderSurface (const double &maxLArBRadius, const double &minLArBRadius, const double &lowZLarB, const double &highZLarB) const
 generateCylinderSurface generates a cylindrical surface for a given set of parameters.
void addCylindricalTrackingVolumeToCaloNode (Acts::Experimental::CylinderContainerBlueprintNode &containerNode, caloDimensionMap_t &caloDimensionMap, const std::string &volumeName, const std::vector< std::shared_ptr< Acts::Surface > > &surfaces) const
 addCylindricalTrackingVolumeToCaloNode adds a cylindrical tracking volume to the calo node.

Private Attributes

std::unique_ptr< CaloDetDescrManagerm_caloDetSecrMgr
std::vector< CaloCell_ID::CaloSamplem_caloDiscSampleList
std::vector< CaloCell_ID::CaloSamplem_caloCylinderSampleList
Gaudi::Property< double > m_radiusTolerance
Gaudi::Property< double > m_zTolerance

Detailed Description

Builds the Calo Blueprint Node.

Definition at line 25 of file CaloBlueprintNodeBuilder.h.

Member Function Documentation

◆ addCylindricalTrackingVolumeToCaloNode()

void ActsTrk::CaloBlueprintNodeBuilder::addCylindricalTrackingVolumeToCaloNode ( Acts::Experimental::CylinderContainerBlueprintNode & containerNode,
caloDimensionMap_t & caloDimensionMap,
const std::string & volumeName,
const std::vector< std::shared_ptr< Acts::Surface > > & surfaces ) const
private

addCylindricalTrackingVolumeToCaloNode adds a cylindrical tracking volume to the calo node.

It takes as input the container node, the calo dimensions map, the name of the volume and the vector of surfaces to be added to the volume. It creates a new CylinderContainerBlueprintNode in the container node, then creates a new Acts::TrackingVolume with the appropriate dimensions. Finally it adds the Acts::CylinderSurface to that Acts::TrackingVolume, then adds the tracking volume to the container node.

Definition at line 326 of file CaloBlueprintNodeBuilder.cxx.

326 {
327
328 CylinderContainerBlueprintNode& cylinder = containerNode.addCylinderContainer(volumeName, AxisDirection::AxisZ);
329
330 ATH_MSG_DEBUG("Creating TrackingVolume for " << volumeName << " with minR, maxR and halfLengthZ of " << caloDimensionMap[volumeName+"MinR"] << ", " << caloDimensionMap[volumeName+"MaxR"] << " and " << caloDimensionMap[volumeName+"HalfLengthZ"]);
331
332 auto trackingVolume = std::make_unique<TrackingVolume>(
333 Transform3::Identity(),
334 std::make_shared<CylinderVolumeBounds>(caloDimensionMap[volumeName+"MinR"], caloDimensionMap[volumeName+"MaxR"], caloDimensionMap[volumeName+"HalfLengthZ"]),
335 volumeName);
336
337 for (auto surface : surfaces) trackingVolume->addSurface(std::move(surface));
338
339
340 cylinder.addStaticVolume(std::move(trackingVolume));
341
342}
#define ATH_MSG_DEBUG(x)

◆ buildBlueprintNode()

std::shared_ptr< BlueprintNode > ActsTrk::CaloBlueprintNodeBuilder::buildBlueprintNode ( const Acts::GeometryContext & gctx,
std::shared_ptr< Acts::Experimental::BlueprintNode > && childNode )
override

Build the Itk Blueprint Node.

Parameters
gctxGeometry context
childThe child node which is added to the itk node.

Definition at line 32 of file CaloBlueprintNodeBuilder.cxx.

33 {
34
35 caloSampleSurfaceMap_t caloSampleSurfaceMap;
36 caloSampleDDEElementsMap_t caloSampleDDEElementsMap;
37 fillMaps(caloSampleSurfaceMap, caloSampleDDEElementsMap);
38
39 ATH_MSG_DEBUG("Have filled first two maps");
40
41 caloDimensionMap_t caloDimensionMap;
42 fillCaloDimensionsMap(caloDimensionMap, caloSampleDDEElementsMap);
43
44 ATH_MSG_DEBUG("Have filled calo dimensions map");
45
46 generateCylinderSurfaces(caloSampleSurfaceMap, caloSampleDDEElementsMap);
47
48 ATH_MSG_DEBUG("Have generated calorimeter cylindrical surfaces");
49
50 //The calo node is a container node that will hold the calo layers
51 auto caloNode = std::make_shared<CylinderContainerBlueprintNode>("CaloNode", AxisDirection::AxisR);
52 if (childNode) caloNode->addChild(std::move(childNode));
53
54 ATH_MSG_DEBUG("Top level calorimeter node created");
55
56 CylinderContainerBlueprintNode& EMBarrelCylinder = caloNode->addCylinderContainer("EMBarrel", AxisDirection::AxisR);
57 // Use Gap attachment strategy to fill gaps between layers
58 EMBarrelCylinder.setAttachmentStrategy(VolumeAttachmentStrategy::Gap);
59
60 ATH_MSG_DEBUG("EM Barrel container node created");
61
62 //Add all cylindrical layers that are symmetric about zero in Z.
63 addCylindricalTrackingVolumeToCaloNode(EMBarrelCylinder, caloDimensionMap, "PreSamplerB", caloSampleSurfaceMap[CaloCell_ID::PreSamplerB]);
64 addCylindricalTrackingVolumeToCaloNode(EMBarrelCylinder, caloDimensionMap, "EMB1", caloSampleSurfaceMap[CaloCell_ID::EMB1]);
65 addCylindricalTrackingVolumeToCaloNode(EMBarrelCylinder, caloDimensionMap, "EMB2", caloSampleSurfaceMap[CaloCell_ID::EMB2]);
66 addCylindricalTrackingVolumeToCaloNode(EMBarrelCylinder, caloDimensionMap, "EMB3", caloSampleSurfaceMap[CaloCell_ID::EMB3]);
67 addCylindricalTrackingVolumeToCaloNode(EMBarrelCylinder, caloDimensionMap, "TileBar0", caloSampleSurfaceMap[CaloCell_ID::TileBar0]);
68 addCylindricalTrackingVolumeToCaloNode(EMBarrelCylinder, caloDimensionMap, "TileBar1", caloSampleSurfaceMap[CaloCell_ID::TileBar1]);
69 addCylindricalTrackingVolumeToCaloNode(EMBarrelCylinder, caloDimensionMap, "TileBar2", caloSampleSurfaceMap[CaloCell_ID::TileBar2]);
70
71 ATH_MSG_DEBUG("Have added all Barrel layers to EMBarrelCylinder node");
72
73 return caloNode;
74}
std::map< CaloCell_ID::CaloSample, std::vector< std::shared_ptr< Acts::Surface > > > caloSampleSurfaceMap_t
std::map< CaloCell_ID::CaloSample, std::vector< const CaloDetDescrElement * > > caloSampleDDEElementsMap_t
std::map< std::string, double > caloDimensionMap_t
void fillCaloDimensionsMap(caloDimensionMap_t &caloDimensionsMap, caloSampleDDEElementsMap_t &caloSampleDDEElementsMap) const
fillCaloDimensionsMap fills a map of calorimeter dimensions for each sampling layer.
void generateCylinderSurfaces(caloSampleSurfaceMap_t &caloSampleSurfaceMap, caloSampleDDEElementsMap_t &caloSampleDDEElementsMap) const
generateCylinderSurfaces generates cylindrical surfaces for each calo sampling.
void addCylindricalTrackingVolumeToCaloNode(Acts::Experimental::CylinderContainerBlueprintNode &containerNode, caloDimensionMap_t &caloDimensionMap, const std::string &volumeName, const std::vector< std::shared_ptr< Acts::Surface > > &surfaces) const
addCylindricalTrackingVolumeToCaloNode adds a cylindrical tracking volume to the calo node.
void fillMaps(caloSampleSurfaceMap_t &caloSampleSurfaceMap, caloSampleDDEElementsMap_t &caloSampleDDEElementsMap) const
fillMaps fills two maps.

◆ fillCaloDimensionsMap()

void ActsTrk::CaloBlueprintNodeBuilder::fillCaloDimensionsMap ( caloDimensionMap_t & caloDimensionsMap,
caloSampleDDEElementsMap_t & caloSampleDDEElementsMap ) const
private

fillCaloDimensionsMap fills a map of calorimeter dimensions for each sampling layer.

The map contains minR, maxR, minZ, maxZ and halfLengthZ for each sampling layer.

Definition at line 237 of file CaloBlueprintNodeBuilder.cxx.

237 {
238
239 //initialise parameters we will use to find the dimensions of the calorimeter
240 double minR = 99999999999999;
241 double maxR = 0.0;
242 double minZ = 99999999999999;
243 double maxZ = -99999999999999;
244
245 //define functions we will use
246 auto checkMinR = [&minR](const CaloDetDescrElement* theDDE){double r = theDDE->r();if (r < minR) minR = r;};
247 auto checkMaxR = [&maxR](const CaloDetDescrElement* theDDE){double r = theDDE->r();if (r > maxR) maxR = r;};
248 auto checkMinMaxZ = [&minZ,&maxZ](const CaloDetDescrElement* theDDE){double z = theDDE->z();if (z > maxZ) maxZ = z;if (z < minZ) minZ = z;};
249 auto calcHalfLengthZ = [&minZ, &maxZ](){return (maxZ - minZ) / 2.0;};
250
251 //function to use the above to get minR, maxR and halfLengthZ
252 auto getMinRMaxRHalfLengthZ = [&minR, &maxR, &minZ, &maxZ, &caloSampleDDEElementsMap, &checkMinR, &checkMaxR, &checkMinMaxZ, &calcHalfLengthZ](CaloCell_ID::CaloSample currentSample) {
253
254 minR = 99999999999999;
255 maxR = 0.0;
256 minZ = 99999999999999;
257 maxZ = -99999999999999;
258
259 for (const CaloDetDescrElement* theDDE : caloSampleDDEElementsMap[currentSample]) {
260 checkMinR(theDDE);
261 checkMaxR(theDDE);
262 checkMinMaxZ(theDDE);
263 }
264
265 return calcHalfLengthZ();
266 };
267
268 //find minR from PreSamplerB
269 for (const CaloDetDescrElement* theDDE : caloSampleDDEElementsMap[CaloCell_ID::PreSamplerB]) checkMinR(theDDE);
270
271 //find maxR from TileBar2, TileGap2 and Tile Ext2
272 std::vector<const CaloDetDescrElement*> DDE_TileBar2 = caloSampleDDEElementsMap[CaloCell_ID::TileBar2];
273 std::vector<const CaloDetDescrElement*> DDE_TileGap2 = caloSampleDDEElementsMap[CaloCell_ID::TileGap2];
274 std::vector<const CaloDetDescrElement*> DDE_TileExt2 = caloSampleDDEElementsMap[CaloCell_ID::TileExt2];
275
276 for (auto currentSample : {CaloCell_ID::TileBar2, CaloCell_ID::TileGap2, CaloCell_ID::TileExt2}) {
277 for (const CaloDetDescrElement* theDDE : caloSampleDDEElementsMap[currentSample]) checkMaxR(theDDE);
278 }
279
280 ATH_MSG_DEBUG("Min R in PreSamplerB is " << minR);
281 ATH_MSG_DEBUG("Max R in TileBar2, TileGap2 and TileExt2 is " << maxR);
282
283 caloDimensionsMap["CaloMinR"] = minR;
284 caloDimensionsMap["CaloMaxR"] = maxR;
285
286 //find minZ and maxZ from all barrel samplings
287 for (auto currentSample : {CaloCell_ID::PreSamplerB, CaloCell_ID::EMB1, CaloCell_ID::EMB2, CaloCell_ID::EMB3, CaloCell_ID::TileBar0, CaloCell_ID::TileBar1, CaloCell_ID::TileBar2, CaloCell_ID::TileGap1, CaloCell_ID::TileGap2, CaloCell_ID::TileExt0, CaloCell_ID::TileExt1, CaloCell_ID::TileExt2}) {
288 for (const CaloDetDescrElement* theDDE : caloSampleDDEElementsMap[currentSample]) checkMinMaxZ(theDDE);
289 }
290
291 caloDimensionsMap["CaloMinZ"] = minZ;
292 caloDimensionsMap["CaloMaxZ"] = maxZ;
293
294 double halfLengthZ = calcHalfLengthZ();
295 ATH_MSG_DEBUG("Half length in Z for entire barrel is " << halfLengthZ);
296 caloDimensionsMap["CaloHalfLengthZ"] = halfLengthZ;
297
298 auto putMinRMaxRHalfLengthZInMap = [&caloDimensionsMap,&minR,&maxR,&halfLengthZ](const std::string& sampleString){
299 //PresamplerB, TileBar0/2, TileGap1/2, TileExt0/1/2 return the same radial value for all DDE, so need to make a small offset because a zero thickness
300 //cylinder is not allowed by Acts volumes etc.
301 float smallOffset = 0.1;
302 if (std::fabs((maxR - minR)) < smallOffset) maxR = minR + smallOffset;
303 caloDimensionsMap[sampleString + "MinR"] = minR;
304 caloDimensionsMap[sampleString + "MaxR"] = maxR;
305 caloDimensionsMap[sampleString + "HalfLengthZ"] = halfLengthZ;
306 };
307
308 halfLengthZ = getMinRMaxRHalfLengthZ(CaloCell_ID::PreSamplerB);
309 putMinRMaxRHalfLengthZInMap("PreSamplerB");
310 halfLengthZ = getMinRMaxRHalfLengthZ(CaloCell_ID::EMB1);
311 putMinRMaxRHalfLengthZInMap("EMB1");
312 halfLengthZ = getMinRMaxRHalfLengthZ(CaloCell_ID::EMB2);
313 putMinRMaxRHalfLengthZInMap("EMB2");
314 halfLengthZ = getMinRMaxRHalfLengthZ(CaloCell_ID::EMB3);
315 putMinRMaxRHalfLengthZInMap("EMB3");
316 halfLengthZ = getMinRMaxRHalfLengthZ(CaloCell_ID::TileBar0);
317 putMinRMaxRHalfLengthZInMap("TileBar0");
318 halfLengthZ = getMinRMaxRHalfLengthZ(CaloCell_ID::TileBar1);
319 putMinRMaxRHalfLengthZInMap("TileBar1");
320 halfLengthZ = getMinRMaxRHalfLengthZ(CaloCell_ID::TileBar2);
321 putMinRMaxRHalfLengthZInMap("TileBar2");
322 halfLengthZ = getMinRMaxRHalfLengthZ(CaloCell_ID::TileGap1);
323
324}
#define z
CaloSampling::CaloSample CaloSample
Definition CaloCell_ID.h:53
int r
Definition globals.cxx:22

◆ fillMaps()

void ActsTrk::CaloBlueprintNodeBuilder::fillMaps ( caloSampleSurfaceMap_t & caloSampleSurfaceMap,
caloSampleDDEElementsMap_t & caloSampleDDEElementsMap ) const
private

fillMaps fills two maps.

The first maps each calo sampling to a vector of surfaces (initially empty) The second maps each calo sampling to a vector of CaloDetDescrElements The second map is filled by looping over all DDE in the CaloDetDescrManager and adding each DDE to the vector corresponding to its sampling in the map

Definition at line 81 of file CaloBlueprintNodeBuilder.cxx.

81 {
82
83
84 //loop over all possible calo sampling layers
85 //and create empty vectors of surfaces in the map
86
87 //Create map between each calorimeter sampling and a vector of
88 //cylinder surfaces. We can have N cylinders in a given sampling,
89 //and the value of N is determined by how often the average radius
90 //calculated for a given phi ring, at fixed Z, changes by more than
91 //a tolerance value
92
93 //Use the same loop to create map bwteeen sampling and vectors of DDE
94 for (auto currentSample : m_caloCylinderSampleList) {
95 caloSampleSurfaceMap[currentSample] = std::vector<std::shared_ptr<Surface> >();
96 caloSampleDDEElementsMap[currentSample] = std::vector<const CaloDetDescrElement*>();
97 }
98
99 for (auto currentSample : m_caloDiscSampleList) {
100 caloSampleSurfaceMap[currentSample] = std::vector<std::shared_ptr<Surface> >();
101 caloSampleDDEElementsMap[currentSample] = std::vector<const CaloDetDescrElement*>();
102 }
103
104 //for each calo sampling collect all the DDE in a vector
105 for (const CaloDetDescrElement* theDDE : m_caloDetSecrMgr->element_range()){
106 if (!theDDE){
107 ATH_MSG_ERROR("Null pointer to CaloDetDescrElement");
108 continue;
109 }
110 CaloCell_ID::CaloSample currentSample=theDDE->getSampling();
111 caloSampleDDEElementsMap[currentSample].push_back(theDDE);
112 }
113
114 auto sortAllLayersInZ = [&caloSampleDDEElementsMap](const std::vector<CaloCell_ID::CaloSample>& caloSampleList) {
115 for (auto currentSample : caloSampleList) {
116 std::vector<const CaloDetDescrElement*> currentElements = caloSampleDDEElementsMap[currentSample];
117 std::sort(currentElements.begin(), currentElements.end(), [](const CaloDetDescrElement* a, const CaloDetDescrElement* b) {return a->z() < b->z();});
118 caloSampleDDEElementsMap[currentSample] = std::move(currentElements);
119 }
120 };
121
122 //Sort the DDE, by Z, in all possible layers
123 sortAllLayersInZ(m_caloCylinderSampleList);
124 sortAllLayersInZ(m_caloDiscSampleList);
125
126}
#define ATH_MSG_ERROR(x)
static Double_t a
std::vector< CaloCell_ID::CaloSample > m_caloCylinderSampleList
std::vector< CaloCell_ID::CaloSample > m_caloDiscSampleList
std::unique_ptr< CaloDetDescrManager > m_caloDetSecrMgr
void sort(typename DataModel_detail::iterator< DVL > beg, typename DataModel_detail::iterator< DVL > end)
Specialization of sort for DataVector/List.

◆ finalize()

StatusCode ActsTrk::CaloBlueprintNodeBuilder::finalize ( )
override

Definition at line 76 of file CaloBlueprintNodeBuilder.cxx.

76 {
77 ATH_MSG_DEBUG("Finalizing CaloBlueprintNodeBuilder");
78 return StatusCode::SUCCESS;
79}

◆ generateCylinderSurface()

std::shared_ptr< CylinderSurface > ActsTrk::CaloBlueprintNodeBuilder::generateCylinderSurface ( const double & maxLArBRadius,
const double & minLArBRadius,
const double & lowZLarB,
const double & highZLarB ) const
private

generateCylinderSurface generates a cylindrical surface for a given set of parameters.

To do this it calculates the radius and length of the cylinder, then shifts it in Z to the midpoint of the Z values used to build it. It then creates the Acts::CylinderSurface and returns it via a shared pointer.

Definition at line 223 of file CaloBlueprintNodeBuilder.cxx.

223 {
224
225 //Characterise the dimensions of the cylinder
226 double LArBRadius = (maxLArBRadius + minLArBRadius) / 2.0;
227 double LArBLength = std::abs(highZLarB - lowZLarB);
228
229 ATH_MSG_DEBUG("Cylinder radius and length are " << LArBRadius << " and " << LArBLength);
230
231 auto surface = Surface::makeShared<CylinderSurface>(Transform3::Identity(), LArBRadius, LArBLength);
232
233 return surface;
234
235}

◆ generateCylinderSurfaces()

void ActsTrk::CaloBlueprintNodeBuilder::generateCylinderSurfaces ( caloSampleSurfaceMap_t & caloSampleSurfaceMap,
caloSampleDDEElementsMap_t & caloSampleDDEElementsMap ) const
private

generateCylinderSurfaces generates cylindrical surfaces for each calo sampling.

It does this for cylindrical layers by scanning in Z, for each Z finding the average radius of the cells in a phi ring If the average radius changes by more than a tolerance value (m_radiusTolerance), a new cylinder surface is created. The surfaces are added to the relevant vector of surfaces in the caloSampleSurfaceMap.

Definition at line 128 of file CaloBlueprintNodeBuilder.cxx.

128 {
129
130 for (auto currentSample : m_caloCylinderSampleList) {
131
132 std::vector<const CaloDetDescrElement*> currentElements = caloSampleDDEElementsMap[currentSample];
133
134 double maxLArBRadius = 0.0, minLArBRadius = 999999.0;
135 double lowZLarB = 0.0, highZLarB = 0.0;
136
137 //loop over cells runs from -z to +z in a given sampling layer
138 //There are many cells with the same z value, but different phi values
139 //We will find the average radius of the cells in a given phi ring
140 double totalRadiusFixedPhi = 0.0;
141 bool firstCellInPhiRing = true;
142 unsigned int phiCounter = 0;
143
144 //Then we will also track changes in radius as we move in Z from
145 //each ring of cells in phi to the next ring of cells in phi
146 bool firstPhiRing = true;
147 double initialRadius = 0.0;
148 double initialZ = -999999.0;
149
150 for (const CaloDetDescrElement* theDDE : currentElements){
151
152 double z = theDDE->z();
153 double radius = theDDE->r();
154
155 ATH_MSG_DEBUG(" Calo Sampling is " << currentSample);
156
157 if (firstCellInPhiRing) {
158 ATH_MSG_DEBUG("First Cell in phi ring " << currentSample << " has z = " << z << " and r = " << radius);
159 initialZ = z;
160 firstCellInPhiRing = false;
161 }
162
163 if (firstPhiRing) {
164 ATH_MSG_DEBUG("First Cell in layer " << currentSample << " has z = " << z << " and r = " << radius);
165 initialRadius = theDDE->r();
166 firstPhiRing = false;
167 lowZLarB = z;
168 }
169
170 ATH_MSG_DEBUG("Z and initialZ are " << z << " and " << initialZ);
171
172 //if z has not changed then we add the radius to the summed radius for this phi ring
173 //and increment the counter of cells in this phi ring
174 if (std::abs(z - initialZ) < 0.0001) {
175 ATH_MSG_DEBUG("phiCounter is " << phiCounter << " and radius is " << radius << " and totalRadiusFixedPhi is " << totalRadiusFixedPhi << " and hash is " << theDDE->calo_hash());
176 totalRadiusFixedPhi += radius;
177 phiCounter++;
178 continue;
179 }
180 else {
181 firstCellInPhiRing = true;
182 if (phiCounter > 0) {
183 double cellRingRadius = totalRadiusFixedPhi / phiCounter;
184 totalRadiusFixedPhi = 0.0;
185 phiCounter = 0;
186
187 if (cellRingRadius > maxLArBRadius) maxLArBRadius = radius;
188 if (cellRingRadius < minLArBRadius) minLArBRadius = radius;
189
190 //if radius changes by more than tolerance, then we will create a cylinder
191 //with the average cell radius and length from neg to pos z
192 highZLarB = z;
193 ATH_MSG_DEBUG("Values of cellRingRadius, initialRadius, highZLarB and lowZLarB are " << cellRingRadius << ", " << initialRadius << ", " << highZLarB << " and " << lowZLarB);
194 if (std::abs(cellRingRadius - initialRadius) > m_radiusTolerance && highZLarB - lowZLarB > 0.0) {
195 ATH_MSG_DEBUG("CYLINDER: Create cylinder for layer " << currentSample);
196 ATH_MSG_DEBUG("CYLINDER: Create Cylinder: Min and Max LAr B radius are " << minLArBRadius << " " << maxLArBRadius);
197 ATH_MSG_DEBUG("CYLINDER: Create Cylinder: Min and Max LAr B z are " << lowZLarB << " " << highZLarB);
198
199 caloSampleSurfaceMap[currentSample].push_back(generateCylinderSurface(maxLArBRadius, minLArBRadius, lowZLarB, highZLarB));
200
201 //reset the dimensions of the cylinder to the initial conditions, in
202 //preparation for the next cylinder
203 firstPhiRing = true;
204 minLArBRadius = 999999.0;
205 maxLArBRadius = 0.0;
206 lowZLarB = 0.0;
207 highZLarB = 0.0;
208 }//if radius changes by more than tolerance
209 }//if at least one cell in phi (should always be the case!)
210 else ATH_MSG_ERROR("phiCounter is zero!");
211 }//if z has changed
212 }//loop over calorimeter DDE
213
214 if (0 == caloSampleSurfaceMap[currentSample].size()){
215 ATH_MSG_DEBUG("CYLINDER: Zero size Vector: Create cylinder for layer " << currentSample);
216 ATH_MSG_DEBUG("CYLINDER: Create Cylinder: Min and Max LAr B radius are " << minLArBRadius << " " << maxLArBRadius);
217 ATH_MSG_DEBUG("CYLINDER: Create Cylinder: Min and Max LAr B z are " << lowZLarB << " " << highZLarB);
218 caloSampleSurfaceMap[currentSample].push_back(generateCylinderSurface(maxLArBRadius, minLArBRadius, lowZLarB, highZLarB));
219 }
220 }
221}
Gaudi::Property< double > m_radiusTolerance
std::shared_ptr< Acts::CylinderSurface > generateCylinderSurface(const double &maxLArBRadius, const double &minLArBRadius, const double &lowZLarB, const double &highZLarB) const
generateCylinderSurface generates a cylindrical surface for a given set of parameters.

◆ initialize()

StatusCode ActsTrk::CaloBlueprintNodeBuilder::initialize ( )
override

Definition at line 23 of file CaloBlueprintNodeBuilder.cxx.

23 {
24 ATH_MSG_DEBUG("Initializing CaloBlueprintNodeBuilder");
25
28
29 return StatusCode::SUCCESS;
30}
std::unique_ptr< CaloDetDescrManager > buildCaloDetDescrNoAlign(ISvcLocator *svcLocator, IMessageSvc *msgSvc)
IMessageSvc * getMessageSvc(bool quiet=false)

Member Data Documentation

◆ m_caloCylinderSampleList

std::vector<CaloCell_ID::CaloSample> ActsTrk::CaloBlueprintNodeBuilder::m_caloCylinderSampleList
private
Initial value:
{CaloCell_ID::PreSamplerB, CaloCell_ID::EMB1, CaloCell_ID::EMB2,
CaloCell_ID::EMB3,CaloCell_ID::TileBar0, CaloCell_ID::TileBar1, CaloCell_ID::TileBar2,
CaloCell_ID::TileGap1, CaloCell_ID::TileGap2, CaloCell_ID::TileExt0, CaloCell_ID::TileExt1,
CaloCell_ID::TileExt2}

Definition at line 79 of file CaloBlueprintNodeBuilder.h.

79 {CaloCell_ID::PreSamplerB, CaloCell_ID::EMB1, CaloCell_ID::EMB2,
80 CaloCell_ID::EMB3,CaloCell_ID::TileBar0, CaloCell_ID::TileBar1, CaloCell_ID::TileBar2,
81 CaloCell_ID::TileGap1, CaloCell_ID::TileGap2, CaloCell_ID::TileExt0, CaloCell_ID::TileExt1,
82 CaloCell_ID::TileExt2};

◆ m_caloDetSecrMgr

std::unique_ptr<CaloDetDescrManager> ActsTrk::CaloBlueprintNodeBuilder::m_caloDetSecrMgr
private

Definition at line 71 of file CaloBlueprintNodeBuilder.h.

◆ m_caloDiscSampleList

std::vector<CaloCell_ID::CaloSample> ActsTrk::CaloBlueprintNodeBuilder::m_caloDiscSampleList
private
Initial value:
{CaloCell_ID::PreSamplerE, CaloCell_ID::EME1, CaloCell_ID::EME2,
CaloCell_ID::EME3, CaloCell_ID::HEC0, CaloCell_ID::HEC1, CaloCell_ID::HEC2, CaloCell_ID::HEC3, CaloCell_ID::TileGap3}

Definition at line 76 of file CaloBlueprintNodeBuilder.h.

76 {CaloCell_ID::PreSamplerE, CaloCell_ID::EME1, CaloCell_ID::EME2,
77 CaloCell_ID::EME3, CaloCell_ID::HEC0, CaloCell_ID::HEC1, CaloCell_ID::HEC2, CaloCell_ID::HEC3, CaloCell_ID::TileGap3};

◆ m_radiusTolerance

Gaudi::Property<double> ActsTrk::CaloBlueprintNodeBuilder::m_radiusTolerance
private
Initial value:
{ this
, "RadiusTolerance"
, 2.0
, "Tolerance for determining if a ring of cells in phi has changed the radius w.r.t to the previous ring in phi" }

Definition at line 84 of file CaloBlueprintNodeBuilder.h.

84 { this
85 , "RadiusTolerance"
86 , 2.0
87 , "Tolerance for determining if a ring of cells in phi has changed the radius w.r.t to the previous ring in phi" };

◆ m_zTolerance

Gaudi::Property<double> ActsTrk::CaloBlueprintNodeBuilder::m_zTolerance
private
Initial value:
{ this
, "ZTolerance"
, 2.0
, "Tolerance for determining if a ring of cells in phi has changed the z w.r.t to the previous ring in phi" }

Definition at line 89 of file CaloBlueprintNodeBuilder.h.

89 { this
90 , "ZTolerance"
91 , 2.0
92 , "Tolerance for determining if a ring of cells in phi has changed the z w.r.t to the previous ring in phi" };

The documentation for this class was generated from the following files: