ATLAS Offline Software
Public Member Functions | Private Types | Private Member Functions | Private Attributes | List of all members
MuonGM::MuonStation Class Reference

#include <MuonStation.h>

Inheritance diagram for MuonGM::MuonStation:
Collaboration diagram for MuonGM::MuonStation:

Public Member Functions

 MuonStation (std::string_view stName, double Ssize, double Rsize, double Zsize, double LongSsize, double LongRsize, double LongZsize, int zi, int fi, bool m_descratzneg)
 
 ~MuonStation ()
 
int getPhiIndex () const
 a la AMDB More...
 
int getEtaIndex () const
 a la AMDB More...
 
const std::string & getKey () const
 
std::string getStationType () const
 like BMS, T1F, CSL More...
 
const std::string & getStationName () const
 like BMS5, T1F1, CSL1 More...
 
void setEtaPhiIndices (int eta, int phi)
 a la AMDB More...
 
double Rsize () const
 
double Ssize () const
 
double Zsize () const
 
double LongRsize () const
 
double LongSsize () const
 
double LongZsize () const
 
double RsizeMdtStation () const
 
double ZsizeMdtStation () const
 
bool endcap () const
 
bool barrel () const
 
double xAmdbCRO () const
 
void setxAmdbCRO (double xpos)
 
void setTransform (GeoAlignableTransform *xf)
 
void setBlineFixedPointInAmdbLRS (double s0, double z0, double t0)
 
const Amg::Vector3DgetBlineFixedPointInAmdbLRS () const
 
void updateBlineFixedPointInAmdbLRS ()
 
void setNativeToAmdbLRS (Amg::Transform3D xf)
 
void setNominalAmdbLRSToGlobal (Amg::Transform3D xf)
 
void setDeltaAmdbLRS (Amg::Transform3D xf)
 set the delta transform in the amdb frame and update the geoModel Delta More...
 
void setDelta_fromAline_forComp (int, double, double, double, double, double, double)
 
void setDelta_fromAline (double, double, double, double, double, double)
 set the delta transform in the amdb frame and update the geoModel Delta More...
 
void addMuonReadoutElementWithAlTransf (MuonReadoutElement *a, GeoAlignableTransform *ptrsf, int jobIndex)
 
const MuonReadoutElementgetMuonReadoutElement (int jobIndex) const
 
MuonReadoutElementgetMuonReadoutElement (int jobIndex)
 
GeoAlignableTransform * getComponentAlTransf (int jobIndex) const
 
int nMuonReadoutElements () const
 
void clearCache ()
 
void fillCache ()
 
void refreshCache ()
 
void setBline (const BLinePar *bline)
 
const GeoAlignableTransform * getGeoTransform () const
 
Amg::Transform3D getTransform () const
 
const Amg::Transform3DgetNativeToAmdbLRS () const
 
Amg::Transform3D getAmdbLRSToGlobal () const
 
const Amg::Transform3DgetNominalAmdbLRSToGlobal () const
 
double getALine_tras () const
 
double getALine_traz () const
 
double getALine_trat () const
 
double getALine_rots () const
 
double getALine_rotz () const
 
double getALine_rott () const
 
bool hasALines () const
 
bool hasBLines () const
 
bool hasMdtAsBuiltParams () const
 
const MdtAsBuiltPargetMdtAsBuiltParams () const
 
void setMdtAsBuiltParams (const MdtAsBuiltPar *xtomo)
 
void setPhysVol (const PVLink &vol)
 
PVConstLink getPhysVol () const
 
PVLink getPhysVol ()
 
bool msgLvl (const MSG::Level lvl) const
 Test the output level. More...
 
MsgStream & msg () const
 The standard message stream. More...
 
MsgStream & msg (const MSG::Level lvl) const
 The standard message stream. More...
 
void setLevel (MSG::Level lvl)
 Change the current logging level. More...
 

Private Types

using pairRE_AlignTransf = std::pair< MuonReadoutElement *, GeoAlignableTransform * >
 

Private Member Functions

void initMessaging () const
 Initialize our message level and MessageSvc. More...
 

Private Attributes

bool m_firstRequestBlineFixedP {true}
 
std::string m_statname {}
 
double m_Ssize {0.}
 
double m_Rsize {0.}
 
double m_Zsize {0.}
 
double m_LongSsize {0.}
 
double m_LongRsize {0.}
 
double m_LongZsize {0.}
 
double m_xAmdbCRO {0.}
 
bool m_descratzneg {false}
 
int m_statPhiIndex {0}
 
int m_statEtaIndex {0}
 
std::string m_key {}
 
GeoAlignableTransform * m_transform {nullptr}
 
Amg::Transform3D m_delta_amdb_frame {Amg::Transform3D::Identity()}
 
Amg::Transform3D m_native_to_amdbl {Amg::Transform3D::Identity()}
 
Amg::Transform3D m_amdbl_to_global {Amg::Transform3D::Identity()}
 
double m_rots {0.}
 
double m_rotz {0.}
 
double m_rott {0.}
 
bool m_hasALines {false}
 
bool m_hasBLines {false}
 
Amg::Vector3D m_BlineFixedPointInAmdbLRS {Amg::Vector3D::Zero()}
 
const MdtAsBuiltParm_XTomoData {nullptr}
 
std::map< int, pairRE_AlignTransfm_REwithAlTransfInStation {}
 keep track of the REs in this station More...
 
PVLink m_physVol {nullptr}
 Link the full physical volume associated with the station. More...
 
std::string m_nm
 Message source name. More...
 
boost::thread_specific_ptr< MsgStream > m_msg_tls
 MsgStream instance (a std::cout like with print-out levels) More...
 
std::atomic< IMessageSvc * > m_imsg { nullptr }
 MessageSvc pointer. More...
 
std::atomic< MSG::Level > m_lvl { MSG::NIL }
 Current logging level. More...
 
std::atomic_flag m_initialized ATLAS_THREAD_SAFE = ATOMIC_FLAG_INIT
 Messaging initialized (initMessaging) More...
 

Detailed Description

Definition at line 51 of file MuonStation.h.

Member Typedef Documentation

◆ pairRE_AlignTransf

using MuonGM::MuonStation::pairRE_AlignTransf = std::pair<MuonReadoutElement*, GeoAlignableTransform*>
private

Definition at line 156 of file MuonStation.h.

Constructor & Destructor Documentation

◆ MuonStation()

MuonGM::MuonStation::MuonStation ( std::string_view  stName,
double  Ssize,
double  Rsize,
double  Zsize,
double  LongSsize,
double  LongRsize,
double  LongZsize,
int  zi,
int  fi,
bool  m_descratzneg 
)

Definition at line 26 of file MuonStation.cxx.

26  :
27  AthMessaging{"MuonStation"},
28  m_statname(stName) {
29  m_Ssize = Ssize;
30  m_Rsize = Rsize;
31  m_Zsize = Zsize;
35  m_descratzneg = descratzneg;
36  m_statEtaIndex = zi;
38  }
39 
40  MuonStation::~MuonStation() = default;
41 

◆ ~MuonStation()

MuonGM::MuonStation::~MuonStation ( )
default

Member Function Documentation

◆ addMuonReadoutElementWithAlTransf()

void MuonGM::MuonStation::addMuonReadoutElementWithAlTransf ( MuonReadoutElement a,
GeoAlignableTransform *  ptrsf,
int  jobIndex 
)

Definition at line 178 of file MuonStation.cxx.

186  {

◆ barrel()

bool MuonGM::MuonStation::barrel ( ) const

Definition at line 364 of file MuonStation.cxx.

364  { return !barrel(); }
365 

◆ clearCache()

void MuonGM::MuonStation::clearCache ( )

Definition at line 238 of file MuonStation.cxx.

240  {
241  ATH_MSG_WARNING(" in MuonStation:clearCache " << getStationType() << " at zi/fi " << getEtaIndex() << "/"
242  << getPhiIndex() << " trying to get a not existing RE (iteration n. ) " << jobId << " RE is null, skipping" );
243  continue;
244  }
245  re->clearCache();
246  ATH_MSG_DEBUG("cache cleared ");
247  }
248  }
249 
250  void MuonStation::fillCache() {
251  for (auto& [jobId, readAlignPair] : m_REwithAlTransfInStation) {

◆ endcap()

bool MuonGM::MuonStation::endcap ( ) const

Definition at line 367 of file MuonStation.cxx.

367 {

◆ fillCache()

void MuonGM::MuonStation::fillCache ( )

Definition at line 253 of file MuonStation.cxx.

254  {
255  ATH_MSG_WARNING(" in MuonStation:fillCache " << getStationType() << " at zi/fi " << getEtaIndex() << "/"
256  << getPhiIndex() << " trying to get a not existing RE (iteration n. ) " << jobId << " RE is null, skipping" );
257  continue;
258  }
259  re->fillCache();
260  }
261  }
262 
264  clearCache();

◆ getALine_rots()

double MuonGM::MuonStation::getALine_rots ( ) const
inline

Definition at line 193 of file MuonStation.h.

193 { return m_rots; }

◆ getALine_rott()

double MuonGM::MuonStation::getALine_rott ( ) const
inline

Definition at line 195 of file MuonStation.h.

195 { return m_rott; }

◆ getALine_rotz()

double MuonGM::MuonStation::getALine_rotz ( ) const
inline

Definition at line 194 of file MuonStation.h.

194 { return m_rotz; }

◆ getALine_tras()

double MuonGM::MuonStation::getALine_tras ( ) const
inline

Definition at line 190 of file MuonStation.h.

190 { return m_delta_amdb_frame.translation()[0]; }

◆ getALine_trat()

double MuonGM::MuonStation::getALine_trat ( ) const
inline

Definition at line 192 of file MuonStation.h.

192 { return m_delta_amdb_frame.translation()[2]; }

◆ getALine_traz()

double MuonGM::MuonStation::getALine_traz ( ) const
inline

Definition at line 191 of file MuonStation.h.

191 { return m_delta_amdb_frame.translation()[1]; }

◆ getAmdbLRSToGlobal()

Amg::Transform3D MuonGM::MuonStation::getAmdbLRSToGlobal ( ) const
inline

Definition at line 186 of file MuonStation.h.

◆ getBlineFixedPointInAmdbLRS()

const Amg::Vector3D & MuonGM::MuonStation::getBlineFixedPointInAmdbLRS ( ) const

Definition at line 81 of file MuonStation.cxx.

83  {
84  if (!m_firstRequestBlineFixedP) return;

◆ getComponentAlTransf()

GeoAlignableTransform * MuonGM::MuonStation::getComponentAlTransf ( int  jobIndex) const

Definition at line 173 of file MuonStation.cxx.

175  {
176  ATH_MSG_DEBUG("addMuonReadoutElementWithAlTransf for station " << getStationName() << " at zi/fi = " << getEtaIndex()

◆ getEtaIndex()

int MuonGM::MuonStation::getEtaIndex ( ) const
inline

a la AMDB

Definition at line 163 of file MuonStation.h.

163 { return m_statEtaIndex; }

◆ getGeoTransform()

const GeoAlignableTransform * MuonGM::MuonStation::getGeoTransform ( ) const
inline

Definition at line 167 of file MuonStation.h.

167 { return m_transform; }

◆ getKey()

const std::string & MuonGM::MuonStation::getKey ( ) const
inline

Definition at line 171 of file MuonStation.h.

171 { return m_key; }

◆ getMdtAsBuiltParams()

const MdtAsBuiltPar * MuonGM::MuonStation::getMdtAsBuiltParams ( ) const

Definition at line 369 of file MuonStation.cxx.

373  {
374  m_XTomoData = xtomo;

◆ getMuonReadoutElement() [1/2]

MuonReadoutElement * MuonGM::MuonStation::getMuonReadoutElement ( int  jobIndex)

Definition at line 168 of file MuonStation.cxx.

170  {
171  std::map<int, pairRE_AlignTransf>::const_iterator itr = m_REwithAlTransfInStation.find(jobIndex);

◆ getMuonReadoutElement() [2/2]

const MuonReadoutElement * MuonGM::MuonStation::getMuonReadoutElement ( int  jobIndex) const

Definition at line 163 of file MuonStation.cxx.

165  {
166  std::map<int, pairRE_AlignTransf>::const_iterator itr = m_REwithAlTransfInStation.find(jobIndex);

◆ getNativeToAmdbLRS()

const Amg::Transform3D & MuonGM::MuonStation::getNativeToAmdbLRS ( ) const
inline

Definition at line 182 of file MuonStation.h.

182 { return m_native_to_amdbl; }

◆ getNominalAmdbLRSToGlobal()

const Amg::Transform3D & MuonGM::MuonStation::getNominalAmdbLRSToGlobal ( ) const
inline

Definition at line 184 of file MuonStation.h.

184 { return m_amdbl_to_global; }

◆ getPhiIndex()

int MuonGM::MuonStation::getPhiIndex ( ) const
inline

a la AMDB

Definition at line 162 of file MuonStation.h.

162 { return m_statPhiIndex; }

◆ getPhysVol() [1/2]

PVLink MuonGM::MuonStation::getPhysVol ( )

Definition at line 382 of file MuonStation.cxx.

◆ getPhysVol() [2/2]

PVConstLink MuonGM::MuonStation::getPhysVol ( ) const

Definition at line 381 of file MuonStation.cxx.

◆ getStationName()

const std::string & MuonGM::MuonStation::getStationName ( ) const
inline

like BMS5, T1F1, CSL1

Definition at line 165 of file MuonStation.h.

165 { return m_statname; }

◆ getStationType()

std::string MuonGM::MuonStation::getStationType ( ) const
inline

like BMS, T1F, CSL

Definition at line 164 of file MuonStation.h.

164 { return m_statname.substr(0, 3); }

◆ getTransform()

Amg::Transform3D MuonGM::MuonStation::getTransform ( ) const
inline

Definition at line 169 of file MuonStation.h.

169 { return m_transform->getTransform(); }

◆ hasALines()

bool MuonGM::MuonStation::hasALines ( ) const
inline

Definition at line 196 of file MuonStation.h.

196 { return m_hasALines; }

◆ hasBLines()

bool MuonGM::MuonStation::hasBLines ( ) const
inline

Definition at line 197 of file MuonStation.h.

197 { return m_hasBLines; }

◆ hasMdtAsBuiltParams()

bool MuonGM::MuonStation::hasMdtAsBuiltParams ( ) const
inline

Definition at line 198 of file MuonStation.h.

198 { return m_XTomoData != nullptr; }

◆ initMessaging()

void AthMessaging::initMessaging ( ) const
privateinherited

Initialize our message level and MessageSvc.

This method should only be called once.

Definition at line 39 of file AthMessaging.cxx.

40 {
42  m_lvl = m_imsg ?
43  static_cast<MSG::Level>( m_imsg.load()->outputLevel(m_nm) ) :
44  MSG::INFO;
45 }

◆ LongRsize()

double MuonGM::MuonStation::LongRsize ( ) const
inline

Definition at line 176 of file MuonStation.h.

176 { return m_LongRsize; }

◆ LongSsize()

double MuonGM::MuonStation::LongSsize ( ) const
inline

Definition at line 177 of file MuonStation.h.

177 { return m_LongSsize; }

◆ LongZsize()

double MuonGM::MuonStation::LongZsize ( ) const
inline

Definition at line 178 of file MuonStation.h.

178 { return m_LongZsize; }

◆ msg() [1/2]

MsgStream & AthMessaging::msg ( ) const
inlineinherited

The standard message stream.

Returns a reference to the default message stream May not be invoked before sysInitialize() has been invoked.

Definition at line 164 of file AthMessaging.h.

165 {
166  MsgStream* ms = m_msg_tls.get();
167  if (!ms) {
168  if (!m_initialized.test_and_set()) initMessaging();
169  ms = new MsgStream(m_imsg,m_nm);
170  m_msg_tls.reset( ms );
171  }
172 
173  ms->setLevel (m_lvl);
174  return *ms;
175 }

◆ msg() [2/2]

MsgStream & AthMessaging::msg ( const MSG::Level  lvl) const
inlineinherited

The standard message stream.

Returns a reference to the default message stream May not be invoked before sysInitialize() has been invoked.

Definition at line 179 of file AthMessaging.h.

180 { return msg() << lvl; }

◆ msgLvl()

bool AthMessaging::msgLvl ( const MSG::Level  lvl) const
inlineinherited

Test the output level.

Parameters
lvlThe message level to test against
Returns
boolean Indicating if messages at given level will be printed
Return values
trueMessages at level "lvl" will be printed

Definition at line 151 of file AthMessaging.h.

152 {
153  if (!m_initialized.test_and_set()) initMessaging();
154  if (m_lvl <= lvl) {
155  msg() << lvl;
156  return true;
157  } else {
158  return false;
159  }
160 }

◆ nMuonReadoutElements()

int MuonGM::MuonStation::nMuonReadoutElements ( ) const
inline

Definition at line 188 of file MuonStation.h.

188 { return m_REwithAlTransfInStation.size(); }

◆ refreshCache()

void MuonGM::MuonStation::refreshCache ( )

Definition at line 266 of file MuonStation.cxx.

268  {
269  if (!bline) return;

◆ Rsize()

double MuonGM::MuonStation::Rsize ( ) const
inline

Definition at line 173 of file MuonStation.h.

173 { return m_Rsize; }

◆ RsizeMdtStation()

double MuonGM::MuonStation::RsizeMdtStation ( ) const

Definition at line 295 of file MuonStation.cxx.

297  bool first = true;
298  int nmdt = 0;
299  ATH_MSG_DEBUG("RsizeMdtStation for " << getStationType() << " at zi/fi " << getEtaIndex() << "/" << getPhiIndex()
300  << " nRE = " << nMuonReadoutElements());
301 
302  for (int j = 1; j < 30; ++j) {
303  const MuonReadoutElement* activeComponent = getMuonReadoutElement(j);
304  if (!activeComponent) continue;
305  if (activeComponent->detectorType() !=Trk::DetectorElemType::Mdt) {
306  continue;
307  }
308  ++nmdt;
309  Rsize += activeComponent->getRsize() / 2.;
310  Rpos = activeComponent->toParentStation().translation();
311  if (first) {
312  RposFirst = Rpos;
313  first = false;
314  } else {
315  if (barrel())
316  Rsize += std::abs(Rpos.x() - RposFirst.x());
317  else
318  Rsize += std::abs(Rpos.y() - RposFirst.y());
319  }
320  }
321  if (nmdt == 1) Rsize = 2. * Rsize;
322  return Rsize;
323  }
324  double MuonStation::ZsizeMdtStation() const {
325  if (getStationName()[0] == 'T' || getStationName()[0] == 'C') return 0.; // TGC and CSC stations
326  double Zsize = 0.;

◆ setBline()

void MuonGM::MuonStation::setBline ( const BLinePar bline)

Definition at line 271 of file MuonStation.cxx.

272  ATH_MSG_DEBUG("fillCache cache .... for RE ... iteration n. " << jobId);
273  MuonReadoutElement* re = readAlignPair.first;
274  if (re->detectorType() !=Trk::DetectorElemType::Mdt) {
275  continue;
276  }
277  MdtReadoutElement* mdt = dynamic_cast<MdtReadoutElement*>(re);
278  mdt->setBLinePar(bline);
279  }
280  }
281 
282 
283 #if defined(FLATTEN)

◆ setBlineFixedPointInAmdbLRS()

void MuonGM::MuonStation::setBlineFixedPointInAmdbLRS ( double  s0,
double  z0,
double  t0 
)

Definition at line 65 of file MuonStation.cxx.

72  : stationName/Jff/Jzz " << getStationType() << " " << getPhiIndex() << " "
73  << getEtaIndex() << " nominal(i.e. from-station-envelop-only) B-line fixed point "
74  << Amg::toString(m_BlineFixedPointInAmdbLRS));
75 
76  }
77 
78  const Amg::Vector3D& MuonStation::getBlineFixedPointInAmdbLRS() const {
79  // needed to update the station-level BlineFixedPoint with data from second multilayer

◆ setDelta_fromAline()

void MuonGM::MuonStation::setDelta_fromAline ( double  tras,
double  traz,
double  trat,
double  rots,
double  rotz,
double  rott 
)

set the delta transform in the amdb frame and update the geoModel Delta

Definition at line 140 of file MuonStation.cxx.

143  {Amg::Transform3D::Identity()};
144  if (std::abs(tras) + std::abs(traz) + std::abs(trat) + (std::abs(rots) + std::abs(rotz) + std::abs(rott)) * 1000. > 0.01) {
145  // compute the delta transform in the local AMDB frame
146  delta_amdb = Amg::Translation3D{tras, traz, trat} *
148  m_hasALines = true;
149  }
150 
151  // store the delta transform in the local AMDB frame
152  setDeltaAmdbLRS(delta_amdb);
153 
154  ATH_MSG_DEBUG("Station " << getStationType() << " at zi/fi " << getEtaIndex() << "/" << getPhiIndex()
155  << " adding Aline " << setiosflags(std::ios::fixed) << std::setprecision(6) << std::setw(12)
156  << tras << " " << traz << " " << trat << " " << rots << " " << rotz << " " << rott << std::endl
157  << " delta_amdb computed from A-line " << Amg::toString(delta_amdb));
158  }
159 
160  const MuonReadoutElement* MuonStation::getMuonReadoutElement(int jobIndex) const {
161  std::map<int, pairRE_AlignTransf>::const_iterator itr = m_REwithAlTransfInStation.find(jobIndex);

◆ setDelta_fromAline_forComp()

void MuonGM::MuonStation::setDelta_fromAline_forComp ( int  jobindex,
double  tras,
double  traz,
double  trat,
double  rots,
double  rotz,
double  rott 
)

this is what happens for a full station : m_transform->setDelta( m_native_to_amdbl->inverse() * m_delta_amdb_frame * m_native_to_amdbl );

Definition at line 188 of file MuonStation.cxx.

188  {
189  ATH_MSG_WARNING( "setDelta_fromAline_forComp: WARNING: component for index " << jobindex
190  << " not found in MuonStation named " << getStationName() << " at zi/fi = " << getEtaIndex() << "/" << getPhiIndex());
191  return;
192  }
193  if (std::abs(tras) + std::abs(traz) + std::abs(trat) + (std::abs(rots) + std::abs(rotz) + std::abs(rott)) * 1000. < 0.01) {
194  ATH_MSG_DEBUG("setDelta_fromAline_forComp: A-line ignored --- too small (translations < 10microns & rotations <10microrad)");
195  return;
196  }
197 
200 
201  Amg::Transform3D parentToChildT = parentToChild->getTransform();
202  Amg::Transform3D delta_amdb = Amg::Translation3D{tras, traz, trat} *
204  // The station to component transform is static and must be computed in terms of "nominal geometry parameters"; fixing here bug
205  const Amg::Vector3D thisREnominalCenter{getMuonReadoutElement(jobindex)->defTransform().translation()};
206  double Rcomp = thisREnominalCenter.perp() - (getMuonReadoutElement(jobindex)->getRsize()) / 2.;
207  double DZcomp = std::abs(thisREnominalCenter.z()) - std::abs((m_amdbl_to_global.translation()).z()) -
208  std::abs((getMuonReadoutElement(jobindex)->getZsize()) / 2.);
209 
210  Amg::Transform3D childToLocAmdbStation = m_native_to_amdbl * parentToChildT;
211  Amg::Transform3D locAmdbStatToLocAmdbComp{Amg::Transform3D::Identity()};
212  // the following line is needed to go for scenario B in last slide of
213  // http://www.fisica.unisalento.it/~spagnolo/allow_listing/TGC_Alines/TGC-ALines_2011_03_01.pdf COMMENT next line to go
214  // for scenario A in last slide of http://www.fisica.unisalento.it/~spagnolo/allow_listing/TGC_Alines/TGC-ALines_2011_03_01.pdf
215  if (getStationType()[0] == 'T') locAmdbStatToLocAmdbComp = Amg::Translation3D{0,-Rcomp, -DZcomp};
216  Amg::Transform3D childToLocAmdbComponent = locAmdbStatToLocAmdbComp * childToLocAmdbStation;
217 
218  ATH_MSG_DEBUG("setDelta_fromAline_forComp: stationName/Jff/Jzz " << getStationType() << " " << getPhiIndex() << " "
219  << getEtaIndex() << " Job " << jobindex << " Origin of component/station AmdbLocalFrame= "
220  <<Amg::toString(m_amdbl_to_global * locAmdbStatToLocAmdbComp.inverse().translation()) << " / "
221  << Amg::toString(m_amdbl_to_global.translation()));
222 
223  parentToChild->setDelta(childToLocAmdbComponent.inverse() * delta_amdb * childToLocAmdbComponent);
224  ATH_MSG_DEBUG("setDelta_fromAline_forComp2:stationName/Jff/Jzz " << getStationType() << " " << getPhiIndex() << " "
225  << getEtaIndex() << " Job " << jobindex << " Origin of component/station AmdbLocalFrame= "
226  << Amg::toString(m_amdbl_to_global * locAmdbStatToLocAmdbComp.inverse().translation()) << " / "
227  << Amg::toString(m_amdbl_to_global.translation()));
228 
229  ATH_MSG_DEBUG("Station " << getStationType() << " at zi/fi " << getEtaIndex() << "/" << getPhiIndex()
230  << " adding Aline " << tras << " " << traz << " " << trat << " " << rots << " " << rotz << " " << rott
231  << " for component with index =" << jobindex << std::endl
232  << " delta_amdb computed from A-line " <<Amg::toString(delta_amdb));
233  }
234 
235  void MuonStation::clearCache() {
236  ATH_MSG_DEBUG("n. of RE in this station is " << m_REwithAlTransfInStation.size());

◆ setDeltaAmdbLRS()

void MuonGM::MuonStation::setDeltaAmdbLRS ( Amg::Transform3D  xf)

set the delta transform in the amdb frame and update the geoModel Delta

Definition at line 131 of file MuonStation.cxx.

137  {
138  // store here the angles of A-line

◆ setEtaPhiIndices()

void MuonGM::MuonStation::setEtaPhiIndices ( int  eta,
int  phi 
)

a la AMDB

Definition at line 45 of file MuonStation.cxx.

47  { m_transform = xf; }
48 

◆ setLevel()

void AthMessaging::setLevel ( MSG::Level  lvl)
inherited

Change the current logging level.

Use this rather than msg().setLevel() for proper operation with MT.

Definition at line 28 of file AthMessaging.cxx.

29 {
30  m_lvl = lvl;
31 }

◆ setMdtAsBuiltParams()

void MuonGM::MuonStation::setMdtAsBuiltParams ( const MdtAsBuiltPar xtomo)

Definition at line 376 of file MuonStation.cxx.

377  { m_physVol = vol; }
378  PVConstLink MuonStation::getPhysVol() const {return m_physVol; }
379  PVLink MuonStation::getPhysVol() { return m_physVol; }

◆ setNativeToAmdbLRS()

void MuonGM::MuonStation::setNativeToAmdbLRS ( Amg::Transform3D  xf)

Definition at line 54 of file MuonStation.cxx.

54  : "<<Amg::toString(m_native_to_amdbl));
55  }
56 
57  void MuonStation::setNominalAmdbLRSToGlobal(Amg::Transform3D xf) {
58  m_amdbl_to_global = std::move(xf);

◆ setNominalAmdbLRSToGlobal()

void MuonGM::MuonStation::setNominalAmdbLRSToGlobal ( Amg::Transform3D  xf)

Definition at line 60 of file MuonStation.cxx.

62  {
63 
64  ATH_MSG_DEBUG("Station " << getStationType() << " at zi/fi " << getEtaIndex() << "/" << getPhiIndex()

◆ setPhysVol()

void MuonGM::MuonStation::setPhysVol ( const PVLink &  vol)

Definition at line 380 of file MuonStation.cxx.

◆ setTransform()

void MuonGM::MuonStation::setTransform ( GeoAlignableTransform *  xf)

Definition at line 50 of file MuonStation.cxx.

◆ setxAmdbCRO()

void MuonGM::MuonStation::setxAmdbCRO ( double  xpos)

Definition at line 52 of file MuonStation.cxx.

54 : "<<Amg::toString(m_native_to_amdbl));

◆ Ssize()

double MuonGM::MuonStation::Ssize ( ) const
inline

Definition at line 174 of file MuonStation.h.

174 { return m_Ssize; }

◆ updateBlineFixedPointInAmdbLRS()

void MuonGM::MuonStation::updateBlineFixedPointInAmdbLRS ( )

Definition at line 86 of file MuonStation.cxx.

91  {
92  for (auto&[jobId, alignPair] :m_REwithAlTransfInStation) {
93  const MuonReadoutElement* muonRE = alignPair.first;
94 
95  if (muonRE->detectorType() !=Trk::DetectorElemType::Mdt) {
96  continue;
97  }
98  const MdtReadoutElement* mdtRE = dynamic_cast<const MdtReadoutElement*>(muonRE);
99  // Correct for tube staggering on barrel side C
100  double shiftInZ = -0.5 * mdtRE->tubePitch();
101  // in addition, correct for 35microm glue width incorrectly applied
102  double multilayerRealSize{0};
103  for (int ilayer = 1; ilayer <= 2; ++ilayer) {
104  double val{0.};
105  bool wellDefined = mdtRE->getWireFirstLocalCoordAlongZ(ilayer, val);
106  if (!wellDefined) {
107  ATH_MSG_WARNING("getUpdatedBlineFixedPointInAmdbLRS: stationName/Jff/Jzz " << getStationType()
108  << " " << getPhiIndex() << " " << getEtaIndex()
109  << " cannot get wire coordinates for second tube layer");
110  val = 0.;
111  }
112  if ((ilayer == 1) || (val > multilayerRealSize)) multilayerRealSize = val;
113  }
114  multilayerRealSize += (mdtRE->getNtubesperlayer() - 1) * mdtRE->tubePitch();
115  multilayerRealSize += mdtRE->outerTubeRadius(); // last tube: no glue width
116  shiftInZ += mdtRE->getZsize() - multilayerRealSize;
117 
119  ATH_MSG_DEBUG("getUpdatedBlineFixedPointInAmdbLRS: stationName/Jff/Jzz " << getStationType() << " "
120  << getPhiIndex() << " " << getEtaIndex() << " shiftInZ = " << shiftInZ << " re-set B-line fixed point "
122  break;
123  }
124  }
126  }
127 
129  m_delta_amdb_frame = std::move(xf);

◆ xAmdbCRO()

double MuonGM::MuonStation::xAmdbCRO ( ) const
inline

Definition at line 180 of file MuonStation.h.

180 { return m_xAmdbCRO; }

◆ Zsize()

double MuonGM::MuonStation::Zsize ( ) const
inline

Definition at line 175 of file MuonStation.h.

175 { return m_Zsize; }

◆ ZsizeMdtStation()

double MuonGM::MuonStation::ZsizeMdtStation ( ) const

Definition at line 327 of file MuonStation.cxx.

329  bool first = true;
330  int nmdt = 0;
331 
332 
333  ATH_MSG_DEBUG("ZsizeMdtStation for " << getStationType() << " at zi/fi " << getEtaIndex() << "/" << getPhiIndex()
334  << " nRE = " << nMuonReadoutElements());
335 
336  for (int j = 1; j < 30; ++j) {
337  const MuonReadoutElement* activeComponent = getMuonReadoutElement(j);
338  if (!activeComponent) continue;
339  if (activeComponent->detectorType() !=Trk::DetectorElemType::Mdt) {
340  continue;
341  }
342  ++nmdt;
343 
344  Zsize += activeComponent->getZsize() / 2.;
345  Zpos = activeComponent->toParentStation() * Amg::Vector3D(0., 0., 0.);
346  if (first) {
347  ZposFirst = Zpos;
348  first = false;
349  } else {
350  if (barrel())
351  Zsize += std::abs(Zpos.z() - ZposFirst.z());
352  else
353  Zsize += std::abs(Zpos.x() - ZposFirst.x());
354  }
355  }
356  if (nmdt == 1) Zsize = 2. * Zsize;
357 
358  return Zsize;
359  }
360 
361  bool MuonStation::barrel() const {
362  return getStationName()[0] == 'B';

Member Data Documentation

◆ ATLAS_THREAD_SAFE

std::atomic_flag m_initialized AthMessaging::ATLAS_THREAD_SAFE = ATOMIC_FLAG_INIT
mutableprivateinherited

Messaging initialized (initMessaging)

Definition at line 141 of file AthMessaging.h.

◆ m_amdbl_to_global

Amg::Transform3D MuonGM::MuonStation::m_amdbl_to_global {Amg::Transform3D::Identity()}
private

Definition at line 147 of file MuonStation.h.

◆ m_BlineFixedPointInAmdbLRS

Amg::Vector3D MuonGM::MuonStation::m_BlineFixedPointInAmdbLRS {Amg::Vector3D::Zero()}
private

Definition at line 153 of file MuonStation.h.

◆ m_delta_amdb_frame

Amg::Transform3D MuonGM::MuonStation::m_delta_amdb_frame {Amg::Transform3D::Identity()}
private

Definition at line 145 of file MuonStation.h.

◆ m_descratzneg

bool MuonGM::MuonStation::m_descratzneg {false}
private

Definition at line 139 of file MuonStation.h.

◆ m_firstRequestBlineFixedP

bool MuonGM::MuonStation::m_firstRequestBlineFixedP {true}
private

Definition at line 129 of file MuonStation.h.

◆ m_hasALines

bool MuonGM::MuonStation::m_hasALines {false}
private

Definition at line 151 of file MuonStation.h.

◆ m_hasBLines

bool MuonGM::MuonStation::m_hasBLines {false}
private

Definition at line 152 of file MuonStation.h.

◆ m_imsg

std::atomic<IMessageSvc*> AthMessaging::m_imsg { nullptr }
mutableprivateinherited

MessageSvc pointer.

Definition at line 135 of file AthMessaging.h.

◆ m_key

std::string MuonGM::MuonStation::m_key {}
private

Definition at line 142 of file MuonStation.h.

◆ m_LongRsize

double MuonGM::MuonStation::m_LongRsize {0.}
private

Definition at line 136 of file MuonStation.h.

◆ m_LongSsize

double MuonGM::MuonStation::m_LongSsize {0.}
private

Definition at line 135 of file MuonStation.h.

◆ m_LongZsize

double MuonGM::MuonStation::m_LongZsize {0.}
private

Definition at line 137 of file MuonStation.h.

◆ m_lvl

std::atomic<MSG::Level> AthMessaging::m_lvl { MSG::NIL }
mutableprivateinherited

Current logging level.

Definition at line 138 of file AthMessaging.h.

◆ m_msg_tls

boost::thread_specific_ptr<MsgStream> AthMessaging::m_msg_tls
mutableprivateinherited

MsgStream instance (a std::cout like with print-out levels)

Definition at line 132 of file AthMessaging.h.

◆ m_native_to_amdbl

Amg::Transform3D MuonGM::MuonStation::m_native_to_amdbl {Amg::Transform3D::Identity()}
private

Definition at line 146 of file MuonStation.h.

◆ m_nm

std::string AthMessaging::m_nm
privateinherited

Message source name.

Definition at line 129 of file AthMessaging.h.

◆ m_physVol

PVLink MuonGM::MuonStation::m_physVol {nullptr}
private

Link the full physical volume associated with the station.

Definition at line 159 of file MuonStation.h.

◆ m_REwithAlTransfInStation

std::map<int, pairRE_AlignTransf> MuonGM::MuonStation::m_REwithAlTransfInStation {}
private

keep track of the REs in this station

Definition at line 157 of file MuonStation.h.

◆ m_rots

double MuonGM::MuonStation::m_rots {0.}
private

Definition at line 148 of file MuonStation.h.

◆ m_rott

double MuonGM::MuonStation::m_rott {0.}
private

Definition at line 150 of file MuonStation.h.

◆ m_rotz

double MuonGM::MuonStation::m_rotz {0.}
private

Definition at line 149 of file MuonStation.h.

◆ m_Rsize

double MuonGM::MuonStation::m_Rsize {0.}
private

Definition at line 133 of file MuonStation.h.

◆ m_Ssize

double MuonGM::MuonStation::m_Ssize {0.}
private

Definition at line 132 of file MuonStation.h.

◆ m_statEtaIndex

int MuonGM::MuonStation::m_statEtaIndex {0}
private

Definition at line 141 of file MuonStation.h.

◆ m_statname

std::string MuonGM::MuonStation::m_statname {}
private

Definition at line 131 of file MuonStation.h.

◆ m_statPhiIndex

int MuonGM::MuonStation::m_statPhiIndex {0}
private

Definition at line 140 of file MuonStation.h.

◆ m_transform

GeoAlignableTransform* MuonGM::MuonStation::m_transform {nullptr}
private

Definition at line 143 of file MuonStation.h.

◆ m_xAmdbCRO

double MuonGM::MuonStation::m_xAmdbCRO {0.}
private

Definition at line 138 of file MuonStation.h.

◆ m_XTomoData

const MdtAsBuiltPar* MuonGM::MuonStation::m_XTomoData {nullptr}
private

Definition at line 154 of file MuonStation.h.

◆ m_Zsize

double MuonGM::MuonStation::m_Zsize {0.}
private

Definition at line 134 of file MuonStation.h.


The documentation for this class was generated from the following files:
AthMessaging::m_lvl
std::atomic< MSG::Level > m_lvl
Current logging level.
Definition: AthMessaging.h:138
MuonGM::MuonStation::m_XTomoData
const MdtAsBuiltPar * m_XTomoData
Definition: MuonStation.h:154
MuonGM::MuonStation::m_descratzneg
bool m_descratzneg
Definition: MuonStation.h:139
MuonGM::MuonStation::getStationType
std::string getStationType() const
like BMS, T1F, CSL
Definition: MuonStation.h:164
checkFileSG.line
line
Definition: checkFileSG.py:75
MuonGM::MuonStation::m_native_to_amdbl
Amg::Transform3D m_native_to_amdbl
Definition: MuonStation.h:146
MuonGM::MuonStation::m_REwithAlTransfInStation
std::map< int, pairRE_AlignTransf > m_REwithAlTransfInStation
keep track of the REs in this station
Definition: MuonStation.h:157
MuonGM::MuonStation::fillCache
void fillCache()
Definition: MuonStation.cxx:253
MuonGM::MuonStation::getPhysVol
PVConstLink getPhysVol() const
Definition: MuonStation.cxx:381
dumpTgcDigiDeadChambers.stationName
dictionary stationName
Definition: dumpTgcDigiDeadChambers.py:30
MuonGM::MuonStation::m_hasBLines
bool m_hasBLines
Definition: MuonStation.h:152
MuonGM::MuonStation::m_hasALines
bool m_hasALines
Definition: MuonStation.h:151
MuonGM::MuonStation::m_LongRsize
double m_LongRsize
Definition: MuonStation.h:136
MuonGM::MuonReadoutElement::defTransform
const Amg::Transform3D & defTransform() const
Definition: MuonDetDescr/MuonReadoutGeometry/MuonReadoutGeometry/MuonReadoutElement.h:212
Amg::y
@ y
Definition: GeoPrimitives.h:35
MuonGM::MuonStation::m_physVol
PVLink m_physVol
Link the full physical volume associated with the station.
Definition: MuonStation.h:159
MuonGM::MuonStation::~MuonStation
~MuonStation()
MuonGM::MuonStation::m_delta_amdb_frame
Amg::Transform3D m_delta_amdb_frame
Definition: MuonStation.h:145
MuonGM::MuonStation::getStationName
const std::string & getStationName() const
like BMS5, T1F1, CSL1
Definition: MuonStation.h:165
MuonGM::MuonStation::LongZsize
double LongZsize() const
Definition: MuonStation.h:178
AthMessaging::m_imsg
std::atomic< IMessageSvc * > m_imsg
MessageSvc pointer.
Definition: AthMessaging.h:135
MuonGM::MuonStation::m_BlineFixedPointInAmdbLRS
Amg::Vector3D m_BlineFixedPointInAmdbLRS
Definition: MuonStation.h:153
python.SystemOfUnits.ms
int ms
Definition: SystemOfUnits.py:132
Athena::getMessageSvc
IMessageSvc * getMessageSvc(bool quiet=false)
Definition: getMessageSvc.cxx:20
MuonGM::MuonStation::m_rots
double m_rots
Definition: MuonStation.h:148
Amg::getRotateZ3D
Amg::Transform3D getRotateZ3D(double angle)
get a rotation transformation around Z-axis
Definition: GeoPrimitivesHelpers.h:270
MuonGM::MuonStation::getMuonReadoutElement
const MuonReadoutElement * getMuonReadoutElement(int jobIndex) const
Definition: MuonStation.cxx:163
MuonGM::MuonStation::m_statPhiIndex
int m_statPhiIndex
Definition: MuonStation.h:140
MuonGM::MuonStation::Ssize
double Ssize() const
Definition: MuonStation.h:174
MuonGM::MuonStation::m_amdbl_to_global
Amg::Transform3D m_amdbl_to_global
Definition: MuonStation.h:147
MuonGM::MuonStation::getPhiIndex
int getPhiIndex() const
a la AMDB
Definition: MuonStation.h:162
MuonGM::MuonStation::Zsize
double Zsize() const
Definition: MuonStation.h:175
Amg::getRotateX3D
Amg::Transform3D getRotateX3D(double angle)
get a rotation transformation around X-axis
Definition: GeoPrimitivesHelpers.h:252
MuonGM::MuonStation::m_xAmdbCRO
double m_xAmdbCRO
Definition: MuonStation.h:138
Amg::toString
std::string toString(const Translation3D &translation, int precision=4)
GeoPrimitvesToStringConverter.
Definition: GeoPrimitivesToStringConverter.h:40
TrigConf::MSGTC::Level
Level
Definition: Trigger/TrigConfiguration/TrigConfBase/TrigConfBase/MsgStream.h:21
MuonGM::MuonStation::LongRsize
double LongRsize() const
Definition: MuonStation.h:176
MuonGM::MuonStation::Rsize
double Rsize() const
Definition: MuonStation.h:173
lumiFormat.i
int i
Definition: lumiFormat.py:85
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
MuonGM::MuonStation::m_key
std::string m_key
Definition: MuonStation.h:142
Amg::Transform3D
Eigen::Affine3d Transform3D
Definition: GeoPrimitives.h:46
AthMessaging
Class to provide easy MsgStream access and capabilities.
Definition: AthMessaging.h:55
MuonGM::MuonStation::refreshCache
void refreshCache()
Definition: MuonStation.cxx:266
MuonGM::MuonStation::barrel
bool barrel() const
Definition: MuonStation.cxx:364
beamspotman.jobId
int jobId
Definition: beamspotman.py:1148
AthMessaging::msg
MsgStream & msg() const
The standard message stream.
Definition: AthMessaging.h:164
python.CaloBCIDAvgAlgConfig.only
list only
Definition: CaloBCIDAvgAlgConfig.py:32
MuonGM::MuonStation::m_firstRequestBlineFixedP
bool m_firstRequestBlineFixedP
Definition: MuonStation.h:129
MuonGM::MuonStation::m_transform
GeoAlignableTransform * m_transform
Definition: MuonStation.h:143
MuonGM::MuonStation::nMuonReadoutElements
int nMuonReadoutElements() const
Definition: MuonStation.h:188
MuonGM::MuonStation::m_LongSsize
double m_LongSsize
Definition: MuonStation.h:135
MuonGM::MuonStation::m_LongZsize
double m_LongZsize
Definition: MuonStation.h:137
MuonGM::MuonStation::m_Ssize
double m_Ssize
Definition: MuonStation.h:132
dqt_zlumi_alleff_HIST.B
B
Definition: dqt_zlumi_alleff_HIST.py:110
Amg::getRotateY3D
Amg::Transform3D getRotateY3D(double angle)
get a rotation transformation around Y-axis
Definition: GeoPrimitivesHelpers.h:261
Amg::Vector3D
Eigen::Matrix< double, 3, 1 > Vector3D
Definition: GeoPrimitives.h:47
MuonGM::MuonStation::m_statname
std::string m_statname
Definition: MuonStation.h:131
MuonGM::MuonStation::m_rotz
double m_rotz
Definition: MuonStation.h:149
MdtAsBuiltPar
Container classifier the MDT as-built parameters See parameter description in http://atlas-muon-align...
Definition: MdtAsBuiltPar.h:18
MuonGM::MuonStation::clearCache
void clearCache()
Definition: MuonStation.cxx:238
MuonGM::MuonReadoutElement::getRsize
double getRsize() const
Definition: MuonDetDescr/MuonReadoutGeometry/MuonReadoutGeometry/MuonReadoutElement.h:197
ATH_MSG_WARNING
#define ATH_MSG_WARNING(x)
Definition: AthMsgStreamMacros.h:32
MuonGM::MuonStation::m_Rsize
double m_Rsize
Definition: MuonStation.h:133
Pythia8_RapidityOrderMPI.val
val
Definition: Pythia8_RapidityOrderMPI.py:14
MuonGM::MuonStation::getEtaIndex
int getEtaIndex() const
a la AMDB
Definition: MuonStation.h:163
AthMessaging::m_nm
std::string m_nm
Message source name.
Definition: AthMessaging.h:129
DeMoScan.first
bool first
Definition: DeMoScan.py:536
re
const boost::regex re(r_e)
Amg::Translation3D
Eigen::Translation< double, 3 > Translation3D
Definition: GeoPrimitives.h:44
MuonGM::MuonStation::getMdtAsBuiltParams
const MdtAsBuiltPar * getMdtAsBuiltParams() const
Definition: MuonStation.cxx:369
checkFileSG.fi
fi
Definition: checkFileSG.py:65
MuonGM::MuonStation::m_statEtaIndex
int m_statEtaIndex
Definition: MuonStation.h:141
AthMessaging::initMessaging
void initMessaging() const
Initialize our message level and MessageSvc.
Definition: AthMessaging.cxx:39
AthMessaging::m_msg_tls
boost::thread_specific_ptr< MsgStream > m_msg_tls
MsgStream instance (a std::cout like with print-out levels)
Definition: AthMessaging.h:132
MuonGM::MuonStation::setDeltaAmdbLRS
void setDeltaAmdbLRS(Amg::Transform3D xf)
set the delta transform in the amdb frame and update the geoModel Delta
Definition: MuonStation.cxx:131
MuonGM::MuonStation::ZsizeMdtStation
double ZsizeMdtStation() const
Definition: MuonStation.cxx:327
MuonGM::MuonStation::LongSsize
double LongSsize() const
Definition: MuonStation.h:177
Trk::DetectorElemType::Mdt
@ Mdt
MuonGM::MuonStation::m_Zsize
double m_Zsize
Definition: MuonStation.h:134
generate::Zero
void Zero(TH1D *hin)
Definition: generate.cxx:32
MuonGM::MuonStation::m_rott
double m_rott
Definition: MuonStation.h:150