|
ATLAS Offline Software
|
#include <ReadoutGeomCnvAlg.h>
|
| ReadoutGeomCnvAlg (const std::string &name, ISvcLocator *pSvcLocator) |
|
| ~ReadoutGeomCnvAlg ()=default |
|
StatusCode | execute (const EventContext &ctx) const override |
|
StatusCode | initialize () override |
|
bool | isReEntrant () const override |
|
virtual StatusCode | sysInitialize () override |
| Override sysInitialize. More...
|
|
virtual bool | isClonable () const override |
| Specify if the algorithm is clonable. More...
|
|
virtual unsigned int | cardinality () const override |
| Cardinality (Maximum number of clones that can exist) special value 0 means that algorithm is reentrant. More...
|
|
virtual StatusCode | sysExecute (const EventContext &ctx) override |
| Execute an algorithm. More...
|
|
virtual const DataObjIDColl & | extraOutputDeps () const override |
| Return the list of extra output dependencies. More...
|
|
virtual bool | filterPassed (const EventContext &ctx) const |
|
virtual void | setFilterPassed (bool state, const EventContext &ctx) const |
|
ServiceHandle< StoreGateSvc > & | evtStore () |
| The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc . More...
|
|
const ServiceHandle< StoreGateSvc > & | evtStore () const |
| The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc . More...
|
|
const ServiceHandle< StoreGateSvc > & | detStore () const |
| The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc . More...
|
|
virtual StatusCode | sysStart () override |
| Handle START transition. More...
|
|
virtual std::vector< Gaudi::DataHandle * > | inputHandles () const override |
| Return this algorithm's input handles. More...
|
|
virtual std::vector< Gaudi::DataHandle * > | outputHandles () const override |
| Return this algorithm's output handles. More...
|
|
Gaudi::Details::PropertyBase & | declareProperty (Gaudi::Property< T > &t) |
|
Gaudi::Details::PropertyBase * | declareProperty (const std::string &name, SG::VarHandleKey &hndl, const std::string &doc, const SG::VarHandleKeyType &) |
| Declare a new Gaudi property. More...
|
|
Gaudi::Details::PropertyBase * | declareProperty (const std::string &name, SG::VarHandleBase &hndl, const std::string &doc, const SG::VarHandleType &) |
| Declare a new Gaudi property. More...
|
|
Gaudi::Details::PropertyBase * | declareProperty (const std::string &name, SG::VarHandleKeyArray &hndArr, const std::string &doc, const SG::VarHandleKeyArrayType &) |
|
Gaudi::Details::PropertyBase * | declareProperty (const std::string &name, T &property, const std::string &doc, const SG::NotHandleType &) |
| Declare a new Gaudi property. More...
|
|
Gaudi::Details::PropertyBase * | declareProperty (const std::string &name, T &property, const std::string &doc="none") |
| Declare a new Gaudi property. More...
|
|
void | updateVHKA (Gaudi::Details::PropertyBase &) |
|
MsgStream & | msg () const |
|
MsgStream & | msg (const MSG::Level lvl) const |
|
bool | msgLvl (const MSG::Level lvl) const |
|
|
StatusCode | buildStation (const ActsGeometryContext &gctx, const Identifier &stationId, ConstructionCache &cacheObj) const |
| builds a station object from readout element. More...
|
|
StatusCode | cloneReadoutVolume (const ActsGeometryContext &gctx, const Identifier &stationId, ConstructionCache &cacheObj, GeoIntrusivePtr< GeoVFullPhysVol > &clonedPhysVol, MuonGM::MuonStation *&station) const |
| Clones the fullPhysical volume of the readoutElement and embeds it into the associated station. More...
|
|
GeoIntrusivePtr< GeoVFullPhysVol > | cloneNswWedge (const ActsGeometryContext &gctx, const MuonGMR4::MuonReadoutElement *nswRE, ConstructionCache &cacheObj) const |
| Clones the fullPhysicalVolume of the
More...
|
|
StatusCode | buildMdt (const ActsGeometryContext &gctx, ConstructionCache &cacheObj) const |
|
StatusCode | buildRpc (const ActsGeometryContext &gctx, ConstructionCache &cacheObj) const |
|
StatusCode | buildSTGC (const ActsGeometryContext &gctx, ConstructionCache &cacheObj) const |
|
StatusCode | buildMM (const ActsGeometryContext &gctx, ConstructionCache &cacheObj) const |
|
StatusCode | buildTgc (const ActsGeometryContext &gctx, ConstructionCache &cacheObj) const |
|
StatusCode | dumpAndCompare (const ActsGeometryContext &gctx, const MuonGMR4::RpcReadoutElement &refEle, const MuonGM::RpcReadoutElement &testEle) const |
|
StatusCode | dumpAndCompare (const ActsGeometryContext &gctx, const MuonGMR4::MdtReadoutElement &refEle, const MuonGM::MdtReadoutElement &testEle) const |
|
StatusCode | dumpAndCompare (const ActsGeometryContext &gctx, const MuonGMR4::MmReadoutElement &refEle, const MuonGM::MMReadoutElement &testEle) const |
|
StatusCode | dumpAndCompare (const ActsGeometryContext &gctx, const MuonGMR4::TgcReadoutElement &refEle, const MuonGM::TgcReadoutElement &testEle) const |
|
StatusCode | dumpAndCompare (const ActsGeometryContext &gctx, const MuonGMR4::sTgcReadoutElement &refEle, const MuonGM::sTgcReadoutElement &testEle) const |
|
StatusCode | checkIdCompability (const MuonGMR4::MuonReadoutElement &refEle, const MuonGM::MuonReadoutElement &testEle) const |
|
Gaudi::Details::PropertyBase & | declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &) |
| specialization for handling Gaudi::Property<SG::VarHandleKey> More...
|
|
Gaudi::Details::PropertyBase & | declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleKeyArrayType &) |
| specialization for handling Gaudi::Property<SG::VarHandleKeyArray> More...
|
|
Gaudi::Details::PropertyBase & | declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleType &) |
| specialization for handling Gaudi::Property<SG::VarHandleBase> More...
|
|
Gaudi::Details::PropertyBase & | declareGaudiProperty (Gaudi::Property< T > &t, const SG::NotHandleType &) |
| specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray> More...
|
|
|
ServiceHandle< Muon::IMuonIdHelperSvc > | m_idHelperSvc {this, "MuonIdHelperSvc", "Muon::MuonIdHelperSvc/MuonIdHelperSvc"} |
|
SG::WriteCondHandleKey< MuonGM::MuonDetectorManager > | m_writeKey {this, "WriteKey", "MuonDetectorManager"} |
|
SG::ReadCondHandleKeyArray< ActsTrk::DetectorAlignStore > | m_alignStoreKeys {this, "AlignmentKeys", {}, "Alignment key"} |
|
Gaudi::Property< bool > | m_checkGeo {this, "checkGeo", false, "Checks the positions of the sensors"} |
|
const MuonGMR4::MuonDetectorManager * | m_detMgr {nullptr} |
|
DataObjIDColl | m_extendedExtraObjects |
| Extra output dependency collection, extended by AthAlgorithmDHUpdate to add symlinks. More...
|
|
StoreGateSvc_t | m_evtStore |
| Pointer to StoreGate (event store by default) More...
|
|
StoreGateSvc_t | m_detStore |
| Pointer to StoreGate (detector store by default) More...
|
|
std::vector< SG::VarHandleKeyArray * > | m_vhka |
|
bool | m_varHandleArraysDeclared |
|
Definition at line 32 of file ReadoutGeomCnvAlg.h.
◆ StoreGateSvc_t
◆ ReadoutGeomCnvAlg()
MuonGMR4::ReadoutGeomCnvAlg::ReadoutGeomCnvAlg |
( |
const std::string & |
name, |
|
|
ISvcLocator * |
pSvcLocator |
|
) |
| |
◆ ~ReadoutGeomCnvAlg()
MuonGMR4::ReadoutGeomCnvAlg::~ReadoutGeomCnvAlg |
( |
| ) |
|
|
default |
◆ buildMdt()
Access the B-Line and As-built parameters
Build the mother station
Define the dimensions
1 cm is added as safety margin to the Mdt multilayer envelope
Need to check how to obtain this parameter from the new geometry newElement->m_cutoutShift;
Determine the tube length's
Define the tube staggering
Add the readout element to the manager
Definition at line 635 of file ReadoutGeomCnvAlg.cxx.
639 static_cast<const MdtAlignmentStore*
>(alignItr->internalAlignment.get()) :
nullptr;
641 const std::vector<const MuonGMR4::MdtReadoutElement*> mdtReadOuts{
m_detMgr->getAllMdtReadoutElements()};
642 ATH_MSG_INFO(
"Copy "<<mdtReadOuts.size()<<
" Mdt readout elements to the legacy system");
647 GeoIntrusivePtr<GeoVFullPhysVol> physVol{};
652 auto newElement = std::make_unique<MuonGM::MdtReadoutElement>(physVol,
654 cacheObj.detMgr.get());
655 newElement->setIdentifier(reId);
656 newElement->setMultilayer(copyMe->multilayer());
657 newElement->setNMdtInStation(
m_idHelperSvc->mdtIdHelper().multilayerMax(reId));
659 newElement->setParentMuonStation(station);
661 newElement->setLongRsize(2*
pars.halfY);
664 newElement->setLongZsize(2*
pars.halfHeight);
665 newElement->setRsize(2*
pars.halfY);
667 newElement->setZsize(2*
pars.halfHeight);
669 newElement->m_nlayers = copyMe->numLayers();
670 newElement->m_ntubesperlayer = copyMe->numTubesInLay();
671 newElement->m_deadlength =
pars.deadLength;
672 newElement->m_endpluglength =
pars.endPlugLength;
673 newElement->m_innerRadius =
pars.tubeInnerRad;
674 newElement->m_tubeWallThickness =
pars.tubeWall;
675 newElement->m_tubepitch =
pars.tubePitch;
681 unsigned int step{1};
682 double lastLength{2.*tubeLay.uncutHalfLength(1)};
683 for (
unsigned tube = 0;
tube < copyMe->numTubesInLay(); ++
tube) {
684 const double currLength = 2.*tubeLay.uncutHalfLength(
tube);
686 if (std::abs(lastLength - currLength) > std::numeric_limits<float>::epsilon() ||
687 tube == copyMe->numTubesInLay() -1) {
688 newElement->m_tubelength[
step-1] = lastLength;
689 newElement->m_tubelength[
step] = currLength;
691 newElement->m_ntubesinastep =
tube;
693 lastLength = currLength;
697 newElement->m_nsteps =
step;
700 double xOffSet{
pars.halfY}, yOffSet{
pars.halfHeight};
701 if (newElement->barrel())
std::swap(xOffSet, yOffSet);
702 for (
unsigned lay = 1; lay <= copyMe->numLayers(); ++lay) {
704 const Amg::Vector3D locTube = copyMe->localTubePos(tubeHash);
705 newElement->m_firstwire_x[lay-1] = locTube.z() + xOffSet;
706 newElement->m_firstwire_y[lay-1] = locTube.x() + yOffSet;
711 if (!station->hasMdtAsBuiltParams()){
712 station->setMdtAsBuiltParams(distort.
asBuilt);
714 if (!station->hasBLines()){
715 station->setBline(distort.
bLine);
717 const Amg::Vector3D refPoint = copyMe->bLineReferencePoint();
718 station->setBlineFixedPointInAmdbLRS(refPoint.x(), refPoint.y(), refPoint.z());
720 newElement->geoInitDone();
721 newElement->setBLinePar(distort.
bLine);
722 newElement->fillCache();
725 cacheObj.detMgr->addMdtReadoutElement(std::move(newElement));
727 return StatusCode::SUCCESS;
◆ buildMM()
Loop over the gas gaps & efine the
Definition at line 479 of file ReadoutGeomCnvAlg.cxx.
482 const auto alignStore = alignItr ?
483 static_cast<const MmAlignmentStore*
>(alignItr->internalAlignment.get()) :
nullptr;
485 const std::vector<const MuonGMR4::MmReadoutElement*> mmReadouts{
m_detMgr->getAllMmReadoutElements()};
486 ATH_MSG_INFO(
"Copy "<<mmReadouts.size()<<
" Mm readout elements to the legacy system");
490 GeoIntrusivePtr<GeoVFullPhysVol> physVol{
cloneNswWedge(gctx, copyMe, cacheObj)};
491 auto newRE = std::make_unique<MuonGM::MMReadoutElement>(physVol,
493 copyMe->stationEta(),
494 copyMe->stationPhi(),
495 copyMe->multilayer(), cacheObj.detMgr.get(),
496 alignStore ? alignStore->passivation :
nullptr);
502 newRE->m_Xlg[
gasGap] = stripLayer.toOrigin() *
509 designFrom.longHalfHeight(),
510 designFrom.halfWidth(),
511 designFrom.stereoAngle());
514 designTo.inputPitch = designFrom.stripPitch();
515 designTo.inputWidth = designTo.inputPitch *
std::cos(designTo.stereoAngle());
516 designTo.nMissedBottomEta = designTo.nMissedBottomStereo = designFrom.firstStripNumber() - 1;
517 designTo.totalStrips = designFrom.numStrips();
518 designTo.nch = designFrom.numStrips();
520 designTo.setFirstPos(designFrom.firstStripPos().x() + 0.5*designTo.inputPitch);
524 if (alignStore && alignStore->getBLine(reId)) {
525 newRE->setBLinePar(*alignStore->getBLine(reId));
528 cacheObj.detMgr->addMMReadoutElement(std::move(newRE));
530 return StatusCode::SUCCESS;
◆ buildRpc()
Define the dimensions
Hack to assign the proper strip positions for REs having doubletPhi =2 in their Identifier
Resignment in face of the rpc readout geometry. Overwrite all the parameters
Definition at line 280 of file ReadoutGeomCnvAlg.cxx.
282 const std::vector<const MuonGMR4::RpcReadoutElement*> readoutEles =
m_detMgr->getAllRpcReadoutElements();
283 ATH_MSG_INFO(
"Copy "<<readoutEles.size()<<
" Rpc readout elements to the legacy system");
288 GeoIntrusivePtr<GeoVFullPhysVol> physVol{};
291 auto newElement = std::make_unique<MuonGM::RpcReadoutElement>(physVol,
293 1, 1,
false, cacheObj.detMgr.get());
294 const bool aSide{copyMe->stationEta() > 0};
295 newElement->setDoubletPhi(copyMe->doubletPhi());
296 newElement->setDoubletR(copyMe->doubletR());
297 newElement->setDoubletZ(copyMe->doubletZ());
298 newElement->setIdentifier(reId);
299 newElement->setParentMuonStation(station);
302 newElement->setLongRsize(
pars.halfLength);
303 newElement->setLongSsize(
pars.halfWidth);
304 newElement->setLongZsize(
pars.halfThickness);
305 newElement->setRsize(
pars.halfLength);
306 newElement->setSsize(
pars.halfWidth);
307 newElement->setZsize(
pars.halfThickness);
309 newElement->m_nlayers = copyMe->nGasGaps();
310 newElement->m_phistripwidth = copyMe->stripPhiWidth();
311 newElement->m_etastripwidth = copyMe->stripEtaWidth();
312 newElement->m_phistrippitch = copyMe->stripPhiPitch();
313 newElement->m_etastrippitch = (aSide > 0 ? 1. : -1.) *copyMe->stripEtaPitch();
314 newElement->m_phistriplength = copyMe->stripPhiLength();
315 newElement->m_etastriplength = copyMe->stripEtaLength();
317 newElement->m_nphistripsperpanel = copyMe->nPhiStrips();
318 newElement->m_netastripsperpanel = copyMe->nEtaStrips();
319 newElement->m_nphistrippanels = copyMe->nPhiPanels();
320 newElement->m_hasDEDontop =
true;
321 newElement->m_descratzneg =
false;
323 std::vector<Identifier> gapIds{};
325 for (
int doubPhi = copyMe->doubletPhiMax(); doubPhi >= copyMe->doubletPhi(); --doubPhi) {
326 for (
bool measPhi : {
false,
true}) {
327 if (measPhi && copyMe->nPhiStrips()==0)
continue;
329 const Identifier gapId = idHelper.channelID(copyMe->identify(),
334 gapIds.push_back(gapId);
335 const Amg::Vector3D locStripPos = copyMe->globalToLocalTrans(gctx) * copyMe->stripPosition(gctx, gapId);
337 newElement->m_gasGap_xPos[
gasGap -1] = locStripPos.x();
340 const int dbPIdx = copyMe->doubletPhi() == 2 ? 1 : doubPhi;
342 newElement->m_first_phistrip_s[dbPIdx -1] = locStripPos.y();
343 newElement->m_phistrip_z = locStripPos.z();
345 newElement->m_first_etastrip_z = locStripPos.z();
346 newElement->m_etastrip_s[dbPIdx-1] = locStripPos.y();
351 newElement->fillCache();
354 const int surfaceHash = newElement->surfaceHash(gapId);
355 const int layerHash = newElement->layerHash(gapId);
357 newElement->m_surfaceData->m_layerTransforms[surfaceHash] = refTrf;
358 newElement->m_surfaceData->m_layerCenters[layerHash] = refTrf.translation();
359 newElement->m_surfaceData->m_layerNormals[layerHash] = refTrf.linear() * Amg::Vector3D::UnitZ();
362 cacheObj.detMgr->addRpcReadoutElement(std::move(newElement));
364 return StatusCode::SUCCESS;
◆ buildStation()
builds a station object from readout element.
The parent PhysVol of the readoutElement is interpreted as embedding station volume and all children which are not fullPhysical volumes are attached to the copied clone.
Fetch the readout element to get its parent volume
Retrieve the full phyiscal volume
Copy the full physical volume of the muon station
Make sure to copy all the children from the original tree that're not FullPhysVols -> represent They represent the passive material inside the station and are needed for the TrackinGeometry building
To create the muon station, we need to extract the dimensions --> Recieve the edge points from the shapes
Transformation to reach from the alignable point to the Muon station
Skip the full physical volumes as they represent the readout elements
Fetch the transform of the detector element which is AlignableNode x Station x [relative pos in station]
S / R / Z size
S / R / Z size (long)
Add the physical volume to the world
Definition at line 146 of file ReadoutGeomCnvAlg.cxx.
149 const std::string stName{
m_idHelperSvc->stationNameString(stationId)};
154 ATH_MSG_DEBUG(
"Station "<<stName<<
" "<<stEta<<
" "<<stPhi<<
" already exists.");
155 return StatusCode::SUCCESS;
161 const GeoVFullPhysVol* readOutVol = copyMe->getMaterialGeom();
162 PVConstLink parentVolume = readOutVol->getParent();
163 cacheObj.translatedStations.insert(parentVolume);
165 PVLink parentPhysVol{make_intrusive<GeoFullPhysVol>(parentVolume->getLogVol())};
169 const std::vector<GeoChildNodeWithTrf>
children = getChildrenWithRef(parentVolume,
false);
170 double minX{1.e9}, maxX{-1.e9}, minY1{1.e9}, maxY1{-1.e9}, minY2{1.e9}, maxY2{-1.e9}, minZ{1.e9}, maxZ{-1.e9};
171 for (
const GeoChildNodeWithTrf& child :
children) {
172 std::vector<Amg::Vector3D> edges = getPolyShapeEdges(child.volume->getLogVol()->getShape(),
173 readOutVol->getX().inverse() * child.transform);
190 const double shortS = (maxY1 - minY1);
191 const double longS = (maxY2 - minY2);
192 const double lengthR = (maxX - minX);
193 const double lengthZ = (maxZ - minZ);
199 const Amg::Transform3D stationTransform = alignTrf->getDefTransform().inverse()*parentVolume->getX();
201 for (
const GeoChildNodeWithTrf& child :
children) {
203 const GeoVPhysVol &childVolRef = *child.volume;
204 if (
typeid(childVolRef) ==
typeid(GeoFullPhysVol)) {
208 PVLink childVol = const_pointer_cast<GeoVPhysVol>(child.volume);
209 parentPhysVol->add(cacheObj.newIdTag());
210 parentPhysVol->add(cacheObj.makeTransform(stationTransform*child.transform));
211 parentPhysVol->add(cloneVolume(childVol));
215 (stationTransform * readOutVol->getX()).
inverse();
217 ATH_MSG_VERBOSE(
"stName "<<stName<<
","<<stEta<<
","<<stPhi<<
" -- shortS: "<<shortS<<
", longS: "<<longS
218 <<
", lengthR: "<<lengthR<<
", lengthZ "<<lengthZ
220 <<std::endl<<
"Station transform: "<<
GeoTrf::toString(stationTransform,
true)
221 <<std::endl<<
"Readout transform: "<<
GeoTrf::toString(readOutVol->getX(),
true));
222 auto newStation = std::make_unique<MuonGM::MuonStation>(stName,
223 shortS, lengthR, lengthZ,
224 longS, lengthR, lengthZ,
225 stEta, stPhi,
false);
226 newStation->setPhysVol(parentPhysVol);
228 cacheObj.world->add(cacheObj.newIdTag());
229 GeoIntrusivePtr<GeoAlignableTransform>
trf = make_intrusive<GeoAlignableTransform>(alignedTransform);
230 newStation->setTransform(
trf);
231 cacheObj.detMgr->addMuonStation(std::move(newStation));
233 cacheObj.world->add(
trf);
234 cacheObj.world->add(parentPhysVol);
236 return StatusCode::SUCCESS;
◆ buildSTGC()
Initialize the eta design
Initialize the phi design
Definition at line 533 of file ReadoutGeomCnvAlg.cxx.
535 auto alignStore = alignItr ?
static_cast<const sTgcAlignmentStore*
>(alignItr->internalAlignment.get()) :
nullptr;
537 const std::vector<const MuonGMR4::sTgcReadoutElement*> sTgcReadOuts{
m_detMgr->getAllsTgcReadoutElements()};
538 ATH_MSG_INFO(
"Copy "<<sTgcReadOuts.size()<<
" sTgc readout elements to the legacy system");
542 GeoIntrusivePtr<GeoVFullPhysVol> physVol{
cloneNswWedge(gctx, copyMe, cacheObj)};
544 auto newRE = std::make_unique<MuonGM::sTgcReadoutElement>(physVol,
546 copyMe->stationEta(),
547 copyMe->stationPhi(),
548 copyMe->multilayer(),
549 cacheObj.detMgr.get());
551 if (alignStore && alignStore->getBLine(reId)) {
552 newRE->setBLinePar(*alignStore->getBLine(reId));
559 copyMe->center(gctx, layerHash));
563 ChannelDesign& etaDesign{newRE->m_etaDesign[
layer-1]};
564 etaDesign.type = ChannelDesign::ChannelType::etaStrip;
566 if (copyEtaDesign.yCutout()) {
567 etaDesign.defineDiamond(copyEtaDesign.shortHalfHeight(),
568 copyEtaDesign.longHalfHeight(),
569 copyEtaDesign.halfWidth(),
570 copyEtaDesign.yCutout());
572 etaDesign.defineTrapezoid(copyEtaDesign.shortHalfHeight(),
573 copyEtaDesign.longHalfHeight(),
574 copyEtaDesign.halfWidth());
576 etaDesign.inputPitch = copyEtaDesign.stripPitch();
577 etaDesign.inputWidth = copyEtaDesign.stripWidth();
578 etaDesign.nch = copyEtaDesign.numStrips();
579 etaDesign.setFirstPos(copyEtaDesign.firstStripPos().x());
584 ChannelDesign& phiDesign{newRE->m_phiDesign[
layer-1]};
585 phiDesign.type = ChannelDesign::ChannelType::phiStrip;
587 if (copyPhiDesign.yCutout() == 0.) {
588 phiDesign.defineTrapezoid(copyPhiDesign.shortHalfHeight(),
589 copyPhiDesign.longHalfHeight(),
590 copyPhiDesign.halfWidth());
592 phiDesign.defineDiamond(copyPhiDesign.shortHalfHeight(),
593 copyPhiDesign.longHalfHeight(),
594 copyPhiDesign.halfWidth(),
595 copyPhiDesign.yCutout());
597 phiDesign.inputPitch = copyPhiDesign.stripPitch();
598 phiDesign.inputWidth = copyPhiDesign.stripWidth();
599 phiDesign.setFirstPos(copyPhiDesign.firstStripPos().x());
600 phiDesign.firstPitch = copyPhiDesign.numWiresInGroup(1);
601 phiDesign.groupWidth = copyPhiDesign.numWiresInGroup(2);
602 phiDesign.nGroups = copyPhiDesign.numStrips();
603 phiDesign.wireCutout = copyPhiDesign.wireCutout();
604 phiDesign.nch = copyPhiDesign.nAllWires();
608 padDesign.
Length = copyMe->chamberHeight();
609 padDesign.sWidth = copyMe->sChamberLength();
610 padDesign.lWidth = copyMe->lChamberLength();
611 padDesign.Size = 2.*copyPadDesign.halfWidth();
612 padDesign.ysFrame = copyMe->sFrameWidth();
613 padDesign.ylFrame = copyMe->lFrameWidth();
614 padDesign.thickness = copyMe->thickness();
615 padDesign.yCutout = copyPadDesign.yCutout();
616 padDesign.setR(copyPadDesign.beamlineRadius());
617 padDesign.sPadWidth = 2.*copyPadDesign.shortHalfHeight();
618 padDesign.lPadWidth = 2.*copyPadDesign.longHalfHeight();
619 padDesign.nPadColumns = copyPadDesign.numPadPhi();
620 padDesign.firstPhiPos = copyPadDesign.firstPadPhiDiv();
621 padDesign.inputPhiPitch = copyPadDesign.anglePadPhi();
622 padDesign.PadPhiShift = copyPadDesign.padPhiShift();
623 padDesign.nPadH = copyPadDesign.numPadEta();
624 padDesign.padEtaMax = copyPadDesign.maxPadEta();
625 padDesign.firstRowPos = copyPadDesign.firstPadHeight();
626 padDesign.inputRowPitch = copyPadDesign.padHeight();
627 padDesign.sectorOpeningAngle = copyPadDesign.sectorAngle();
631 cacheObj.detMgr->addsTgcReadoutElement(std::move(newRE));
633 return StatusCode::SUCCESS;
◆ buildTgc()
Define the local gasGap positions
In the sector frame, the gasGap is oriented along the x-axis
Definition at line 368 of file ReadoutGeomCnvAlg.cxx.
370 std::vector<const MuonGMR4::TgcReadoutElement*> tgcReadouts{
m_detMgr->getAllTgcReadoutElements()};
373 return a->stationEta() > b->stationEta();
375 ATH_MSG_INFO(
"Copy "<<tgcReadouts.size()<<
" Tgc readout elements to the legacy system");
379 std::map<std::string, std::shared_ptr<TgcReadoutParams>> readoutParMap{};
383 GeoIntrusivePtr<GeoVFullPhysVol> physVol{};
387 auto newRE = std::make_unique<MuonGM::TgcReadoutElement>(physVol,
m_idHelperSvc->stationNameString(reId),
388 cacheObj.detMgr.get());
389 newRE->setIdentifier(reId);
390 newRE->setParentMuonStation(station);
392 std::shared_ptr<TgcReadoutParams>& readOutPars = readoutParMap[copyMe->chamberDesign()];
398 std::array<WiregangArray, 3> wires{};
401 bool stripSet{
false};
402 double wirePitch{0.};
407 if (nWireGangs[
gasGap -1]) {
411 for (
int gang = 1; gang <= design.numStrips(); ++gang) {
412 fillMe[gang -1] = design.numWiresInGroup(gang);
419 botMountings[
strip-1] = - design.stripLeftBottom(strip).x();
420 topMountings[
strip-1] = - design.stripLeftTop(strip).x();
422 botMountings[nCh] = - design.stripRightBottom(nCh).x();
423 topMountings[nCh] = - design.stripRightTop(nCh).x();
428 readOutPars = std::make_unique<TgcReadoutParams>(copyMe->chamberDesign(),
430 idHelper.stationPhiMax(reId),
431 std::move(nWireGangs),
436 std::move(botMountings),
437 std::move(topMountings),
445 const Amg::Vector3D translation{copyMe->globalToLocalTrans(gctx) * copyMe->center(gctx, layHash)};
446 newRE->setPlaneZ(translation.x(),
gasGap);
448 newRE->setSsize(copyMe->moduleHeight());
449 newRE->setRsize(copyMe->moduleWidthS());
450 newRE->setZsize(copyMe->moduleThickness());
452 newRE->setLongSsize(copyMe->moduleHeight());
453 newRE->setLongRsize(copyMe->moduleWidthL());
454 newRE->setLongZsize(copyMe->moduleThickness());
456 newRE->setReadOutParams(readOutPars);
459 cacheObj.detMgr->addTgcReadoutElement(std::move(newRE));
462 return StatusCode::SUCCESS;
◆ cardinality()
unsigned int AthReentrantAlgorithm::cardinality |
( |
| ) |
const |
|
overridevirtualinherited |
Cardinality (Maximum number of clones that can exist) special value 0 means that algorithm is reentrant.
Override this to return 0 for reentrant algorithms.
Override this to return 0 for reentrant algorithms.
Definition at line 55 of file AthReentrantAlgorithm.cxx.
◆ checkIdCompability()
Definition at line 730 of file ReadoutGeomCnvAlg.cxx.
737 return StatusCode::FAILURE;
742 return StatusCode::FAILURE;
744 return StatusCode::SUCCESS;
◆ cloneNswWedge()
Clones the fullPhysicalVolume of the
Definition at line 466 of file ReadoutGeomCnvAlg.cxx.
469 GeoIntrusivePtr<const GeoVFullPhysVol> readOutVol{copyMe->getMaterialGeom()};
470 cacheObj.translatedStations.insert(readOutVol->getParent());
472 PVLink clonedVol{cloneVolume(const_pointer_cast<GeoVFullPhysVol>(readOutVol))};
473 GeoIntrusivePtr<GeoFullPhysVol> physVol{dynamic_pointer_cast<GeoFullPhysVol>(clonedVol)};
474 cacheObj.world->add(cacheObj.newIdTag());
475 cacheObj.world->add(cacheObj.makeTransform(copyMe->localToGlobalTrans(gctx)));
476 cacheObj.world->add(physVol);
◆ cloneReadoutVolume()
Clones the fullPhysical volume of the readoutElement and embeds it into the associated station.
If creations of the needed station fails, failure is returned. The references to the clonedPhysVol & to the station are set if the procedure was successful.
This is a hack to include the BIL Rpcs into the translation. Recall that the BI-RPCs break the station paradigm Hence, in the new description they have their own alignable transform. However, the legacy geometry tries to sort them into the corresponding Mdt station with the same stName, stEta, stPhi. So quite a lot of gymnastics is now needed to place them accordingly into that frame. getX(Mdt) * delta(Mdt) * X = getX(Rpc) * delta(Rpc) X = [getX(Mdt) * delta(Mdt)]^{-1} * getX(Rpc) * delta(Rpc) The second term is the transform of the transform of the Muon station. The second one needs to be rewritten Y = getX(Rpc) * delta(Rpc) * getX(alignNode -> readoutFrame) X = Y * getX(alignNode -> readoutFrame)^{-1}
Clone the detector element with all of its subvolumes
Definition at line 240 of file ReadoutGeomCnvAlg.cxx.
247 const std::string stName{
m_idHelperSvc->stationNameString(reId)};
248 station = cacheObj.detMgr->getMuonStation(stName,
254 GeoIntrusivePtr<const GeoVFullPhysVol> readOutVol{copyMe->getMaterialGeom()};
255 parentPhysVol->add(cacheObj.newIdTag());
267 readOutVol->getParent()->getX() * readOutVol->getX()};
272 parentPhysVol->add(cacheObj.makeTransform(stationTrf*alignNodeToRE));
274 PVLink clonedVol{cloneVolume(const_pointer_cast<GeoVFullPhysVol>(readOutVol))};
275 physVol = dynamic_pointer_cast<GeoVFullPhysVol>(clonedVol);
276 parentPhysVol->add(physVol);
277 return StatusCode::SUCCESS;
◆ declareGaudiProperty() [1/4]
specialization for handling Gaudi::Property<SG::VarHandleKeyArray>
Definition at line 170 of file AthCommonDataStore.h.
175 hndl.documentation());
◆ declareGaudiProperty() [2/4]
specialization for handling Gaudi::Property<SG::VarHandleKey>
Definition at line 156 of file AthCommonDataStore.h.
161 hndl.documentation());
◆ declareGaudiProperty() [3/4]
specialization for handling Gaudi::Property<SG::VarHandleBase>
Definition at line 184 of file AthCommonDataStore.h.
189 hndl.documentation());
◆ declareGaudiProperty() [4/4]
◆ declareProperty() [1/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
hndl | Object holding the property value. |
doc | Documentation string for the property. |
This is the version for types that derive from SG::VarHandleBase
. The property value object is put on the input and output lists as appropriate; then we forward to the base class.
Definition at line 245 of file AthCommonDataStore.h.
250 this->declare(hndl.
vhKey());
251 hndl.
vhKey().setOwner(
this);
◆ declareProperty() [2/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
hndl | Object holding the property value. |
doc | Documentation string for the property. |
This is the version for types that derive from SG::VarHandleKey
. The property value object is put on the input and output lists as appropriate; then we forward to the base class.
Definition at line 221 of file AthCommonDataStore.h.
◆ declareProperty() [3/6]
◆ declareProperty() [4/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
property | Object holding the property value. |
doc | Documentation string for the property. |
This is the generic version, for types that do not derive from SG::VarHandleKey
. It just forwards to the base class version of declareProperty
.
Definition at line 333 of file AthCommonDataStore.h.
◆ declareProperty() [5/6]
Declare a new Gaudi property.
- Parameters
-
name | Name of the property. |
property | Object holding the property value. |
doc | Documentation string for the property. |
This dispatches to either the generic declareProperty
or the one for VarHandle/Key/KeyArray.
Definition at line 352 of file AthCommonDataStore.h.
◆ declareProperty() [6/6]
◆ detStore()
◆ dumpAndCompare() [1/5]
Definition at line 795 of file ReadoutGeomCnvAlg.cxx.
800 return StatusCode::SUCCESS;
806 <<std::endl<<
GeoTrf::toString(testEle.getMaterialGeom()->getAbsoluteTransform())
810 for (
unsigned int lay = 1; lay <= refEle.
numLayers(); ++lay){
813 if (!refEle.
isValid(tubeHash)) {
827 <<
GeoTrf::toString(globToLocal*tubePos) <<
" delta: "<<(refPos - tubePos).mag()
828 <<
" Transforms "<<std::endl
831 return StatusCode::FAILURE;
841 std::numeric_limits<float>::epsilon() ) {
845 return StatusCode::FAILURE;
850 return StatusCode::SUCCESS;
◆ dumpAndCompare() [2/5]
Definition at line 747 of file ReadoutGeomCnvAlg.cxx.
752 return StatusCode::SUCCESS;
768 return StatusCode::FAILURE;
772 for (
int strip = stripDesign.firstStripNumber(); strip <= stripDesign.numStrips(); ++strip) {
780 return StatusCode::FAILURE;
782 const double dist = refStripDir.dot(refStripPos - testStripPos);
787 return StatusCode::FAILURE;
792 return StatusCode::SUCCESS;
◆ dumpAndCompare() [3/5]
Definition at line 852 of file ReadoutGeomCnvAlg.cxx.
857 return StatusCode::SUCCESS;
868 for (
bool measPhi : {
false,
true}) {
869 if (measPhi && !refEle.
nPhiStrips())
continue;
873 doubPhi,
gasGap, measPhi, strip);
882 return StatusCode::FAILURE;
895 if ((refStripPos - testStripPos).
mag() > 2
e-4){
898 <<
" local coordinates -- ref: "<<
Amg::toString(refTrans.inverse()*refStripPos)
899 <<
" test: "<<
Amg::toString(refTrans.inverse()*testStripPos));
900 return StatusCode::FAILURE;
904 <<
", local: "<<
Amg::toString(refTrans.inverse()*refStripPos));
909 return StatusCode::SUCCESS;
◆ dumpAndCompare() [4/5]
Definition at line 985 of file ReadoutGeomCnvAlg.cxx.
990 return StatusCode::SUCCESS;
999 for (
int chType = sTgcIdHelper::sTgcChannelTypes::Pad;
chType <= sTgcIdHelper::sTgcChannelTypes::Wire; ++
chType) {
1000 unsigned int numChannel = 0;
1005 case sTgcIdHelper::sTgcChannelTypes::Pad:
1006 numChannel = refEle.
numPads(layID);
1009 case sTgcIdHelper::sTgcChannelTypes::Strip:
1013 case sTgcIdHelper::sTgcChannelTypes::Wire:
1028 return StatusCode::FAILURE;
1030 if (
chType == sTgcIdHelper::sTgcChannelTypes::Pad) {
1035 const std::array<Amg::Vector3D,4> refPadCorners = refEle.
globalPadCorners(gctx, chID);
1036 std::array<Amg::Vector3D,4> testPadCorners{make_array<Amg::Vector3D, 4>(
Amg::Vector3D::Zero())};
1038 for (
unsigned int cornerIdx = 0; cornerIdx < refPadCorners.size(); ++cornerIdx) {
1044 return StatusCode::FAILURE;
1052 return StatusCode::FAILURE;
1066 return StatusCode::FAILURE;
1074 return StatusCode::SUCCESS;
◆ dumpAndCompare() [5/5]
Definition at line 911 of file ReadoutGeomCnvAlg.cxx.
916 return StatusCode::SUCCESS;
924 <<std::endl<<
GeoTrf::toString(testEle.getMaterialGeom()->getAbsoluteTransform(),
true)
930 for (
bool isStrip : {
false,
true}) {
941 <<
" are not identical. ");
942 return StatusCode::FAILURE;
953 if ((refChannel - testChannel).
mag() < std::numeric_limits<float>::epsilon()){
956 std::stringstream
msg{};
958 <<
" is not at the same position "<<
Amg::toString(refChannel)
960 <<(refChannel - testChannel).
mag();
962 msg<<std::endl<<
"*** Test *** - wirePitch: "<<testEle.
wirePitch()
967 msg<<std::endl<<
"*** Ref *** - wirePitch: "<<design.stripPitch()
969 <<
", wires to reach "<<design.numPitchesToGroup(
ch)
970 <<
", wires in gang "<<design.numWiresInGroup(
ch);
972 const Amg::Vector3D locRefPos{refLayerTrf.inverse() * refChannel};
973 const Amg::Vector3D locTestPos{refLayerTrf.inverse()* testChannel};
978 return StatusCode::FAILURE;
983 return StatusCode::SUCCESS;
◆ evtStore() [1/2]
◆ evtStore() [2/2]
◆ execute()
StatusCode MuonGMR4::ReadoutGeomCnvAlg::execute |
( |
const EventContext & |
ctx | ) |
const |
|
override |
Prepare the Geometry context
Ensure that the position & tracking alignment caches are split from the conditions object
Check that for every detector technology there's an DetectorAlignStore in the geometry context Otherwise create an empty one.
Create the cache and populate it with the geoWolds
Build the chamber technologies
Finally add the passives
Move the passives also onto the new world tree...
Final check that all elements are cached properly
Definition at line 78 of file ReadoutGeomCnvAlg.cxx.
80 if (writeHandle.isValid()) {
81 ATH_MSG_DEBUG(
"The current readout geometry is still valid.");
82 return StatusCode::SUCCESS;
90 if (!readHandle.isValid()) {
92 return StatusCode::FAILURE;
94 writeHandle.addDependency(readHandle);
95 auto alignStore = std::make_unique<ActsTrk::DetectorAlignStore>(**readHandle);
97 if (alignStore->geoModelAlignment) {
98 alignStore->geoModelAlignment->clearPosCache();
100 alignStore->trackingAlignment = std::make_unique<TrackingAlignment>(alignStore->detType);
101 geoContext.setStore(std::move(alignStore));
107 if (geoContext.getStore(detType)) {
111 geoContext.setStore(std::make_unique<ActsTrk::DetectorAlignStore>(detType));
114 ConstructionCache cacheObj;
115 cacheObj.detMgr = std::make_unique<MuonGM::MuonDetectorManager>();
116 cacheObj.world = createGeoWorld();
117 cacheObj.detMgr->addTreeTop(cacheObj.world);
125 std::vector<GeoChildNodeWithTrf> treeTops = getChildrenWithRef(
m_detMgr->
getTreeTop(0),
false);
128 for (
const GeoChildNodeWithTrf& treeTop : treeTops) {
129 if (hasStationVolume(treeTop.volume, cacheObj.translatedStations))
continue;
132 cacheObj.world->add(const_pointer_cast(treeTop.volume));
143 ATH_CHECK(writeHandle.record(std::move(cacheObj.detMgr)));
144 return StatusCode::SUCCESS;
◆ extraDeps_update_handler()
Add StoreName to extra input/output deps as needed.
use the logic of the VarHandleKey to parse the DataObjID keys supplied via the ExtraInputs and ExtraOuputs Properties to add the StoreName if it's not explicitly given
◆ extraOutputDeps()
const DataObjIDColl & AthReentrantAlgorithm::extraOutputDeps |
( |
| ) |
const |
|
overridevirtualinherited |
Return the list of extra output dependencies.
This list is extended to include symlinks implied by inheritance relations.
Definition at line 79 of file AthReentrantAlgorithm.cxx.
86 return Algorithm::extraOutputDeps();
◆ filterPassed()
virtual bool AthReentrantAlgorithm::filterPassed |
( |
const EventContext & |
ctx | ) |
const |
|
inlinevirtualinherited |
◆ initialize()
StatusCode MuonGMR4::ReadoutGeomCnvAlg::initialize |
( |
| ) |
|
|
override |
◆ inputHandles()
Return this algorithm's input handles.
We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.
◆ isClonable()
bool AthReentrantAlgorithm::isClonable |
( |
| ) |
const |
|
overridevirtualinherited |
Specify if the algorithm is clonable.
Reentrant algorithms are clonable.
Reimplemented in Simulation::BeamEffectsAlg, InDet::SiTrackerSpacePointFinder, InDet::SCT_Clusterization, InDet::SiSPSeededTrackFinder, SCTRawDataProvider, InDet::GNNSeedingTrackMaker, SCT_PrepDataToxAOD, RoIBResultToxAOD, InDet::SiSPGNNTrackMaker, SCT_CablingCondAlgFromCoraCool, SCT_ReadCalibDataTestAlg, SCT_CablingCondAlgFromText, SCT_ReadCalibChipDataTestAlg, SCT_TestCablingAlg, SCT_ConfigurationConditionsTestAlg, ITkPixelCablingAlg, ITkStripCablingAlg, SCTEventFlagWriter, SCT_ConditionsSummaryTestAlg, SCT_ModuleVetoTestAlg, SCT_MonitorConditionsTestAlg, SCT_LinkMaskingTestAlg, SCT_MajorityConditionsTestAlg, SCT_RODVetoTestAlg, SCT_SensorsTestAlg, SCT_TdaqEnabledTestAlg, SCT_SiliconConditionsTestAlg, SCTSiLorentzAngleTestAlg, SCT_ByteStreamErrorsTestAlg, SCT_ConditionsParameterTestAlg, SCT_FlaggedConditionTestAlg, SCT_StripVetoTestAlg, SCT_RawDataToxAOD, and SCTSiPropertiesTestAlg.
Definition at line 44 of file AthReentrantAlgorithm.cxx.
◆ isReEntrant()
bool MuonGMR4::ReadoutGeomCnvAlg::isReEntrant |
( |
| ) |
const |
|
inlineoverride |
◆ msg() [1/2]
◆ msg() [2/2]
◆ msgLvl()
◆ outputHandles()
Return this algorithm's output handles.
We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.
◆ renounce()
◆ renounceArray()
◆ setFilterPassed()
virtual void AthReentrantAlgorithm::setFilterPassed |
( |
bool |
state, |
|
|
const EventContext & |
ctx |
|
) |
| const |
|
inlinevirtualinherited |
◆ sysExecute()
StatusCode AthReentrantAlgorithm::sysExecute |
( |
const EventContext & |
ctx | ) |
|
|
overridevirtualinherited |
Execute an algorithm.
We override this in order to work around an issue with the Algorithm base class storing the event context in a member variable that can cause crashes in MT jobs.
Definition at line 67 of file AthReentrantAlgorithm.cxx.
69 return Gaudi::Algorithm::sysExecute (ctx);
◆ sysInitialize()
StatusCode AthReentrantAlgorithm::sysInitialize |
( |
| ) |
|
|
overridevirtualinherited |
Override sysInitialize.
Override sysInitialize from the base class.
Loop through all output handles, and if they're WriteCondHandles, automatically register them and this Algorithm with the CondSvc
Scan through all outputHandles, and if they're WriteCondHandles, register them with the CondSvc
Reimplemented from AthCommonDataStore< AthCommonMsg< Gaudi::Algorithm > >.
Reimplemented in InputMakerBase, and HypoBase.
Definition at line 96 of file AthReentrantAlgorithm.cxx.
107 if ( cs.retrieve().isFailure() ) {
109 return StatusCode::SUCCESS;
111 if (cs->regHandle(
this,*
h).isFailure()) {
112 sc = StatusCode::FAILURE;
113 ATH_MSG_ERROR(
"unable to register WriteCondHandle " <<
h->fullKey()
◆ sysStart()
Handle START transition.
We override this in order to make sure that conditions handle keys can cache a pointer to the conditions container.
◆ updateVHKA()
◆ m_alignStoreKeys
◆ m_checkGeo
Gaudi::Property<bool> MuonGMR4::ReadoutGeomCnvAlg::m_checkGeo {this, "checkGeo", false, "Checks the positions of the sensors"} |
|
private |
◆ m_detMgr
◆ m_detStore
◆ m_evtStore
◆ m_extendedExtraObjects
DataObjIDColl AthReentrantAlgorithm::m_extendedExtraObjects |
|
privateinherited |
Extra output dependency collection, extended by AthAlgorithmDHUpdate to add symlinks.
Empty if no symlinks were found.
Definition at line 153 of file AthReentrantAlgorithm.h.
◆ m_idHelperSvc
◆ m_varHandleArraysDeclared
◆ m_vhka
◆ m_writeKey
The documentation for this class was generated from the following files:
def retrieve(aClass, aKey=None)
StatusCode buildSTGC(const ActsGeometryContext &gctx, ConstructionCache &cacheObj) const
int doubletPhiMax() const
Returns the maximum phi panel.
StatusCode buildMdt(const ActsGeometryContext &gctx, ConstructionCache &cacheObj) const
sTgcIdHelper::sTgcChannelTypes chType
StatusCode dumpAndCompare(const ActsGeometryContext &gctx, const MuonGMR4::RpcReadoutElement &refEle, const MuonGM::RpcReadoutElement &testEle) const
Parameters defining the design of the readout sTGC pads.
int multilayer() const
Returns the multilayer of the sTgcReadoutElement.
virtual const Amg::Transform3D & transform() const override
Return local to global transform.
const WireGroupDesign & wireGangLayout(unsigned int gasGap) const
Returns access to the wire group design of the given gasGap [1-3] If the gap does not have a wires an...
std::vector< ActsTrk::DetectorType > getDetectorTypes() const
Returns a list of all detector types.
static IdentifierHash createHash(const int gasGap, const int strip)
const Amg::Transform3D & absTransform() const
StatusCode cloneReadoutVolume(const ActsGeometryContext &gctx, const Identifier &stationId, ConstructionCache &cacheObj, GeoIntrusivePtr< GeoVFullPhysVol > &clonedPhysVol, MuonGM::MuonStation *&station) const
Clones the fullPhysical volume of the readoutElement and embeds it into the associated station.
unsigned int nGasGaps() const
Returns the number of gas gaps.
double tubeLength(const int tubeLayer, const int tube) const
unsigned int numTubesInLay() const
Returns the number of tubes per layer.
StatusCode buildStation(const ActsGeometryContext &gctx, const Identifier &stationId, ConstructionCache &cacheObj) const
builds a station object from readout element.
DetectorType
Simple enum to Identify the Type of the ACTS sub detector.
StatusCode buildTgc(const ActsGeometryContext &gctx, ConstructionCache &cacheObj) const
Scalar perp() const
perp method - perpenticular length
PVConstLink getPhysVol() const
void defineTrapezoid(double HalfShortY, double HalfLongY, double HalfHeight)
set the trapezoid dimensions
Store holding the transfomations used by the Acts algorithms.
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
double tubeLength(const IdentifierHash &hash) const
TgcReadoutParams::GasGapIntArray GasGapIntArray
static IdentifierHash measurementHash(unsigned int layerNumber, unsigned int tubeNumber)
Transform the layer and tube number to the measurementHash.
unsigned int nGasGaps() const
Returns the number of gasgaps described by this ReadOutElement (usally 2 or 3)
Amg::Transform3D getTransform() const
Amg::Vector3D channelPosition(const ActsGeometryContext &ctx, const Identifier &measId) const
Returns the center of the measurement channel eta measurement: wire gang center phi measurement: stri...
std::enable_if_t< std::is_void_v< std::result_of_t< decltype(&T::renounce)(T)> > &&!std::is_base_of_v< SG::VarHandleKeyArray, T > &&std::is_base_of_v< Gaudi::DataHandle, T >, void > renounce(T &h)
unsigned int nGasGaps() const
Returns the number of gasgaps described by this ReadOutElement (usally 2 or 3)
The MuonReadoutElement is an abstract class representing the geometry representing the muon detector.
double activeTubeLength(const IdentifierHash &hash) const
IdentifierHash detectorElementHash() const
Returns the IdentifierHash of the detector element.
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
std::vector< SG::VarHandleKeyArray * > m_vhka
ReadoutChannelType
ReadoutChannelType to distinguish the available readout channels Pad - pad readout channel Strip - et...
Helper struct to retrieve the tube lengths and the tube centers directly from the GeoModel tree.
std::vector< const MuonReadoutElement * > getAllReadoutElements() const
Returns the list of all detector elements.
double getTubeLengthForCaching(const int tubeLayer, const int tube) const
Amg::Transform3D globalToLocalTrans(const ActsGeometryContext &ctx) const
Transformations to translate between local <-> global coordinates.
#define ATH_MSG_VERBOSE(x)
SG::ReadCondHandleKeyArray< ActsTrk::DetectorAlignStore > m_alignStoreKeys
StatusCode buildMM(const ActsGeometryContext &gctx, ConstructionCache &cacheObj) const
double getLongSsize() const
Gaudi::Property< bool > m_checkGeo
static IdentifierHash constructHash(unsigned int measCh, unsigned int gasGap, const bool isStrip)
Constructs the Hash out of the Identifier fields (channel, gasGap, isStrip)
StatusCode buildRpc(const ActsGeometryContext &gctx, ConstructionCache &cacheObj) const
TgcReadoutParams::WiregangArray WiregangArray
void stable_sort(std::reverse_iterator< DataModel_detail::iterator< DVL > > beg, std::reverse_iterator< DataModel_detail::iterator< DVL > > end, Compare comp)
Specialization of stable_sort for DataVector/List.
bool padGlobalCorners(const Identifier &id, std::array< Amg::Vector3D, 4 > &gcorners) const
pad global corners
Set of parameters to describe a RPC chamber.
Amg::Vector3D channelPos(const Identifier &id) const
Returns the position of the active channel (wireGang or strip)
const ServiceHandle< StoreGateSvc > & detStore() const
The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.
virtual void setOwner(IDataHandleHolder *o)=0
StatusCode checkIdCompability(const MuonGMR4::MuonReadoutElement &refEle, const MuonGM::MuonReadoutElement &testEle) const
An algorithm that can be simultaneously executed in multiple threads.
Amg::Transform3D getRotateZ3D(double angle)
get a rotation transformation around Z-axis
double getLongRsize() const
Identifier measurementId(const IdentifierHash &measHash) const override final
Converts the measurement hash back to the full Identifier.
Helper struct to cache simulatenously the As-built and the BLine corrections of the Mdts for fast acc...
double wireLength(const IdentifierHash &hash) const
double getWireLength(const int tubeLayer, const int tube) const
chamberDistortions getDistortion(const Identifier &detElId) const
Returns a chamber distortion that's cached for the corresponding Mdt chamber element.
AlignmentStorePtr & getStore(const DetectorType type)
Returns the mutable alignable store for the ATLAS detector type (Pixel, Mdt, etc.)
GeoIntrusivePtr< GeoVFullPhysVol > cloneNswWedge(const ActsGeometryContext &gctx, const MuonGMR4::MuonReadoutElement *nswRE, ConstructionCache &cacheObj) const
Clones the fullPhysicalVolume of the
double uncutTubeLength(const IdentifierHash &tubeHash) const
Returns the uncut tube length.
static IdentifierHash createHash(const unsigned int gasGap, const unsigned int channelType, const unsigned int channel, const unsigned int wireInGrp=0)
Create a measurement hash from the Identifier fields.
Helper struct to store the pointer to the Mdt distrotion parameters, namely the As-built and the BLin...
std::string toString(const Translation3D &translation, int precision=4)
GeoPrimitvesToStringConverter.
int multilayer() const
Returns the multi layer of the element [1-2].
double nPitchesToGang(int gasGap, int gang) const
Returns the number of wire pitches that have to be travelled to reach gang i.
virtual std::vector< Gaudi::DataHandle * > outputHandles() const override
Return this algorithm's output handles.
Amg::Vector3D stripPosition(const ActsGeometryContext &ctx, const Identifier &measId) const
Returns the position of the strip center.
@ Mm
Maybe not needed in the migration.
unsigned int numWireGroups(unsigned int gasGap) const
Number of wire groups in the gas gap.
Set of parameters to describe a MDT chamber.
double getLongZsize() const
::StatusCode StatusCode
StatusCode definition for legacy code.
CalibratedSpacePoint::Covariance_t inverse(const CalibratedSpacePoint::Covariance_t &mat)
Inverts the parsed matrix.
int nWires(int gasGap) const
Returns the total number of wires in a given gas gap.
bool stripGlobalPosition(const Identifier &id, Amg::Vector3D &gpos) const
int doubletPhi() const
Returns the doublet Phi field of the MuonReadoutElement identifier.
double getActiveTubeLength(const int tubeLayer, const int tube) const
unsigned int numLayers() const
Returns the number of tube layer.
Eigen::Affine3d Transform3D
bool doesNotDeform(const Amg::Transform3D &trans)
Checks whether the linear part of the transformation rotates or stetches any of the basis vectors.
Amg::Vector3D stripPosition(const ActsGeometryContext &ctx, const Identifier &measId) const
Returns the position of the strip center.
static EventIDRange infiniteRunLB()
Produces an EventIDRange that is infinite in RunLumi and invalid in Time.
Identifier measurementId(const IdentifierHash &measHash) const override final
Converts the measurement hash back to the full Identifier.
int doubletZ() const
Returns the doublet Z field of the MuonReadoutElement identifier.
bool isIdentity(const Amg::Transform3D &trans)
Checks whether the transformation is the Identity transformation.
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
IdentifierHash identHash() const
Returns the Identifier has of the Element that is Identical to the detElHash from the id_helper class...
Include the GeoPrimitives which need to be put first.
DataObjIDColl m_extendedExtraObjects
Extra output dependency collection, extended by AthAlgorithmDHUpdate to add symlinks.
virtual void renounce()=0
std::conditional< std::is_base_of< SG::VarHandleKeyArray, T >::value, VarHandleKeyArrayType, type2 >::type type
const StripLayer & stripLayer(const Identifier &measId) const
int nStrips(const MuonGM::TgcReadoutElement &readoutEle, int layer)
PVConstLink getTreeTop(unsigned int i) const override final
Returns the i-th top node of the MuonSystem trees.
const MdtAsBuiltPar * asBuilt
ServiceHandle< Muon::IMuonIdHelperSvc > m_idHelperSvc
std::array< MuonChannelDesign, 4 > m_etaDesign
Amg::Vector3D globalChannelPosition(const ActsGeometryContext &ctx, const Identifier &measId) const
Returns the global pad/strip/wireGroup position.
std::string to_string(const DetectorType &type)
const GeoAlignableTransform * alignableTransform() const
Returnsthe alignable transform of the readout element.
Amg::Vector3D stripPos(const Identifier &id) const
bool stripGlobalPosition(const Identifier &id, Amg::Vector3D &gpos) const
virtual StatusCode sysInitialize() override
Override sysInitialize.
StatusCode initialize(bool used=true)
Amg::Transform3D getRotateY3D(double angle)
get a rotation transformation around Y-axis
Identifier identify() const override final
Return the athena identifier.
unsigned int nPhiStrips() const
Number of strips measuring the phi coordinate.
Eigen::Matrix< double, 3, 1 > Vector3D
double wirePitch() const
Returns the pitch of the wires.
unsigned int numChannels(const IdentifierHash &measHash) const
Returns the number of readout channels.
unsigned int numLayers() const
Returns the number of gas gap layers.
const StripDesign & design() const
Returns the underlying strip design.
TgcReadoutParams::StripArray StripArray
Amg::Vector3D tubePos(const Identifier &id) const
Returns the global position of the given tube.
IdentifierHash layerHash(const Identifier &measId) const override final
#define ATH_MSG_WARNING(x)
globalCornerArray globalPadCorners(const ActsGeometryContext &ctx, const Identifier &measId) const
Identifier identify() const override final
Returns the ATLAS Identifier of the MuonReadOutElement.
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
int Nstrips(bool measphi) const
returns the number of strips for the phi or eta plane
unsigned int numPads(const Identifier &measId) const
Pads Total number of pads in the given layer.
unsigned int numStrips(const Identifier &measId) const
Strips Number of strips in a chamber.
const Amg::Transform3D & localToGlobalTrans(const ActsGeometryContext &ctx) const
Returns the local to global transformation into the ATLAS coordinate system.
Amg::Vector3D globalTubePos(const ActsGeometryContext &ctx, const Identifier &measId) const
Returns the global position of the tube center.
double stripPitch() const
Distance between two adjacent strips.
virtual const Amg::Transform3D & transform(const Identifier &id) const override final
Return local to global transform associated with this identifier.
This is a "hash" representation of an Identifier. This encodes a 32 bit index which can be used to lo...
SG::WriteCondHandleKey< MuonGM::MuonDetectorManager > m_writeKey
bool isValid(const IdentifierHash &measHash) const
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
Scalar mag() const
mag method
const MuonGMR4::MuonDetectorManager * m_detMgr
Amg::Transform3D getTranslate3D(const double X, const double Y, const double Z)
: Returns a shift transformation along an arbitrary axis
const MuonReadoutElement * getReadoutElement(const Identifier &id) const
Returns a generic Muon readout element.