|
ATLAS Offline Software
|
Go to the documentation of this file.
30 SCTGeometryManagerTool::SCTGeometryManagerTool(
const std::string&
type,
31 const std::string&
name,
34 , m_detManager(nullptr)
36 , m_alignModuleTool(
"Trk::AlignModuleTool/AlignModuleTool")
38 , m_alignParList(nullptr)
39 , m_fullAlignParList(nullptr)
41 declareInterface<IGeometryManagerTool>(
this);
127 return StatusCode::FAILURE;
135 return StatusCode::FAILURE;
143 return StatusCode::FAILURE;
157 return StatusCode::FAILURE;
159 return StatusCode::SUCCESS;
167 return StatusCode::SUCCESS;
186 ATH_MSG_INFO(
"Setting up OLD L2 alignment level for SCT");
216 case 1:
case 2:
case 27:
case 3:
233 case 1:
case 2:
case 25:
case 3:
260 std::vector<Trk::AlignModule *>::const_iterator imod =
m_alignModuleList.begin();
261 std::vector<Trk::AlignModule *>::const_iterator imod_end =
m_alignModuleList.end();
262 for( ; imod!=imod_end ; ++imod)
280 ATH_MSG_INFO(
"Total number of degrees of freedom: "<<nDoF);
338 ATH_MSG_INFO(
"Preparing the SCT geometry for L0: the whole SCT");
368 IdentifierHash idHash =
index;
391 (*sctIdHashMap)[idHash] = sct;
400 ATH_MSG_DEBUG(
"SCT L0 module successfully added to the geometry");
409 ATH_MSG_INFO(
"Preparing the SCT Barrel geometry for L1: barrel + 2 endcaps");
426 mod->setName(
"SCT Barrel");
454 for (
int is = 0; is < 2; is++) {
477 ATH_MSG_DEBUG(
"SCT Barrel successfully added to the geometry");
486 ATH_MSG_INFO(
"Preparing the SCT Endcap geometry for L1: 2 endcaps");
505 if(iEndcapIndex == 0)
506 mod->setName(
"SCT EndCap A");
508 mod->setName(
"SCT EndCap C");
528 for(
int is=0; is<2; is++) {
550 ATH_MSG_DEBUG(
"Endcap:" << iSide <<
" , CoG (" << translation.x() <<
" , " << translation.y() <<
" , " << translation.z() <<
" ) " );
551 Amg::Transform3D localtoglobal = translation * Amg::RotationMatrix3D::Identity();
553 mod->setGlobalFrameToAlignFrameTransform(localtoglobal.inverse());
558 ATH_MSG_DEBUG(
"SCT End-caps successfully added to the geometry");
566 ATH_MSG_INFO(
"Preparing the SCT Barrel geometry for L2: 4 layers");
590 std::stringstream
name;
591 name <<
"SCT/Barrel/Layer_"<<iLayer;
609 for (
int is = 0; is < 2; is++) {
638 ATH_MSG_INFO(
"Preparing the SCT Barrel geometry for L27: 176 staves (ladders)");
672 std::stringstream
name;
673 name <<
"SCT/Barrel/Layer_"<<iLayer<<
"/PhiStave_"<<
iPhi;
692 for (
int is = 0; is < 2; is++) {
723 ATH_MSG_DEBUG(
" - translation: "<<localToGlobal.translation().x()<<
" "<<localToGlobal.translation().y()<<
" "<<localToGlobal.translation().z());
725 ATH_MSG_DEBUG(
" "<<localToGlobal.rotation()(0,0)<<
" "<<localToGlobal.rotation()(0,1)<<
" "<<localToGlobal.rotation()(0,2));
726 ATH_MSG_DEBUG(
" "<<localToGlobal.rotation()(1,0)<<
" "<<localToGlobal.rotation()(1,1)<<
" "<<localToGlobal.rotation()(1,2));
727 ATH_MSG_DEBUG(
" "<<localToGlobal.rotation()(2,0)<<
" "<<localToGlobal.rotation()(2,1)<<
" "<<localToGlobal.rotation()(2,2));
729 mod->setGlobalFrameToAlignFrameTransform(localToGlobal.inverse());
741 ATH_MSG_INFO(
"Preparing the SCT Endcap geometry for L2: 2 x 9 disks");
766 std::stringstream
name;
767 if(iEndcapIndex == 0)
768 name <<
"SCT/EndcapA/Disk_" << iWheel;
770 name <<
"SCT/EndcapC/Disk_" << iWheel;
785 for(
int is=0; is<2; is++) {
806 ATH_MSG_DEBUG(
"Endcap:" << iSide <<
" , disk: " << iWheel <<
" , CoG (" << translation.x() <<
" , " << translation.y() <<
" , " << translation.z() <<
" ) " );
807 Amg::Transform3D localtoglobal = translation * Amg::RotationMatrix3D::Identity();
808 mod->setGlobalFrameToAlignFrameTransform(localtoglobal.inverse());
820 ATH_MSG_INFO(
"Preparing the SCT Endcap geometry for L25: 2 x 22 rings");
852 std::stringstream
name;
853 if(iEndcapIndex == 0)
854 name <<
"SCT/EndcapA/Disk_"<<iWheel<<
"/Ring_"<<
iEta;
856 name <<
"SCT/EndcapC/Disk_"<<iWheel<<
"/Ring_"<<
iEta;
869 for(
int is=0; is<2; is++) {
892 ATH_MSG_DEBUG(
"Endcap:" << iSide <<
" , disk: " << iWheel <<
" , CoG (" << translation.x() <<
" , " << translation.y() <<
" , " << translation.z() <<
" ) " );
893 Amg::Transform3D localtoglobal = translation * Amg::RotationMatrix3D::Identity();
894 mod->setGlobalFrameToAlignFrameTransform(localtoglobal.inverse());
905 ATH_MSG_INFO(
"Preparing the old SCT Barrel geometry for L2: 4 barrel layers + 2 x 9 endcap disks");
917 int iEndcapIndex = 1;
927 std::stringstream
name;
928 name <<
"SCT/EndcapC/Disk_" << iWheel;
943 for(
int is=0; is<2; is++) {
963 ATH_MSG_DEBUG(
"Endcap:" << iSide <<
" , disk: " << iWheel <<
" , CoG (" << translation.x() <<
" , " << translation.y() <<
" , " << translation.z() <<
" ) " );
964 Amg::Transform3D localtoglobal = translation * Amg::RotationMatrix3D::Identity();
965 mod->setGlobalFrameToAlignFrameTransform(localtoglobal.inverse());
980 std::stringstream
name;
981 name <<
"SCT/Barrel/Layer_"<<iLayer;
999 for (
int is = 0; is < 2; is++) {
1033 std::stringstream
name;
1034 name <<
"SCT/EndcapA/Disk_" << iWheel;
1049 for(
int is=0; is<2; is++) {
1069 ATH_MSG_DEBUG(
"Endcap:" << iSide <<
" , disk: " << iWheel <<
" , CoG (" << translation.x() <<
" , " << translation.y() <<
" , " << translation.z() <<
" ) " );
1071 Amg::Transform3D localtoglobal = translation * Amg::RotationMatrix3D::Identity();
1073 mod->setGlobalFrameToAlignFrameTransform(localtoglobal.inverse());
1084 ATH_MSG_INFO(
"Preparing the SCT Barrel geometry for L3: module (bi-wafer) level");
1113 std::stringstream
name;
1114 name <<
"SCT/Barrel/Layer_"<<iLayer<<
"/Phi_"<<
iPhi<<
"/Eta_"<<
iEta;
1125 for(
int is=0;is<2;is++) {
1169 ATH_MSG_INFO(
"Preparing the SCT Endcap geometry for L3: module (bi-wafer) level");
1196 std::stringstream
name;
1197 if(iEndcapIndex == 0)
1198 name<<
"SCT/EndcapA";
1200 name<<
"SCT/EndcapC";
1212 for(
int is=0; is<2; is++) {
1269 for(
unsigned int ipar=0;ipar<fullModPars->
size();++ipar) {
1305 allFullModPars->push_back(fullModPars);
1306 allActiveModPars->push_back(activeModPars);
1312 for(
unsigned int ipar=0;ipar<modPars->
size();++ipar) {
1383 for(
int i=0;
i<nsel;++
i)
1399 ATH_MSG_INFO(
"---------------------------------------------------");
1409 ATH_MSG_DEBUG(
" - local to global : "<<std::setprecision(12)<<localtoglobal.translation()<<
" "<<localtoglobal.rotation());
1412 int npars =
pars->size();
1413 ATH_MSG_DEBUG(
" - number of active transform parameters: "<<npars);
1414 for(
int j=0;j<npars;j++)
1417 ATH_MSG_INFO(
"---------------------------------------------------");
def retrieve(aClass, aKey=None)
const Identifier & identify(const UncalibratedMeasurement *meas)
Returns the associated identifier from the muon measurement.
This is an Identifier helper class for the SCT subdetector. This class is a factory for creating comp...
const SiNumerology & numerology() const
Access Numerology.
std::vector< AlignModule * > AlignModuleList
@ VIEW_ELEMENTS
this data object is a view, it does not own its elmts
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
void addDetElement(AlignModule::DetectorType detType, const TrkDetElementBase *det, const Amg::Transform3D &transform, Identifier id=Identifier())
used to add a detector element to the align module with a align frame to detector element local frame...
bool useLayer(int layer) const
Check if layer exists.
bool msgLvl(const MSG::Level lvl) const
virtual SiDetectorElement * getDetectorElement(const Identifier &id) const override
access to individual elements via Identifier
AlignModule::TransformParameters paramType() const
returns the type of parameter (i.e.
bool skipEtaZeroForLayer(int layer) const
Check if eta_module=0 exists.
const ServiceHandle< StoreGateSvc > & detStore() const
The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.
AlignModule is a grouping of TrkDetElementBase objects, grouped according to the type of alignment,...
void setSigma(double sigma)
sets sigma
void setName(const std::string &name)
Set and return name of align module (i.e.
void setIdentifier(Identifier identifier)
Set and return identifier of module.
const Amg::Transform3D & moduleTransform() const
Module to global frame transform.
@ OWN_ELEMENTS
this data object owns its elements
IdentifierHash identifyHash() const
Set and return index of module, used by alignment classes to keep track of order of align module.
::StatusCode StatusCode
StatusCode definition for legacy code.
CalibratedSpacePoint::Covariance_t inverse(const CalibratedSpacePoint::Covariance_t &mat)
Inverts the parsed matrix.
Eigen::Affine3d Transform3D
Amg::Vector3D transform(Amg::Vector3D &v, Amg::Transform3D &tr)
Transform a point from a Trasformation3D.
int endcapId(int index) const
Barrel/endcap identifier for each endcap.
bool useDisk(int disk) const
Check if disk exists.
int numDisks() const
Number of disks.
const std::string & name() const
Ensure that the ATLAS eigen extensions are properly loaded.
size_type wafer_hash_max(void) const
value_type push_back(value_type pElem)
Add an element to the end of the collection.
constexpr unsigned int numLayers()
void setIdHash(IdentifierHash id)
An STL vector of pointers that by default owns its pointed-to elements.
Eigen::Matrix< double, 3, 3 > RotationMatrix3D
int beginEtaModuleForLayer(int layer) const
First eta_module number for a layer.
Eigen::Translation< double, 3 > Translation3D
virtual IdentifierHash identifyHash() const =0
Identifier hash.
void setSoftCut(double softCut)
sets soft-mode-cut
const T * at(size_type n) const
Access an element, as an rvalue.
Identifier wafer_id(int barrel_ec, int layer_disk, int phi_module, int eta_module, int side) const
For a single side of module.
bool isStereo() const
Check if it is the stereo side (useful for SCT)
setScale setgFexType iEta
size_type size() const noexcept
Returns the number of elements in the collection.
Identifier identify() const
bool is_barrel(const Identifier &id) const
Test for barrel - WARNING: id MUST be sct id, otherwise answer is not accurate. Use SiliconID for gen...