ATLAS Offline Software
Loading...
Searching...
No Matches
PixelDetectorManager.cxx
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3*/
5
10#include "Identifier/Identifier.h"
15#include "GeoModelKernel/GeoVAlignmentStore.h"
19
20namespace InDetDD {
21
22 const int FIRST_HIGHER_LEVEL = 1;
23
24
26 const std::string& name,
27 const std::string& pixelIDName)
28 : SiDetectorManager(detStore, name),
29 m_idHelper(nullptr),
30 m_isLogical(false) // Change to true to change the definition of local module corrections
31 {
32 //
33 // Initialized the Identifier helper.
34 //
35 if (pixelIDName == "PLR_ID") {
36 const PLR_ID* plr_idHelper;
37 StatusCode sc = detStore->retrieve(plr_idHelper, pixelIDName);
38 if (sc.isFailure()) {
39 ATH_MSG_ERROR("Could not retrieve PLR_ID helper");
40 }
41 m_idHelper = plr_idHelper;
42 // make the symlink
43 sc = detStore->symLink(plr_idHelper, m_idHelper);
44 if (sc.isFailure()) {
45 ATH_MSG_ERROR("Could not make PLR_ID symlink");
46 }
47 } else {
48 StatusCode sc = detStore->retrieve(m_idHelper, pixelIDName);
49 if (sc.isFailure()) {
50 ATH_MSG_ERROR("Could not retrieve PixelID helper");
51 }
52 }
53
54 // Initialize the collections.
55 if (m_idHelper) {
56 m_elementCollection.resize(m_idHelper->wafer_hash_max());
57 m_alignableTransforms.resize(m_idHelper->wafer_hash_max());
58 }
59 //https://its.cern.ch/jira/browse/ATLASRECTS-4886
61 }
62
64 : PixelDetectorManager(detStore, "Pixel", "PixelID"){ }
65
67 {
68 return m_volume.size();
69 }
70
71 PVConstLink PixelDetectorManager::getTreeTop(unsigned int i) const
72 {
73 return m_volume[i];
74 }
75
76 void PixelDetectorManager::addTreeTop(const PVConstLink& vol){
77 m_volume.push_back(vol);
78 }
79
81 {
82 // NB the id helpers implementation for getting a hash is not optimal.
83 // Essentially does a binary search.
84 // Make sure it is a wafer Id
85 Identifier waferId = m_idHelper->wafer_id(id);
86 IdentifierHash idHash = m_idHelper->wafer_hash(waferId);
87 if (idHash.is_valid()) {
88 return m_elementCollection[idHash];
89 } else {
90 return nullptr;
91 }
92 }
93
95 {
96 return m_elementCollection[idHash];
97 }
98
99 const SiDetectorElement* PixelDetectorManager::getDetectorElement(int barrel_endcap, int layer_wheel, int phi_module, int eta_module) const
100 {
101 return getDetectorElement(m_idHelper->wafer_id(barrel_endcap, layer_wheel, phi_module, eta_module));
102 }
103
108
113
122
127
129 {
130 IdentifierHash idHash = element->identifyHash();
131 if (idHash >= m_elementCollection.size())
132 throw std::runtime_error("PixelDetectorManager: Error adding detector element.");
133 m_elementCollection[idHash] = element;
134 }
135
137 {
139
140 // Loop over all elements and set the neighbours
141 for (iter = m_elementCollection.begin(); iter != m_elementCollection.end(); ++iter){
142
143 SiDetectorElement * element = *iter;
144 if (element) {
145
146 IdentifierHash idHash = element->identifyHash();
147 IdentifierHash idHashOther;
148
149 int result;
150 // If no neighbour, result != 0 in which case we leave neighbour as null
151 result = m_idHelper->get_next_in_eta(idHash, idHashOther);
152 if (result==0) element->setNextInEta(m_elementCollection[idHashOther]);
153
154 result = m_idHelper->get_prev_in_eta(idHash, idHashOther);
155 if (result==0) element->setPrevInEta(m_elementCollection[idHashOther]);
156
157 result = m_idHelper->get_next_in_phi(idHash, idHashOther);
158 if (result==0) element->setNextInPhi(m_elementCollection[idHashOther]);
159
160 result = m_idHelper->get_prev_in_phi(idHash, idHashOther);
161 if (result==0) element->setPrevInPhi(m_elementCollection[idHashOther]);
162 }
163 }
164 }
165
166
168 {
169 return m_idHelper;
170 }
171
173 {
174 unsigned int barrelLayers = 0;
175 for (int i = numerology().numLayers() - 1; i >= 0; --i) {
176 barrelLayers *= 10;
177 barrelLayers += numerology().useLayer(i);
178 }
179 return barrelLayers;
180 }
181
183 {
184 unsigned int endcapLayers = 0;
185 for (int i = numerology().numDisks() - 1; i >= 0; --i) {
186 endcapLayers *= 10;
187 endcapLayers += numerology().useDisk(i);
188 }
189 return endcapLayers;
190 }
191
192
194 const Identifier & id,
195 const Amg::Transform3D & delta,
196 FrameType frame,
197 GeoVAlignmentStore* alignStore) const
198 {
199
200 if (level == 0) { // At the element level - local shift
201
202 // We retrieve it via a hashId.
203 IdentifierHash idHash = m_idHelper->wafer_hash(id);
204 if (!idHash.is_valid()) return false;
205
206 if (frame == InDetDD::global) {
207
208 return setAlignableTransformGlobalDelta(m_alignableTransforms[idHash].get(), delta, alignStore);
209
210 } else if (frame == InDetDD::local) {
211
212 const SiDetectorElement * element = m_elementCollection[idHash];
213 if (!element) return false;
214
215 // Its a local transform
216 //See header file for definition of m_isLogical
217 if( m_isLogical ){
218 // Ensure cache is up to date and use the alignment corrected local to
219 // global transform
220 element->updateCache();
222 m_alignableTransforms[idHash].get(), element->transform(), delta,
223 alignStore);
224 } else
225 //Use default local to global transform
227 m_alignableTransforms[idHash].get(), element->defTransform(),
228 delta, alignStore);
229 } else {
230 // other not supported
231 ATH_MSG_WARNING("Frames other than global or local are not supported.");
232 return false;
233 }
234
235 } else { // higher level
236
237 if (frame != InDetDD::global) {
238 ATH_MSG_WARNING("Non global shift at higher levels is not possible.");
239 return false;
240 }
241
242 int index = level - FIRST_HIGHER_LEVEL; // level 0 is treated separately.
243 if (index >= static_cast<int>(m_higherAlignableTransforms.size())) return false;
244
245 // We retrieve it from a map.
246 AlignableTransformMap::const_iterator iter;
247 iter = m_higherAlignableTransforms[index].find(id);
248 if (iter == m_higherAlignableTransforms[index].end()) return false;
249
250 // Its a global transform
251 return setAlignableTransformGlobalDelta((iter->second).get(), delta, alignStore);
252 }
253
254 }
255
256
258 const Identifier & id,
259 GeoAlignableTransform *transform,
260 const GeoVPhysVol * child)
261 {
262 GeoNodePtr<GeoAlignableTransform> tmp_transform(transform);
263 if (m_idHelper) {
264
265 const GeoVFullPhysVol * childFPV = dynamic_cast<const GeoVFullPhysVol *>(child);
266 if (!childFPV) {
267 ATH_MSG_ERROR("Child of alignable transform is not a full physical volume");
268 } else {
269 addAlignableTransform (level, id, transform, childFPV);
270 }
271 }
272 }
273
275 const Identifier & id,
276 GeoAlignableTransform *transform,
277 const GeoVFullPhysVol * child)
278 {
279 GeoNodePtr<GeoAlignableTransform> tmp_transform(transform);
280 if (m_idHelper) {
281 if (level == 0) {
282 IdentifierHash idHash = m_idHelper->wafer_hash(id);
283 if (idHash.is_valid()) {
284 m_alignableTransforms[idHash]= std::make_unique<ExtendedAlignableTransform>(transform, child);
285 }
286 } else {
287 // Higher levels are saved in a map. NB the index is level-1 as level=0 is treated above.
288 int index = level - FIRST_HIGHER_LEVEL;
289 if (index >= static_cast<int>(m_higherAlignableTransforms.size())) m_higherAlignableTransforms.resize(index+1);
290 m_higherAlignableTransforms[index][id] = std::make_unique<ExtendedAlignableTransform>(transform, child);
291 }
292 }
293 }
294
296 {
297 return getIdHelper()->is_pixel(id);
298 }
299
300
301
303 {
304 return dynamic_cast<const PixelModuleDesign *>(getDesign(i));
305 }
306
307
308
309 // The implementation of the new IBLDist DB;
310 // Specific for IBL -> maybe make it different function in future to be more general
311 bool PixelDetectorManager::processSpecialAlignment(const std::string & key, InDetDD::AlignFolderType alignfolderType)
312 {
313
314 bool alignmentChange = false;
315
316 std::string alignfolder;
317 if (alignfolderType == InDetDD::static_run1) alignfolder = "/Indet/Align";
318 if (alignfolderType == InDetDD::timedependent_run2) alignfolder = "/Indet/AlignL3";
319
320 ATH_MSG_INFO("Processing IBLDist alignment container with key (" << key << ")"
321 << "and alignment folder pointing to " << alignfolder);
322
323 int nstaves = 0;
324 if (numerology().numPhiModulesForLayer(0)<14) nstaves = 14;
325 else nstaves = numerology().numPhiModulesForLayer(0);
326
327 std::vector<float> ibldist;
328 std::vector<float> iblbaseline;
329 ibldist.resize(nstaves);
330 iblbaseline.resize(nstaves);
331
332 const CondAttrListCollection* atrlistcol=nullptr;
333 if (StatusCode::SUCCESS==m_detStore->retrieve(atrlistcol,key)) {
334 // loop over objects in collection
335 for (CondAttrListCollection::const_iterator citr=atrlistcol->begin(); citr!=atrlistcol->end();++citr) {
336 const coral::AttributeList& atrlist=citr->second;
337 ibldist[atrlist["stave"].data<int>()] = atrlist["mag"].data<float>();
338 iblbaseline[atrlist["stave"].data<int>()] = atrlist["base"].data<float>();
339
340 ATH_MSG_VERBOSE("IBLDist DB -- channel: " << citr->first
341 << " ,stave: " << atrlist["stave"].data<int>()
342 << " ,mag: " << atrlist["mag"].data<float>()
343 << " ,base: " << atrlist["base"].data<float>());
344 }
345 }
346 else {
347 ATH_MSG_WARNING("Cannot find IBLDist Container for key "
348 << key << " - no IBL bowing alignment");
349 return alignmentChange;
350 }
351
362
364 if (StatusCode::SUCCESS!=m_detStore->retrieve(container, alignfolder)) {
365 ATH_MSG_ERROR("Cannot find AlignableTransformContainer for key "
366 << key << " - no misalignment");
367 // This should not occur in normal situations so we force job to abort.
368 throw std::runtime_error("Unable to apply Inner Detector alignments");
369 }
370 // Check if container is empty - this can occur if it is an invalid IOV.
371 if (container->empty()) {
372 ATH_MSG_ERROR("AlignableTransformContainer for key "
373 << key << " is empty. Probably due to out of range IOV");
374 // This should not occur in normal situations so we force job to abort.
375 throw std::runtime_error("Unable to apply Inner Detector alignments.");
376 }
377 // loop over all the AlignableTransform objects in the collection
378 std::string IBLalignfolder = alignfolder;
379 IBLalignfolder.append("/PIXB1");// "/Indet/Align/PIXB1"
380 for (const auto *pat : *container)
381 {
382 if (!( pat->tag()==IBLalignfolder &&
383 numerology().numPhiModulesForLayer(0)==14 &&
384 numerology().numLayers()==4) ){ // hard-coded to IBL for now; no other geometry should really apply this!
385 ATH_MSG_DEBUG("IBLDist; ignoring collections " << pat->tag());
386 }
387 else{
388 const AlignableTransform* transformCollection = pat;
389 for (AlignableTransform::AlignTransMem_citr trans_iter = transformCollection->begin();
390 trans_iter != transformCollection->end();
391 ++trans_iter)
392 {
393 ATH_MSG_DEBUG("IBLDist alignment for identifier "
394 << getIdHelper()->show_to_string(trans_iter->identify()));
395
396 IdentifierHash idHash = getIdHelper()->wafer_hash(trans_iter->identify());
397 if (!idHash.is_valid()){
398 ATH_MSG_WARNING("Invalid HashID for identifier "
399 << getIdHelper()->show_to_string(trans_iter->identify()));
400 ATH_MSG_WARNING("No IBLDist corrections can be applied for invalid HashID's - exiting");
401 return false;
402 }
403 const SiDetectorElement * sielem = m_elementCollection[idHash];
404 //This should work as Bowing is in L3 frame, i.e. local module frame
405 Amg::Vector3D center = sielem->defTransform() * Amg::Vector3D{0, 0, 0};
406 double z = center[2];
407 const double y0y0 = 366.5*366.5;
408
409 double bowx = ibldist[getIdHelper()->phi_module(trans_iter->identify())] * ( z*z - y0y0 ) / y0y0;
410 double basex= iblbaseline[getIdHelper()->phi_module(trans_iter->identify())];
411 // This is in the module frame, as bowing corrections are directly L3
412
413 ATH_MSG_DEBUG("Total IBL-module Tx shift (baseline+bowing): " << basex+bowx);
414 if ( (basex+bowx)==0 ) continue; // make sure we ignore NULL corrections
415
416 Amg::Transform3D shift = Amg::Translation3D(basex+bowx,0,0) * Amg::RotationMatrix3D::Identity();
417
418 const AlignableTransform* cpat = pat;
419 AlignableTransform::AlignTransMem_citr this_trans=cpat->findIdent(trans_iter->identify());
420 HepGeom::Transform3D newtrans = Amg::EigenTransformToCLHEP(shift)*this_trans->transform();
421
423 if (msgLvl(MSG::VERBOSE)) {
424 ATH_MSG_LVL_NOCHK(MSG::VERBOSE, "Bowing Transformation only:");
425 printTransform(MSG::VERBOSE, shift);
426 ATH_MSG_LVL_NOCHK(MSG::VERBOSE, "Original alignable Transformation from StoreGate:");
427 printTransform(MSG::VERBOSE, Amg::CLHEPTransformToEigen(this_trans->transform()));
428 ATH_MSG_LVL_NOCHK(MSG::VERBOSE, "Final mModified Transformation:");
429 printTransform(MSG::VERBOSE, Amg::CLHEPTransformToEigen(newtrans));
430 }
432
433 // Set the new transform; Will replace existing one with updated transform
434 bool status = setAlignableTransformDelta(0,
435 trans_iter->identify(),
438 nullptr);
439
440 if (!status) {
441 ATH_MSG_DEBUG("Cannot set AlignableTransform for identifier."
442 << getIdHelper()->show_to_string(trans_iter->identify())
443 << " at level 0 for IBLDist bowing deformation");
444 }
445 alignmentChange = (alignmentChange || status);
446 }
447 }
448 }
449
450 return alignmentChange;
451 }
452
454 const CondAttrListCollection* obj,
455 GeoVAlignmentStore* alignStore) const {
456 bool alignmentChange = false;
457
458 ATH_MSG_INFO("Processing IBLDist alignment container with key " << key);
459 if(numerology().numLayers() != 4) {
460 // this doesn't appear to be Run 2, i.e. the IBL isn't there. Bailing
461 return alignmentChange;
462 }
463
464 int nstaves = 0;
465 if (numerology().numPhiModulesForLayer(0) < 14)
466 nstaves = 14;
467 else
468 nstaves = numerology().numPhiModulesForLayer(0);
469
470 std::vector<float> ibldist;
471 std::vector<float> iblbaseline;
472 ibldist.resize(nstaves);
473 iblbaseline.resize(nstaves);
474
475 // loop over objects in collection
476 for (CondAttrListCollection::const_iterator citr = obj->begin();
477 citr != obj->end(); ++citr) {
478
479 const coral::AttributeList &atrlist = citr->second;
480 ibldist[atrlist["stave"].data<int>()] = atrlist["mag"].data<float>();
481 iblbaseline[atrlist["stave"].data<int>()] = atrlist["base"].data<float>();
482
483 ATH_MSG_VERBOSE("IBLDist DB -- channel: " << citr->first
484 << ", stave: " << atrlist["stave"].data<int>()
485 << ", mag: " << atrlist["mag"].data<float>()
486 << ", base: " << atrlist["base"].data<float>());
487 }
488
499
500
501 for(const auto* detElem : *getDetectorElementCollection()) {
502 if(!detElem->isInnermostPixelLayer()) {
503 // skip non-IBL elements. This only works if the innermost pixel layer is in fact
504 // the IBL. That should be the case for Run2 until replacement of the ID.
505 continue;
506 }
507 std::string repr = getIdHelper()->show_to_string(detElem->identify());
508 ATH_MSG_DEBUG("IBLDist alignment for identifier " << repr);
509
510
511 IdentifierHash idHash = getIdHelper()->wafer_hash(detElem->identify());
512 if (!idHash.is_valid()) {
513 ATH_MSG_WARNING("Invalid HashID for identifier " << repr);
514 ATH_MSG_WARNING("No IBLDist corrections can be applied for "
515 "invalid HashID's - exiting ");
516 return false;
517 }
518
519 // extract the stave number
520 int stave = getIdHelper()->phi_module(detElem->identify());
521
522 Amg::Vector3D center = detElem->defTransform() * Amg::Vector3D{0, 0, 0};
523 double z = center[2];
524 const double y0y0 = 366.5 * 366.5;
525
526 double bowx = ibldist[stave] * (z * z - y0y0) / y0y0;
527 double basex = iblbaseline[stave];
528 // This is in the module frame, as bowing corrections are directly L3
529
530 ATH_MSG_DEBUG("Total IBL-module Tx shift (baseline+bowing): " << basex + bowx);
531
532 if ((basex + bowx) == 0) {
533 continue; // make sure we ignore NULL corrections
534 }
535
536 Amg::Transform3D shift = Amg::Translation3D(basex + bowx, 0, 0) *
537 Amg::RotationMatrix3D::Identity();
538
539 // now we need to get the original alignment delta to apply this additional
540 // shift to
542 const GeoTrf::Transform3D* currentDelta = alignStore->getDelta(eat->alignableTransform());
543 if (currentDelta == nullptr) {
544 ATH_MSG_ERROR("Have IBL Dist for element which does not have an alignment delta."
545 << " This indicates inconsistent alignment data");
546 return false;
547 }
548
549 HepGeom::Transform3D recoToHitTransform = detElem->recoToHitTransform();
550 Amg::Transform3D r2h = Amg::CLHEPTransformToEigen(recoToHitTransform);
551
552 ATH_MSG_VERBOSE("Previous delta for " << repr << ":\n" << currentDelta->matrix());
553 ATH_MSG_VERBOSE("Bowing-only delta for " << repr << ":\n" << shift.matrix());
554 Amg::Transform3D newDelta = shift * r2h.inverse() * (*currentDelta) * r2h;
555
556 // We can probably just write it back to the geo alignment store.
557 // The IBL bowing is always at the module level, and that's the delta that
558 // we retrieved from the geo alignment store.
559
560 bool status = setAlignableTransformDelta(0,
561 detElem->identify(),
562 newDelta,
564 alignStore);
565
566
567 ATH_MSG_VERBOSE("New delta for " << repr << ":\n"
568 << alignStore->getDelta(eat->alignableTransform())->matrix());
569
570 alignmentChange |= status;
571 }
572
573 return alignmentChange;
574 }
575
576 // New global alignment folders
577 bool PixelDetectorManager::processGlobalAlignment(const std::string & key, int level, FrameType frame, const CondAttrListCollection* obj, GeoVAlignmentStore* alignStore) const
578 {
579
580 bool alignmentChange = false;
581
582 ATH_MSG_INFO("Processing new global alignment containers with key " << key
583 << " in the " << frame << " frame at level " << level);
584
585 Identifier ident=Identifier();
586 const CondAttrListCollection* atrlistcol=obj;
587 //cppcheck-suppress nullPointerRedundantCheck
588 if (!atrlistcol) {
589 ATH_MSG_INFO("Read alignment from detector store with key " << key);
590 if (StatusCode::SUCCESS!=m_detStore->retrieve(atrlistcol,key)) {
591 ATH_MSG_WARNING("Cannot find new global align Container for key "
592 << key << " - no new global alignment");
593 return alignmentChange;
594 }
595 }
596 // Avoid cppcheck warning.
597 if (!atrlistcol) {
598 return alignmentChange;
599 }
600 {
601 // loop over objects in collection
602 //cppcheck-suppress nullPointerRedundantCheck
603 for (CondAttrListCollection::const_iterator citr=atrlistcol->begin(); citr!=atrlistcol->end();++citr) {
604 const coral::AttributeList& atrlist=citr->second;
605 // We are in the Pixel manager, therefore ignore all that is not Pixel Identifier
606 if (atrlist["det"].data<int>()!=1) continue;
607
608 ident = getIdHelper()->wafer_id(atrlist["bec"].data<int>(),
609 atrlist["layer"].data<int>(),
610 atrlist["ring"].data<int>(),
611 atrlist["sector"].data<int>());
612
613 // Make sure we have valid HashID (This ONLY works here as the 0-modules exist)
614 // Precaution which does not work for e.g. SCT
615 if (!(getIdHelper()->wafer_hash(ident)).is_valid()){
616 ATH_MSG_WARNING("Invalid HashID for identifier " << getIdHelper()->show_to_string(ident));
617 ATH_MSG_WARNING("No global alignment corrections can be applied for invalid HashID's - exiting");
618 return false;
619 }
620
621 // construct new transform
622 // Order of rotations is defined as around z, then y, then x.
623 Amg::Translation3D newtranslation(atrlist["Tx"].data<float>(),atrlist["Ty"].data<float>(),atrlist["Tz"].data<float>());
624 Amg::Transform3D newtrans = newtranslation * Amg::RotationMatrix3D::Identity();
625 newtrans *= Amg::AngleAxis3D(atrlist["Rz"].data<float>()*CLHEP::mrad, Amg::Vector3D(0.,0.,1.));
626 newtrans *= Amg::AngleAxis3D(atrlist["Ry"].data<float>()*CLHEP::mrad, Amg::Vector3D(0.,1.,0.));
627 newtrans *= Amg::AngleAxis3D(atrlist["Rx"].data<float>()*CLHEP::mrad, Amg::Vector3D(1.,0.,0.));
628
629 ATH_MSG_DEBUG("New global DB -- channel: " << citr->first
630 << " ,det: " << atrlist["det"].data<int>()
631 << " ,bec: " << atrlist["bec"].data<int>()
632 << " ,layer: " << atrlist["layer"].data<int>()
633 << " ,ring: " << atrlist["ring"].data<int>()
634 << " ,sector: " << atrlist["sector"].data<int>()
635 << " ,Tx: " << atrlist["Tx"].data<float>()
636 << " ,Ty: " << atrlist["Ty"].data<float>()
637 << " ,Tz: " << atrlist["Tz"].data<float>()
638 << " ,Rx: " << atrlist["Rx"].data<float>()
639 << " ,Ry: " << atrlist["Ry"].data<float>()
640 << " ,Rz: " << atrlist["Rz"].data<float>());
641
642 // Set the new transform; Will replace existing one with updated transform
643 bool status = setAlignableTransformDelta(level,
644 ident,
645 newtrans,
646 frame,
647 alignStore);
648
649 if (!status) {
650 ATH_MSG_DEBUG("Cannot set AlignableTransform for identifier."
651 << getIdHelper()->show_to_string(ident)
652 << " at level " << level << " for new global DB");
653 }
654
655 alignmentChange = (alignmentChange || status);
656 }
657 }
658 return alignmentChange;
659 }
660
661
662 // Helpful function for debugging of transforms
664 const Amg::Transform3D & tr) const
665 {
666 ATH_MSG_LVL_NOCHK(level, " - translation: " << tr.translation().x() << " " <<tr.translation().y() << " " <<tr.translation().z());
667 ATH_MSG_LVL_NOCHK(level, " - rotation:");
668 ATH_MSG_LVL_NOCHK(level, " " << tr(0,0) << " " << tr(0,1) << " " << tr(0,2));
669 ATH_MSG_LVL_NOCHK(level, " " << tr(1,0) << " " << tr(1,1) << " " << tr(1,2));
670 ATH_MSG_LVL_NOCHK(level, " " << tr(2,0) << " " << tr(2,1) << " " << tr(2,2));
671 }
672
673
674} // namespace InDetDD
CondMultChanCollection< AlignableTransform > AlignableTransformContainer
#define ATH_MSG_ERROR(x)
#define ATH_MSG_INFO(x)
#define ATH_MSG_VERBOSE(x)
#define ATH_MSG_LVL_NOCHK(lvl, x)
#define ATH_MSG_WARNING(x)
#define ATH_MSG_DEBUG(x)
This file defines the class for a collection of AttributeLists where each one is associated with a ch...
GeoIntrusivePtr< T > GeoNodePtr
Definition GeoNodePtr.h:12
char data[hepevt_bytes_allocation_ATLAS]
Definition HepEvt.cxx:11
static Double_t sc
#define z
std::vector< AlignTransMember >::const_iterator AlignTransMem_citr
AlignTransMem_citr end() const
AlignTransMem_citr begin() const
AlignTransMem_citr findIdent(const Identifier &ident) const
bool msgLvl(const MSG::Level lvl) const
Test the output level.
bool is_pixel(Identifier id) const
std::string show_to_string(Identifier id, const IdContext *context=0, char sep='.') const
or provide the printout in string form
This class is a collection of AttributeLists where each one is associated with a channel number.
const_iterator end() const
const_iterator begin() const
Access to Chan/AttributeList pairs via iterators.
ChanAttrListMap::const_iterator const_iterator
DataModel_detail::const_iterator< DataVector > const_iterator
Definition DataVector.h:838
DataModel_detail::iterator< DataVector > iterator
Definition DataVector.h:842
This is a "hash" representation of an Identifier.
bool is_valid() const
Check if id is in a valid state.
Class to hold alignable transform plus a pointer to the child volume and optionally a frame volume.
std::vector< std::unique_ptr< ExtendedAlignableTransform > > m_alignableTransforms
virtual const PixelModuleDesign * getPixelDesign(int i) const
Access to module design, Casts to PixelModuleDesign.
void printTransform(MSG::Level level, const Amg::Transform3D &tr) const
void addTreeTop(const PVConstLink &vol)
Add a Tree top:
virtual void addDetectorElement(SiDetectorElement *element) override
Add elememts.
bool processSpecialAlignment(const std::string &, InDetDD::AlignFolderType) override
Process new IBLDist DB folder.
virtual SiDetectorElementCollection::const_iterator getDetectorElementBegin() const override
std::vector< PVConstLink > m_volume
virtual const PixelID * getIdHelper() const override
PixelDetectorManager(StoreGateSvc *detStore)
Constructor.
virtual SiDetectorElementCollection::const_iterator getDetectorElementEnd() const override
virtual const SiDetectorElementCollection * getDetectorElementCollection() const override
access to whole collection via Iterators
virtual unsigned int getNumTreeTops() const override
Access to raw geometry:
SiDetectorElementCollection m_elementCollection
bool m_isLogical
This variable switches the how the local alignment corrections are applied If true they will be calcu...
unsigned int getEndcapLayers() const
Layers built.
virtual bool setAlignableTransformDelta(int level, const Identifier &id, const Amg::Transform3D &delta, FrameType frame, GeoVAlignmentStore *alignStore) const override
implements the main alignment update for delta transforms in different frames, it translates into the...
virtual void addAlignableTransform(int level, const Identifier &id, GeoAlignableTransform *xf, const GeoVFullPhysVol *child)
Add alignable transforms.
std::vector< AlignableTransformMap > m_higherAlignableTransforms
unsigned int getBarrelLayers() const
Layers built.
virtual void initNeighbours() override
Initialize the neighbours.
virtual bool processGlobalAlignment(const std::string &, int level, FrameType frame, const CondAttrListCollection *obj, GeoVAlignmentStore *alignStore) const override
Process new global DB folders for L1 and L2.
virtual PVConstLink getTreeTop(unsigned int i) const override
virtual bool identifierBelongs(const Identifier &id) const override
Check identifier is for this detector.
virtual const SiDetectorElement * getDetectorElement(const Identifier &id) const override
access to individual elements : via Identifier
Class used to describe the design of a module (diode segmentation and readout scheme)
Class to hold the SiDetectorElement objects to be put in the detector store.
Class to hold geometrical description of a silicon detector element.
void setPrevInEta(const SiDetectorElement *element)
void setPrevInPhi(const SiDetectorElement *element)
void setNextInEta(const SiDetectorElement *element)
void setNextInPhi(const SiDetectorElement *element)
const SiNumerology & numerology() const
Access Numerology.
SiDetectorManager(StoreGateSvc *detStore, const std::string &name)
const SiDetectorDesign * getDesign(int i) const
static bool setAlignableTransformGlobalDelta(ExtendedAlignableTransform *extXF, const Amg::Transform3D &delta, GeoVAlignmentStore *alignStore=nullptr)
Helper method to set delta transform from a global delta - Amg interface.
static bool setAlignableTransformLocalDelta(ExtendedAlignableTransform *extXF, const Amg::Transform3D &localToGlobalXF, const Amg::Transform3D &delta, GeoVAlignmentStore *alignStore=nullptr)
Helper method to set delta transform from a local delta - Amg interface.
bool useLayer(int layer) const
Check if layer exists.
bool useDisk(int disk) const
Check if disk exists.
int numPhiModulesForLayer(int layer) const
Number of sectors in phi for a layer.
virtual const Amg::Transform3D & transform() const override final
Return local to global transform.
virtual IdentifierHash identifyHash() const override final
identifier hash (inline)
virtual void updateCache() const
Recalculate cached values.
This is a Identifier helper class for the PLR subdetector.
Definition PLR_ID.h:22
This is an Identifier helper class for the Pixel subdetector.
Definition PixelID.h:67
Identifier wafer_id(int barrel_ec, int layer_disk, int phi_module, int eta_module) const
For a single crystal.
Definition PixelID.h:360
IdentifierHash wafer_hash(Identifier wafer_id) const
wafer hash from id
Definition PixelID.h:383
int phi_module(const Identifier &id) const
Definition PixelID.h:625
The Athena Transient Store API.
T * get(TKey *tobj)
get a TObject* from a TKey* (why can't a TObject be a TKey?)
Definition hcg.cxx:130
Eigen::AngleAxisd AngleAxis3D
HepGeom::Transform3D EigenTransformToCLHEP(const Amg::Transform3D &eigenTransf)
Converts an Eigen-based Amg::Transform3D into a CLHEP-based HepGeom::Transform3D.
Amg::Transform3D CLHEPTransformToEigen(const HepGeom::Transform3D &CLHEPtransf)
Converts a CLHEP-based HepGeom::Transform3D into an Eigen Amg::Transform3D.
Eigen::Affine3d Transform3D
Eigen::Matrix< double, 3, 1 > Vector3D
Eigen::Translation< double, 3 > Translation3D
Message Stream Member.
const int FIRST_HIGHER_LEVEL
@ timedependent_run2
Definition index.py:1