ATLAS Offline Software
TRT_DetectorManager.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3 */
4 
13 
14 #include "GeoModelKernel/GeoXF.h"
15 #include "GeoModelKernel/GeoAlignableTransform.h"
16 
18 
21 
22 #include "StoreGate/StoreGateSvc.h"
24 
25 namespace InDetDD {
26 
27  const int FIRST_HIGHER_LEVEL = 1;
28 
31  m_numerology(new TRT_Numerology()),
32  m_idHelper(nullptr),
33  m_ownsIdHelper(false),
34  m_gasType(unknown),
35  m_digvers(9999),
36  m_digversname("ERROR:DIGVERSNOTSET!")
37  {
39 
40  m_barrelXF[0]=m_barrelXF[1]=m_barrelXF[2]=nullptr;
41  m_endcapXF[0]=m_endcapXF[1]=m_endcapXF[2]=nullptr;
42  }
43 
44 
45 
47  return m_numerology;
48  }
49 
51  return m_numerology;
52  }
53 
55  {
56  delete m_numerology;
57  if (m_ownsIdHelper) delete m_idHelper;
58  for (auto & i : m_barrelXF) delete i;
59  for (auto & i : m_endcapXF) delete i;
60 
61 
62  for (auto & m : m_alignableTransforms) {
63  for (auto & j : m) {
64  delete j.second;
65  }
66  }
67 
68  for (const TRT_BarrelDescriptor* barrelDescriptor : m_barrelDescriptors) {
69  delete barrelDescriptor;
70  }
71  for (const TRT_EndcapDescriptor* endcapDescriptor : m_endcapDescriptors) {
72  delete endcapDescriptor;
73  }
74  }
75 
76 
78  {
79  return m_volume.size();
80  }
81 
82  PVConstLink TRT_DetectorManager::getTreeTop(unsigned int i) const
83  {
84  return m_volume[i];
85  }
86 
87  void TRT_DetectorManager::addTreeTop(const PVLink& vol) {
88  m_volume.push_back(vol);
89  }
90 
91  // Manage the barrel elements:
93  {
95  }
96 
97  // Manage the endcap elements:
99  {
101  }
102 
104  , unsigned int moduleIndex
105  , unsigned int phiIndex
106  , unsigned int strawLayerIndex) const
107  {
108  return m_elementContainer.getBarrelDetElement(positive,moduleIndex,phiIndex,strawLayerIndex);
109  }
110 
112  , unsigned int moduleIndex
113  , unsigned int phiIndex
114  , unsigned int strawLayerIndex)
115  {
116  return m_elementContainer.getBarrelDetElement(positive,moduleIndex,phiIndex,strawLayerIndex);
117  }
118 
120  , unsigned int wheelIndex
121  , unsigned int strawLayerIndex
122  , unsigned int phiIndex) const
123  {
124  return m_elementContainer.getEndcapDetElement(positive,wheelIndex,strawLayerIndex,phiIndex);
125  }
126 
128  , unsigned int wheelIndex
129  , unsigned int strawLayerIndex
130  , unsigned int phiIndex)
131  {
132  return m_elementContainer.getEndcapDetElement(positive,wheelIndex,strawLayerIndex,phiIndex);
133  }
134 
136  {
137  return m_idHelper;
138  }
139 
140  void TRT_DetectorManager::setIdHelper(const TRT_ID *idHelper, bool owns)
141  {
142  m_idHelper=idHelper;
143  m_ownsIdHelper=owns;
144  }
145 
146 
147 
149  {
150  // Make sure it is a straw_layer id
151  Identifier strawLayerId = m_idHelper->layer_id(id);
152  IdentifierHash hashId = m_idHelper->straw_layer_hash(strawLayerId);
154  if (hashId>=elements->size()) return nullptr;
155  return (*elements)[hashId];
156  }
157 
159  {
161  if (id>=elements->size()) return nullptr;
162  return (*elements)[id];
163  }
164 
166  {
167  return &m_elementContainer;
168  }
169 
171  {
173  }
174 
175  TRT_DetElementCollection::const_iterator TRT_DetectorManager::getDetectorElementBegin() const
176  {
177  return m_elementContainer.getElements()->begin();
178  }
179 
180  TRT_DetElementCollection::const_iterator TRT_DetectorManager::getDetectorElementEnd() const
181  {
182  return m_elementContainer.getElements()->end();
183  }
184 
185 
186  void TRT_DetectorManager::setBarrelTransformField(size_t i, const GeoXF::Function * f){
187  if (m_barrelXF[i]!=f) delete m_barrelXF[i];
188  m_barrelXF[i] = f;
189  }
190 
191  const GeoXF::Function * TRT_DetectorManager::barrelTransformField(size_t i) const {
192  return m_barrelXF[i];
193  }
194 
195  void TRT_DetectorManager::setEndcapTransformField(size_t i, const GeoXF::Function *f) {
196  if (m_endcapXF[i]!=f) delete m_endcapXF[i];
197  m_endcapXF[i]=f;
198  }
199 
200  const GeoXF::Function *TRT_DetectorManager::endcapTransformField(size_t i) const{
201  return m_endcapXF[i];
202  }
203 
204 
206  {
207  return m_gasType;
208  }
209 
210  void TRT_DetectorManager::setGasType(const ActiveGasType & activeGasType)
211  {
212  m_gasType = activeGasType;
213  }
214 
216  {
217  return m_digvers;
218  }
219 
221  {
222  return m_digversname;
223  }
224 
225  void TRT_DetectorManager::setDigitizationVersion(const unsigned int & dv, const std::string& name )
226  {
228  }
229 
230  // Register the call back for this key and the corresponding level in
231  // in the hierarchy.
232  // DEPRECATED
233  void TRT_DetectorManager::addKey ATLAS_NOT_THREAD_SAFE (const std::string & key, int level) // Thread unsafe m_detStore->regFcn (callback) is used.
234  {
235  if(msgLvl(MSG::DEBUG))
236  msg(MSG::DEBUG) << "Registering alignmentCallback with key " << key << ", at level " << level
237  << endmsg;
238 
239  const DataHandle<AlignableTransform> transformCollection;
240  if (m_detStore->regFcn(&TRT_DetectorManager::alignmentCallback, this, transformCollection, key).isFailure()) {
241  ATH_MSG_ERROR("Cannot register callback with DetectorStore");
242  }
243  addKey(key, level, InDetDD::other);
244  }
245 
246  void TRT_DetectorManager::addKey(const std::string & key, int level, FrameType frame)
247  {
248  addChannel(key, level, frame);
249  }
250 
252  const Identifier &id,
253  GeoAlignableTransform *transform,
254  const GeoVPhysVol * child,
255  const GeoVPhysVol * frameVol)
256  {
257  if (m_idHelper) {
258  // Check if child and frame are actually full physical volumes.
259  // if they are non zero.
260  const GeoVFullPhysVol * childFPV = nullptr;
261  if (child) {
262  childFPV = dynamic_cast<const GeoVFullPhysVol *>(child);
263  }
264  const GeoVFullPhysVol * frameFPV = nullptr;
265  if (frameVol) {
266  frameFPV = dynamic_cast<const GeoVFullPhysVol *>(frameVol);
267  }
268  if (child && !childFPV) {
269  msg(MSG::ERROR)
270  << "Child of alignable transform is not a full physical volume"
271  << endmsg;
272  } else if (frameVol && !frameFPV) {
273  msg(MSG::ERROR)
274  << "Frame for alignable transform is not a full physical volume"
275  << endmsg;
276  } else {
277  addAlignableTransform (level, id, transform, childFPV, frameFPV);
278  }
279  }
280  }
281 
283  const Identifier &id,
284  GeoAlignableTransform *transform,
285  const GeoVFullPhysVol *child,
286  const GeoVFullPhysVol *frameVol)
287  {
288  if (m_idHelper) {
289  if (level == 0) {
290  // Nothing implemented. Reserved in case we want alignable straws.
291  } else {
292 
293  ExtendedAlignableTransform * extAlignableTransform = new ExtendedAlignableTransform(transform, child, frameVol);
294  if(msgLvl(MSG::VERBOSE)) {
295  msg(MSG::VERBOSE) << "TRT: Adding alignment at level " << level << " " << m_idHelper->show_to_string(id);
296  if (child && !frameVol) {
297  msg(MSG::VERBOSE) << " using global frame";
298  } else if (!child || child == frameVol ) {
299  msg(MSG::VERBOSE) << " using local frame";
300  } else {
301  msg(MSG::VERBOSE) << " using other frame";
302  }
303  msg(MSG::VERBOSE) << endmsg;
304  }
305  // Save in map
306  int index = level - FIRST_HIGHER_LEVEL; // level 0 treated separately.
307  if (index >= static_cast<int>(m_alignableTransforms.size())) m_alignableTransforms.resize(index+1);
308  m_alignableTransforms[index][id] = extAlignableTransform;
309  }
310  }
311  }
312 
314  const Identifier & id,
315  const Amg::Transform3D & delta,
316  FrameType frame,
317  GeoVAlignmentStore* alignStore) const
318  {
319  if (level == 0) {
320  // Nothing implemented. Reserved in case we want alignable straws
321  return false;
322  } else {
323 
324  int index = level - FIRST_HIGHER_LEVEL; // level 0 treated separately.
325  if (index >= static_cast<int>(m_alignableTransforms.size())) return false;
326 
327  // We retrieve it from a map.
328  AlignableTransformMap::const_iterator iter;
329  iter = m_alignableTransforms[index].find(id);
330  if (iter == m_alignableTransforms[index].end()) return false;
331 
332  return setAlignableTransformAnyFrameDelta(iter->second, delta, frame, alignStore);
333 
334  }
335  }
336 
338  const Amg::Transform3D & delta,
339  FrameType frame,
340  GeoVAlignmentStore* alignStore) const
341  {
342  //---------------------
343  // For Local:
344  //---------------------
345  // The geomodel alignable transform delta is already a local delta so we just pass it directly
346 
347  //---------------------
348  // For global frame
349  //---------------------
350  // Sets the alignable transform delta when the supplied delta is in the global frame.
351 
352  // If the default transform down to the alignable transform is
353  // T = A*B*C
354  // and the alignable transform is C with delta c and the delta in the global frame is g, then
355  // A*B*C*c = g*A*B*C
356  // T*c = g*T
357  // c = T.inverse() * g * T
358 
359  // To get default transform up and including the alignable transform,
360  // we assume the next volume down is a fullphys volume and so its
361  // transform is the transform we want (ie T=A*B*C in the above example).
362 
363  //---------------------
364  // For Other frame
365  //---------------------
366  // Sets the alignable transform delta when the supplied delta is in the frame of the
367  // volume "frameVol".
368 
369  // If the default transform down to the alignable transform is
370  // T = A*B*C
371  // and the alignable transform is C with delta c and the delta g is expressed in the frame A, then
372  // A*B*C*c = A*g*B*C
373  // c = (BC).inverse * g * (BC)
374  // BC = A.inverse() * T
375  // C = T.inverse() * A * g * A.inverse() * T
376 
377  // To get default transform up and including the alignable transform,
378  // we assume the next volume down is a fullphys volume and so its
379  // transform is the transform we want (ie T=A*B*C in the above example).
380  // The Transform to the frame is T = A which we get from the fullphys volume frameVol.
381 
382  if (!extXF) return false;
383  if (!extXF->alignableTransform()) return false;
384 
385  const GeoVFullPhysVol * child = extXF->child();
386  const GeoVFullPhysVol * frameVol = extXF->frame();
387 
388  FrameType newFrame = frame;
389  // If frame is other then check if "other" is actually local or global
390  if (frame == InDetDD::other) {
391  if (child && !frameVol) {
392  // frame = 0 indicates to use global frame
393  newFrame = InDetDD::global;
394  } else if (!child || child == frameVol){
395  // if child is 0 or the they are the same volumes then its local
396  newFrame = InDetDD::local;
397  } // else its "other" already.
398  }
399 
400  if (newFrame == InDetDD::global) { // Global
401  if (!child) {
402  msg(MSG::ERROR) << "global frame specified, but child == 0" << endmsg;
403  } else {
404  const GeoTrf::Transform3D & childXF = child->getDefAbsoluteTransform(alignStore);
405  extXF->alignableTransform()->setDelta(childXF.inverse() * delta * childXF);
406  }
407 
408  } else if (frame == InDetDD::local) { // Local
409  // if its a local frame then no transform necessary. We set it directly.
410  extXF->alignableTransform()->setDelta(delta);
411 
412  } else { // Other frame
413  // if child or frame is zero it will have been set to local or global above
414  if (!child) { // CID 113112
415  // shouldn't be happening, if child is null then something is terribly wrong
416  ATH_MSG_ERROR("Child can't be null if frame is 'other'");
417  return false;
418  } else {
419  const GeoTrf::Transform3D & xfChild = child->getDefAbsoluteTransform(alignStore);
420  const GeoTrf::Transform3D & xfFrame = frameVol->getDefAbsoluteTransform(alignStore);
421  extXF->alignableTransform()->setDelta(xfChild.inverse() * xfFrame * delta * xfFrame.inverse() * xfChild);
422  }
423  }
424 
425  return true;
426  }
427 
428 
430  {
431  return align(I, keys);
432  }
433 
434 
435  // We invalidate all the elements if at least one alignment changed.
437  {
438  for (TRT_DetElementCollection::const_iterator element_iter = getDetectorElementBegin();
439  element_iter != getDetectorElementEnd();
440  ++element_iter) {
441 
442  if (*element_iter) {
443  (*element_iter)->invalidate();
444  }
445  }
446  }
447 
449  {
450  for (TRT_DetElementCollection::const_iterator element_iter = getDetectorElementBegin();
451  element_iter != getDetectorElementEnd();
452  ++element_iter) {
453 
454  if (*element_iter) {
455  (*element_iter)->updateAllCaches();
456  }
457  }
458  }
459 
460 
462  {
463  return getIdHelper()->is_trt(id);
464  }
465 
466 
468  {
469  if(msgLvl(MSG::DEBUG))
470  msg(MSG::DEBUG) << "Processing TRT fine alignment." << endmsg;
471 
472  const TRTCond::StrawDxContainer* container = nullptr;
473  StatusCode sc = StatusCode::FAILURE;
475  sc = m_detStore->retrieve(container, key);
476  }
477 
478  if (sc.isFailure()) {
479  if (msgLvl(MSG::INFO))
480  msg(MSG::INFO) << "Cannot find StrawDxContainer for key "
481  << key << " - no fine alignment " << endmsg;
482  throw std::runtime_error("Unable to apply TRT fine alignment. This is normal for simulation");
483  //return false;
484  } else {
485 
486  // Loop trough all barrel elements and pass container.
487 
488  this->setDxContainer(container);
489 
490  for (TRT_DetElementCollection::const_iterator element_iter = getDetectorElementBegin();
491  element_iter != getDetectorElementEnd();
492  ++element_iter) {
493  TRT_BaseElement * element = *element_iter;
494  if (element) {
495  element->invalidate();
496  }
497  }
498  return false; // we return false as we have already invalidated the elements
499  }
500  }
501 
502  bool TRT_DetectorManager::processSpecialAlignment(const std::string& /*key*/,
503  const CondAttrListCollection* /*obj*/,
504  GeoVAlignmentStore* /*alignStore*/) const {
505  return false;
506  }
507 
508 
510  {
511  return this;
512  }
513 
514  // New global alignment filders
515  bool TRT_DetectorManager::processGlobalAlignment(const std::string & key, int level, FrameType frame,
516  const CondAttrListCollection* obj, GeoVAlignmentStore* alignStore) const
517  {
518 
519  bool alignmentChange = false;
520 
521  ATH_MSG_INFO("Processing new global alignment containers with key " << key << " in the " << frame << " frame at level " << level);
522 
524  const CondAttrListCollection* atrlistcol=obj;
525  //cppcheck-suppress nullPointerRedundantCheck
526  if (!atrlistcol) {
527  ATH_MSG_INFO("Read alignment from detector store with key " << key);
528  if (StatusCode::SUCCESS!=m_detStore->retrieve(atrlistcol,key)) {
529  ATH_MSG_WARNING("Cannot find new global align Container for key "
530  << key << " - no new global alignment");
531  return alignmentChange;
532  }
533  }
534  // Avoid cppcheck warning.
535  if (!atrlistcol) {
536  return alignmentChange;
537  }
538  {
539  // loop over objects in collection
540  //cppcheck-suppress nullPointerRedundantCheck
541  for (const auto & citr : *atrlistcol) {
542 
543  const coral::AttributeList& atrlist=citr.second;
544  ident = getIdHelper()->module_id(atrlist["bec"].data<int>(),
545  atrlist["layer"].data<int>(),
546  atrlist["sector"].data<int>());
547 
548  // Follow same definitions as in TRT_AlignDbSvc.cxx
549  CLHEP::Hep3Vector newtranslation(atrlist["Tx"].data<float>(),atrlist["Ty"].data<float>(),atrlist["Tz"].data<float>());
550  CLHEP::HepRotation newrotation;
551  newrotation.set(atrlist["phi"].data<float>(),atrlist["theta"].data<float>(),atrlist["psi"].data<float>());
552  HepGeom::Transform3D newtransform(newrotation, newtranslation);
553 
554  msg(MSG::DEBUG) << "New global DB -- channel: " << citr.first
555  << " ,bec: " << atrlist["bec"].data<int>()
556  << " ,layer: " << atrlist["layer"].data<int>()
557  << " ,sector: " << atrlist["sector"].data<int>()
558  << " ,Tx: " << atrlist["Tx"].data<float>()
559  << " ,Ty: " << atrlist["Ty"].data<float>()
560  << " ,Tz: " << atrlist["Tz"].data<float>()
561  << " ,phi: " << atrlist["phi"].data<float>()
562  << " ,theta: " << atrlist["theta"].data<float>()
563  << " ,psi: " << atrlist["psi"].data<float>() << endmsg;
564 
565  // Set the new transform; Will replace existing one with updated transform
567  ident,
568  Amg::CLHEPTransformToEigen(newtransform),
569  frame,
570  alignStore);
571 
572  if (!status) {
573  if (msgLvl(MSG::DEBUG)) {
574  msg(MSG::DEBUG) << "Cannot set AlignableTransform for identifier."
576  << " at level " << level << " for new global DB " << endmsg;
577  }
578  }
579 
580  alignmentChange = (alignmentChange || status);
581  }
582  }
583  return alignmentChange;
584  }
585 
587  {
588  m_barrelDescriptors.insert(barrelDescriptor);
589  }
590 
592  {
593  m_endcapDescriptors.insert(endcapDescriptor);
594  }
595 
596 } // namespace InDetDD
InDetDD::FrameType
FrameType
Definition: InDetDD_Defs.h:16
InDetDD::ExtendedAlignableTransform::alignableTransform
GeoAlignableTransform * alignableTransform()
Definition: ExtendedAlignableTransform.h:43
InDetDD::TRT_DetectorManager::manageBarrelElement
void manageBarrelElement(TRT_BarrelElement *barrel)
Definition: TRT_DetectorManager.cxx:92
InDetDD::TRT_DetectorManager::conditions
const TRT_Conditions * conditions() const
Conditions interface (mostly for internal use):-------------------------—.
Definition: TRT_DetectorManager.cxx:509
TRT_ID::layer_id
Identifier layer_id(int barrel_ec, int phi_module, int layer_or_wheel, int straw_layer) const
For an individual straw layer.
Definition: TRT_ID.h:500
StoreGateSvc::contains
bool contains(const TKEY &key) const
Look up a keyed object in TDS (compare also tryRetrieve) returns false if object not available in TDS...
InDetDD::TRT_DetectorManager::addAlignableTransform
void addAlignableTransform(int level, const Identifier &id, GeoAlignableTransform *transform, const GeoVFullPhysVol *child=0, const GeoVFullPhysVol *frameVol=0)
Add alignable transforms: GeoModel/CLHEP based.
Definition: TRT_DetectorManager.cxx:282
InDetDD::TRT_BarrelElement
Definition: TRT_BarrelElement.h:44
python.SystemOfUnits.m
int m
Definition: SystemOfUnits.py:91
PlotCalibFromCool.dv
dv
Definition: PlotCalibFromCool.py:762
InDetDD::TRT_DetectorManager::getDetectorElementCollection
const TRT_DetElementCollection * getDetectorElementCollection() const
Access to Whole Collection of Elements ---------------------------------—.
Definition: TRT_DetectorManager.cxx:170
InDetDD::TRT_DetectorManager::setEndcapDescriptor
void setEndcapDescriptor(const TRT_EndcapDescriptor *endcapDescriptor)
Definition: TRT_DetectorManager.cxx:591
InDetDD::TRT_DetElementContainer::manageEndcapElement
void manageEndcapElement(TRT_EndcapElement *endcap, const TRT_ID *idHelper)
Definition: TRT_DetElementContainer.cxx:168
ATH_MSG_INFO
#define ATH_MSG_INFO(x)
Definition: AthMsgStreamMacros.h:31
TRT_DetectorManager.h
InDetDD::ExtendedAlignableTransform::frame
const GeoVFullPhysVol * frame()
Definition: ExtendedAlignableTransform.h:45
InDetDD::TRT_DetectorManager::m_ownsIdHelper
bool m_ownsIdHelper
Definition: TRT_DetectorManager.h:260
InDetDD::TRT_DetectorManager::m_idHelper
const TRT_ID * m_idHelper
Definition: TRT_DetectorManager.h:259
InDetDD::TRT_DetectorManager::invalidateAll
virtual void invalidateAll() const override
Invalidate cache for all detector elements.
Definition: TRT_DetectorManager.cxx:436
index
Definition: index.py:1
InDetDD::TRT_DetElementContainer
Class to hold different TRT detector elements structures.
Definition: TRT_DetElementContainer.h:25
InDetDD::TRT_DetectorManager::getBarrelElement
const TRT_BarrelElement * getBarrelElement(unsigned int positive, unsigned int moduleIndex, unsigned int phiIndex, unsigned int strawLayerIndex) const
Access Barrel Elements:---------------—(Fast)-------------------------—.
Definition: TRT_DetectorManager.cxx:103
InDetDD::TRT_DetectorManager::setBarrelTransformField
void setBarrelTransformField(size_t i, const GeoXF::Function *field)
Definition: TRT_DetectorManager.cxx:186
InDetDD::TRT_BarrelDescriptor
Definition: TRT_BarrelDescriptor.h:40
InDetDD::TRT_DetectorManager::m_barrelXF
const GeoXF::Function * m_barrelXF[3]
Definition: TRT_DetectorManager.h:261
CSV_InDetExporter.new
new
Definition: CSV_InDetExporter.py:145
ExtendedAlignableTransform.h
InDetDD::TRT_DetectorManager::m_digversname
std::string m_digversname
Definition: TRT_DetectorManager.h:266
InDetDD::TRT_EndcapElement
Definition: TRT_EndcapElement.h:44
InDetDD::TRT_DetectorManager::processSpecialAlignment
bool processSpecialAlignment(const std::string &key, InDetDD::AlignFolderType dummy) const override
Definition: TRT_DetectorManager.cxx:467
InDetDD::TRT_DetectorManager::setAlignableTransformDelta
virtual bool setAlignableTransformDelta(int level, const Identifier &id, const Amg::Transform3D &delta, FrameType frame, GeoVAlignmentStore *alignStore) const override
Set alignable transforms: Amg based.
Definition: TRT_DetectorManager.cxx:313
InDetDD::TRT_DetectorManager::m_endcapDescriptors
std::set< const TRT_EndcapDescriptor * > m_endcapDescriptors
Definition: TRT_DetectorManager.h:274
IOVSVC_CALLBACK_ARGS_P
#define IOVSVC_CALLBACK_ARGS_P(I, K)
short hand for IOVSvc call back argument list, to be used when access to formal arguments is needed,...
Definition: IOVSvcDefs.h:42
AtlasDetectorID::is_trt
bool is_trt(Identifier id) const
Definition: AtlasDetectorID.h:782
InDetDD::global
@ global
Definition: InDetDD_Defs.h:16
python.PyKernel.AttributeList
AttributeList
Definition: PyKernel.py:36
InDetDD::TRT_DetectorManager::barrelTransformField
const GeoXF::Function * barrelTransformField(size_t i) const
Definition: TRT_DetectorManager.cxx:191
InDetDD::TRT_Conditions
Definition: TRT_Conditions.h:30
CondAttrListCollection
This class is a collection of AttributeLists where each one is associated with a channel number....
Definition: CondAttrListCollection.h:52
InDetDD::TRT_DetectorManager::TRT_DetectorManager
TRT_DetectorManager(StoreGateSvc *detStore)
Definition: TRT_DetectorManager.cxx:29
InDetDD::TRT_DetectorManager::getIdHelper
virtual const TRT_ID * getIdHelper() const override
Definition: TRT_DetectorManager.cxx:135
InDetDD::TRT_DetElementContainer::manageBarrelElement
void manageBarrelElement(TRT_BarrelElement *barrel, const TRT_ID *idHelper)
Definition: TRT_DetElementContainer.cxx:126
AthenaPoolTestRead.sc
sc
Definition: AthenaPoolTestRead.py:27
mergePhysValFiles.end
end
Definition: DataQuality/DataQualityUtils/scripts/mergePhysValFiles.py:93
python.iconfTool.models.loaders.level
level
Definition: loaders.py:20
InDetDD::TRT_EndcapDescriptor
class TRT_EndcapDescriptor
Definition: TRT_EndcapDescriptor.h:30
InDetDD::TRT_DetectorManager::addTreeTop
void addTreeTop(const PVLink &)
Definition: TRT_DetectorManager.cxx:87
StoreGateSvc::retrieve
StatusCode retrieve(const T *&ptr) const
Retrieve the default object into a const T*.
InDetDD::TRT_DetectorManager::manageEndcapElement
void manageEndcapElement(TRT_EndcapElement *endcap)
Definition: TRT_DetectorManager.cxx:98
TRT_EndcapCode.h
InDetDD::TRT_DetElementContainer::setNumerology
void setNumerology(const TRT_Numerology *mynum)
Definition: TRT_DetElementContainer.cxx:24
TRT_EndcapElement.h
StoreGateSvc
The Athena Transient Store API.
Definition: StoreGateSvc.h:125
InDetDD::TRT_DetectorManager::getTreeTop
virtual PVConstLink getTreeTop(unsigned int i) const override
Definition: TRT_DetectorManager.cxx:82
InDetDD::TRT_DetectorManager::getNumerology
TRT_Numerology * getNumerology()
Access Numerological information:---------------------------------------—.
Definition: TRT_DetectorManager.cxx:46
InDetDD::TRT_DetectorManager::m_endcapXF
const GeoXF::Function * m_endcapXF[3]
Definition: TRT_DetectorManager.h:262
InDetDD::TRT_Numerology
Definition: TRT_Numerology.h:22
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
AthMessaging::msgLvl
bool msgLvl(const MSG::Level lvl) const
Test the output level.
Definition: AthMessaging.h:151
InDetDD::TRT_DetectorManager::endcapTransformField
const GeoXF::Function * endcapTransformField(size_t i) const
Definition: TRT_DetectorManager.cxx:200
lumiFormat.i
int i
Definition: lumiFormat.py:85
InDetDD::ExtendedAlignableTransform::child
const GeoVFullPhysVol * child()
Definition: ExtendedAlignableTransform.h:44
InDetDD::TRT_DetectorManager::getNumTreeTops
virtual unsigned int getNumTreeTops() const override
Access Raw Geometry:----------------------------------------------------—.
Definition: TRT_DetectorManager.cxx:77
endmsg
#define endmsg
Definition: AnalysisConfig_Ntuple.cxx:63
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
AlignableTransformContainer.h
InDetDD::TRT_DetectorManager::m_digvers
unsigned int m_digvers
Definition: TRT_DetectorManager.h:265
Amg::Transform3D
Eigen::Affine3d Transform3D
Definition: GeoPrimitives.h:46
InDetDD::TRT_DetectorManager::m_alignableTransforms
std::vector< AlignableTransformMap > m_alignableTransforms
Definition: TRT_DetectorManager.h:270
Amg::transform
Amg::Vector3D transform(Amg::Vector3D &v, Amg::Transform3D &tr)
Transform a point from a Trasformation3D.
Definition: GeoPrimitivesHelpers.h:156
InDetDD::FIRST_HIGHER_LEVEL
const int FIRST_HIGHER_LEVEL
Definition: PixelDetectorManager.cxx:22
InDetDD::TRT_DetectorManager::m_volume
std::vector< PVLink > m_volume
Definition: TRT_DetectorManager.h:254
InDetDD::InDetDetectorManager
Definition: InDetDetectorManager.h:60
hist_file_dump.f
f
Definition: hist_file_dump.py:135
InDetDD::TRT_DetectorManager::m_numerology
TRT_Numerology * m_numerology
Definition: TRT_DetectorManager.h:258
InDetDD::TRT_DetectorManager::setAlignableTransformAnyFrameDelta
bool setAlignableTransformAnyFrameDelta(ExtendedAlignableTransform *extXF, const Amg::Transform3D &delta, FrameType frame, GeoVAlignmentStore *alignStore) const
Set alignable transforms: Amg based.
Definition: TRT_DetectorManager.cxx:337
InDetDD::InDetDetectorManager::m_detStore
StoreGateSvc * m_detStore
Definition: InDetDetectorManager.h:99
AthMessaging::msg
MsgStream & msg() const
The standard message stream.
Definition: AthMessaging.h:164
TRT_BarrelElement.h
InDetDD::TRT_DetectorManager::m_elementContainer
TRT_DetElementContainer m_elementContainer
Definition: TRT_DetectorManager.h:256
InDetDD::TRT_DetectorManager::alignmentCallback
StatusCode alignmentCallback(IOVSVC_CALLBACK_ARGS)
Call back for alignment updates, DEPRECATED.
Definition: TRT_DetectorManager.cxx:429
InDetDD::TRT_DetectorManager::getDetectorElementBegin
TRT_DetElementCollection::const_iterator getDetectorElementBegin() const
Definition: TRT_DetectorManager.cxx:175
InDetDD::TRT_DetectorManager::getDetectorElementEnd
TRT_DetElementCollection::const_iterator getDetectorElementEnd() const
Definition: TRT_DetectorManager.cxx:180
InDetDD::local
@ local
Definition: InDetDD_Defs.h:16
CLHEPtoEigenConverter.h
InDetDD::TRT_DetectorManager::getEndcapElement
const TRT_EndcapElement * getEndcapElement(unsigned int positive, unsigned int wheelIndex, unsigned int strawLayerIndex, unsigned int phiIndex) const
Access Endcap Elements:---------------—(Fast)--------------------------—.
Definition: TRT_DetectorManager.cxx:119
python.PyKernel.detStore
detStore
Definition: PyKernel.py:41
Muon::nsw::unknown
@ unknown
Definition: NSWTriggerElink.h:36
InDetDD::ATLAS_NOT_THREAD_SAFE
void TRT_DetectorManager::addKey ATLAS_NOT_THREAD_SAFE(const std::string &key, int level)
Definition: TRT_DetectorManager.cxx:233
InDetDD::TRT_DetectorManager::identifierBelongs
virtual bool identifierBelongs(const Identifier &id) const override
Check identifier is for this detector.
Definition: TRT_DetectorManager.cxx:461
InDetDD::TRT_DetElementContainer::getBarrelDetElement
const TRT_BarrelElement * getBarrelDetElement(unsigned int positive, unsigned int moduleIndex, unsigned int phiIndex, unsigned int strawLayerIndex) const
Definition: TRT_DetElementContainer.cxx:39
id
SG::auxid_t id
Definition: Control/AthContainers/Root/debug.cxx:220
InDetDD::TRT_DetectorManager::setGasType
void setGasType(const ActiveGasType &)
Definition: TRT_DetectorManager.cxx:210
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:221
InDetDD::InDetDetectorManager::align
StatusCode align(IOVSVC_CALLBACK_ARGS) const
InDetDD::TRT_DetectorManager::getElement
const TRT_BaseElement * getElement(Identifier id) const
Access Elements Generically---------------------------------------------—.
Definition: TRT_DetectorManager.cxx:148
InDetDD::TRT_DetectorManager::digitizationVersionName
const std::string & digitizationVersionName() const
Definition: TRT_DetectorManager.cxx:220
TRTCond::StrawDxContainer
Definition: StrawDxContainer.h:109
DataHandle
an iterator over instances of a given type in StoreGateSvc. It d-casts and caches locally the pointed...
Definition: DataHandle.h:42
InDetDD::TRT_DetectorManager::m_barrelDescriptors
std::set< const TRT_BarrelDescriptor * > m_barrelDescriptors
Definition: TRT_DetectorManager.h:273
InDetDD::TRT_BaseElement::invalidate
void invalidate()
Invalidate cache.
Definition: TRT_BaseElement.cxx:190
TRT::Hit::ident
@ ident
Definition: HitInfo.h:77
InDetDD::ExtendedAlignableTransform
Definition: ExtendedAlignableTransform.h:31
InDetDD::TRT_DetectorManager::setIdHelper
void setIdHelper(const TRT_ID *idHelper, bool owns=true)
Get the ID helper: -----------------------------------------------------—.
Definition: TRT_DetectorManager.cxx:140
InDetDD::TRT_DetectorManager::getDetectorElementContainer
const TRT_DetElementContainer * getDetectorElementContainer() const
Access the element container -------------------------------------------—.
Definition: TRT_DetectorManager.cxx:165
AlignableTransform.h
eflowRec::phiIndex
unsigned int phiIndex(float phi, float binsize)
calculate phi index for a given phi
Definition: EtaPhiLUT.cxx:23
DeMoScan.index
string index
Definition: DeMoScan.py:364
TRT_ID
Definition: TRT_ID.h:84
InDetDD::TRT_DetectorManager::addKey
void addKey(const std::string &key, int level, FrameType frame)
Definition: TRT_DetectorManager.cxx:246
InDetDD::TRT_DetectorManager::m_gasType
ActiveGasType m_gasType
Definition: TRT_DetectorManager.h:264
InDetDD::other
@ other
Definition: InDetDD_Defs.h:16
AtlasDetectorID::show_to_string
std::string show_to_string(Identifier id, const IdContext *context=0, char sep='.') const
or provide the printout in string form
Definition: AtlasDetectorID.cxx:574
ATH_MSG_WARNING
#define ATH_MSG_WARNING(x)
Definition: AthMsgStreamMacros.h:32
InDetDD
Message Stream Member.
Definition: FakeTrackBuilder.h:8
Amg::CLHEPTransformToEigen
Amg::Transform3D CLHEPTransformToEigen(const HepGeom::Transform3D &CLHEPtransf)
Converts a CLHEP-based HepGeom::Transform3D into an Eigen Amg::Transform3D.
Definition: CLHEPtoEigenConverter.h:38
InDetDD::TRT_DetectorManager::gasType
ActiveGasType gasType() const
Definition: TRT_DetectorManager.cxx:205
InDetDD::TRT_DetectorManager::~TRT_DetectorManager
~TRT_DetectorManager()
Definition: TRT_DetectorManager.cxx:54
InDetDD::TRT_DetectorManager::digitizationVersion
unsigned int digitizationVersion() const
Get and set information about digitization version ---------------------—.
Definition: TRT_DetectorManager.cxx:215
DEBUG
#define DEBUG
Definition: page_access.h:11
InDetDD::TRT_DetectorManager::setEndcapTransformField
void setEndcapTransformField(size_t i, const GeoXF::Function *field)
Definition: TRT_DetectorManager.cxx:195
InDetDD::TRT_DetectorManager::updateAll
virtual void updateAll() const override
Update all caches.
Definition: TRT_DetectorManager.cxx:448
InDetDD::TRT_DetectorManager::setDigitizationVersion
void setDigitizationVersion(const unsigned int &, const std::string &name)
Definition: TRT_DetectorManager.cxx:225
InDetDD::TRT_DetElementContainer::getElements
const TRT_DetElementCollection * getElements() const
Definition: TRT_DetElementContainer.cxx:29
TRT_Numerology.h
InDetDD::TRT_Conditions::setDxContainer
void setDxContainer(const TRTCond::StrawDxContainer *container) const
Definition: TRT_Conditions.cxx:20
InDetDD::TRT_DetectorManager::ActiveGasType
ActiveGasType
Definition: TRT_DetectorManager.h:89
python.Bindings.keys
keys
Definition: Control/AthenaPython/python/Bindings.py:798
merge.status
status
Definition: merge.py:17
python.Constants.VERBOSE
int VERBOSE
Definition: Control/AthenaCommon/python/Constants.py:14
I
#define I(x, y, z)
Definition: MD5.cxx:116
InDetDD::TRT_DetElementCollection
Class to hold collection of TRT detector elements.
Definition: TRT_DetElementCollection.h:28
IdentifierHash
This is a "hash" representation of an Identifier. This encodes a 32 bit index which can be used to lo...
Definition: IdentifierHash.h:25
InDetDD::InDetDetectorManager::addChannel
void addChannel(const std::string &key, int level, FrameType frame)
Alignment access.
Definition: InDetDetectorManager.cxx:56
InDetDD::TRT_DetElementContainer::getEndcapDetElement
const TRT_EndcapElement * getEndcapDetElement(unsigned int positive, unsigned int wheelIndex, unsigned int strawLayerIndex, unsigned int phiIndex) const
Definition: TRT_DetElementContainer.cxx:62
TRT_BarrelCode.h
python.PyAthena.obj
obj
Definition: PyAthena.py:132
TRT_Conditions.h
StoreGateSvc.h
python.AutoConfigFlags.msg
msg
Definition: AutoConfigFlags.py:7
InDetDD::AlignFolderType
AlignFolderType
Definition: InDetDD_Defs.h:19
StrawDxContainer.h
Class for storing/accessing trt endpoint corrections data.
InDetDD::TRT_DetectorManager::processGlobalAlignment
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.
Definition: TRT_DetectorManager.cxx:515
TRT_ID::straw_layer_hash
IdentifierHash straw_layer_hash(Identifier straw_layer_id) const
straw_layer hash from id - optimized
Definition: TRT_ID.h:750
InDetDD::TRT_DetectorManager::setBarrelDescriptor
void setBarrelDescriptor(const TRT_BarrelDescriptor *barrelDescriptor)
Set TRT_Barrel/EndcapDescriptor pointer to the internal sets to delete them in the destructor.
Definition: TRT_DetectorManager.cxx:586
InDetDD::TRT_BaseElement
Definition: TRT_BaseElement.h:57
TRT_ID::module_id
Identifier module_id(int barrel_ec, int phi_module, int layer_or_wheel) const
For an individual module phi sector.
Definition: TRT_ID.h:448
mapkey::key
key
Definition: TElectronEfficiencyCorrectionTool.cxx:37
Identifier
Definition: IdentifierFieldParser.cxx:14