ATLAS Offline Software
Loading...
Searching...
No Matches
InDet::SCTGeometryManagerTool Class Reference

#include <SCTGeometryManagerTool.h>

Inheritance diagram for InDet::SCTGeometryManagerTool:
Collaboration diagram for InDet::SCTGeometryManagerTool:

Public Member Functions

virtual ~SCTGeometryManagerTool ()
StatusCode initialize ()
StatusCode finalize ()
int ReadGeometry (int solveLevel)
 read the geometry Method is called from the main AlignAlg to build the geometry based on the requested level of alignment.
void PrintModPositions ()
void StoreModPositions (std::string)
void buildGeometry ()
 builds geometry for SCT alignment
void addModuleParameters (Trk::AlignModule *module, DataVector< DataVector< Trk::AlignPar > > *allFullModPars, DataVector< DataVector< Trk::AlignPar > > *allActiveModPars)
 adds alignment parameters for the module checks for active parameters and calls setSigmas()
bool checkAlignLevel ()
 check whether the alignment level is correct
bool checkAlignLevelBarrel ()
 check whether the Barrel alignment level is correct
bool checkAlignLevelEndcaps ()
 check whether the Endcap alignment level is correct
void setAlignLevel (int level)

Private Member Functions

void buildL0 ()
 creates L0 AlignModules for SCT
void buildL1Barrel ()
 creates L1 AlignModules for SCT barrel
void buildL1Endcaps ()
 creates L1 AlignModules for SCT endcaps
void buildL2Barrel ()
 creates L2 AlignModules for SCT barrel
void buildL27Barrel ()
 creates L27 AlignModules for SCT barrel
void buildL2Endcaps ()
 creates L2 AlignModules for SCT endcaps
void buildL25Endcaps ()
 creates L25 AlignModules for SCT endcaps
void buildL2Old ()
 creates L2 AlignModules for the full Pixel in the ordering equal to the old code
void buildL3Barrel ()
 creates L3 AlignModules for SCT barrel
void buildL3Endcaps ()
 creates L3 AlignModules for SCT endcaps
void setSigmas (Trk::AlignModule *mod, DataVector< Trk::AlignPar > *modPars)
 sets sigmas for modules
bool moduleSelected (Trk::AlignModule *mod)
 check wheather module is selected for module pointer
bool moduleSelected (unsigned long long modId)
 check wheather module is selected for module id
void dumpGeometry ()
 print basic geometry info to screen

Private Attributes

const InDetDD::SCT_DetectorManager * m_detManager {nullptr}
 pointer to SCT detector manager
const SCT_ID * m_idHelper {nullptr}
 pointer to SCT detector manager
PublicToolHandle< Trk::IAlignModuleTool > m_alignModuleTool {this, "AlignModuleTool", "Trk::AlignModuleTool/AlignModuleTool"}
 pointer to AlignModuleTool
Trk::AlignModuleList m_alignModuleList
Trk::AlignModuleList m_idHashToAlignModuleMap
std::vector< Trk::AlignModuleList * > m_idHashToAlignModuleMaps {std::vector<Trk::AlignModuleList *>(Trk::AlignModule::NDetectorTypes, nullptr)}
DataVector< DataVector< Trk::AlignPar > > * m_alignParList {nullptr}
DataVector< DataVector< Trk::AlignPar > > * m_fullAlignParList {nullptr}
Gaudi::Property< int > m_alignLevelProp {this, "AlignmentLevel", 1}
 property, copied to m_alignLevel in initialize()
Gaudi::Property< int > m_alignLevelBarrelProp {this, "AlignmentLevelBarrel", -1}
 property, copied to m_alignLevelBarrel in initialize()
Gaudi::Property< int > m_alignLevelEndcapsProp {this, "AlignmentLevelEndcaps", -1}
 property, copied to m_alignLevelEndcaps in initialize()
Gaudi::Property< bool > m_doModuleSelection {this, "doModuleSelection", false}
Gaudi::Property< std::vector< unsigned long long > > m_moduleSelection {this, "ModuleSelection", {}}
Gaudi::Property< bool > m_alignBarrel {this, "AlignBarrel", true}
Gaudi::Property< bool > m_alignEndcaps {this, "AlignEndcaps", true}
Gaudi::Property< bool > m_alignBarrelX {this, "AlignBarrelX", true}
Gaudi::Property< bool > m_alignBarrelY {this, "AlignBarrelY", true}
Gaudi::Property< bool > m_alignBarrelZ {this, "AlignBarrelZ", true}
Gaudi::Property< bool > m_alignBarrelRotX {this, "AlignBarrelRotX", true}
Gaudi::Property< bool > m_alignBarrelRotY {this, "AlignBarrelRotY", true}
Gaudi::Property< bool > m_alignBarrelRotZ {this, "AlignBarrelRotZ", true}
Gaudi::Property< bool > m_alignEndcapX {this, "AlignEndcapX", true}
Gaudi::Property< bool > m_alignEndcapY {this, "AlignEndcapY", true}
Gaudi::Property< bool > m_alignEndcapZ {this, "AlignEndcapZ", true}
Gaudi::Property< bool > m_alignEndcapRotX {this, "AlignEndcapRotX", true}
Gaudi::Property< bool > m_alignEndcapRotY {this, "AlignEndcapRotY", true}
Gaudi::Property< bool > m_alignEndcapRotZ {this, "AlignEndcapRotZ", true}
Gaudi::Property< double > m_sigmaBarrelX {this, "SetSigmaBarrelX", 1.}
Gaudi::Property< double > m_sigmaBarrelY {this, "SetSigmaBarrelY", 1.}
Gaudi::Property< double > m_sigmaBarrelZ {this, "SetSigmaBarrelZ", 1.}
Gaudi::Property< double > m_sigmaBarrelRotX {this, "SetSigmaBarrelRotX", 0.001}
Gaudi::Property< double > m_sigmaBarrelRotY {this, "SetSigmaBarrelRotY", 0.001}
Gaudi::Property< double > m_sigmaBarrelRotZ {this, "SetSigmaBarrelRotZ", 0.001}
Gaudi::Property< double > m_sigmaEndcapX {this, "SetSigmaEndcapX", 1.}
Gaudi::Property< double > m_sigmaEndcapY {this, "SetSigmaEndcapY", 1.}
Gaudi::Property< double > m_sigmaEndcapZ {this, "SetSigmaEndcapZ", 1.}
Gaudi::Property< double > m_sigmaEndcapRotX {this, "SetSigmaEndcapRotX", 0.001}
Gaudi::Property< double > m_sigmaEndcapRotY {this, "SetSigmaEndcapRotY", 0.001}
Gaudi::Property< double > m_sigmaEndcapRotZ {this, "SetSigmaEndcapRotZ", 0.001}
Gaudi::Property< double > m_softcutBarrelX {this, "SetSoftCutBarrelX", 1.}
Gaudi::Property< double > m_softcutBarrelY {this, "SetSoftCutBarrelY", 1.}
Gaudi::Property< double > m_softcutBarrelZ {this, "SetSoftCutBarrelZ", 1.}
Gaudi::Property< double > m_softcutBarrelRotX {this, "SetSoftCutBarrelRotX", 1.}
Gaudi::Property< double > m_softcutBarrelRotY {this, "SetSoftCutBarrelRotY", 1.}
Gaudi::Property< double > m_softcutBarrelRotZ {this, "SetSoftCutBarrelRotZ", 1.}
Gaudi::Property< double > m_softcutEndcapX {this, "SetSoftCutEndcapX", 1.}
Gaudi::Property< double > m_softcutEndcapY {this, "SetSoftCutEndcapY", 1.}
Gaudi::Property< double > m_softcutEndcapZ {this, "SetSoftCutEndcapZ", 1.}
Gaudi::Property< double > m_softcutEndcapRotX {this, "SetSoftCutEndcapRotX", 1.}
Gaudi::Property< double > m_softcutEndcapRotY {this, "SetSoftCutEndcapRotY", 1.}
Gaudi::Property< double > m_softcutEndcapRotZ {this, "SetSoftCutEndcapRotZ", 1.}
Gaudi::Property< bool > m_useOldL2 {this, "UseOldL2", false}
Gaudi::Property< bool > m_dumpGeometry {this, "DumpGeometry", true}
Gaudi::Property< std::string > m_stripDetManagerName {this,"StripDetectorManager","SCT","Name of the Strip Detector Manager to attempt to retrieve"}

Detailed Description

Definition at line 44 of file SCTGeometryManagerTool.h.

Constructor & Destructor Documentation

◆ ~SCTGeometryManagerTool()

InDet::SCTGeometryManagerTool::~SCTGeometryManagerTool ( )
virtual

Definition at line 30 of file SCTGeometryManagerTool.cxx.

31 {
32 ATH_MSG_DEBUG("deleting alignModuleList");
33 for (int i=0;i<(int)m_alignModuleList.size();i++)
34 delete m_alignModuleList[i];
35 m_alignModuleList.clear();
36
37 ATH_MSG_DEBUG("deleting fullAlignParList");
38 delete m_fullAlignParList;
39 ATH_MSG_DEBUG("deleting alignParList");
40 delete m_alignParList;
41 }
#define ATH_MSG_DEBUG(x,...)
DataVector< DataVector< Trk::AlignPar > > * m_fullAlignParList
DataVector< DataVector< Trk::AlignPar > > * m_alignParList

Member Function Documentation

◆ addModuleParameters()

void InDet::SCTGeometryManagerTool::addModuleParameters ( Trk::AlignModule * module,
DataVector< DataVector< Trk::AlignPar > > * allFullModPars,
DataVector< DataVector< Trk::AlignPar > > * allActiveModPars )

adds alignment parameters for the module checks for active parameters and calls setSigmas()

Definition at line 1162 of file SCTGeometryManagerTool.cxx.

1163 {
1164 // prepare all parameters
1165 DataVector<Trk::AlignPar> * fullModPars = new DataVector<Trk::AlignPar>(SG::OWN_ELEMENTS);
1166 fullModPars->push_back(new Trk::AlignPar(module,Trk::AlignModule::TransX));
1167 fullModPars->push_back(new Trk::AlignPar(module,Trk::AlignModule::TransY));
1168 fullModPars->push_back(new Trk::AlignPar(module,Trk::AlignModule::TransZ));
1169 fullModPars->push_back(new Trk::AlignPar(module,Trk::AlignModule::RotX));
1170 fullModPars->push_back(new Trk::AlignPar(module,Trk::AlignModule::RotY));
1171 fullModPars->push_back(new Trk::AlignPar(module,Trk::AlignModule::RotZ));
1172
1173 // set sigmas
1174 setSigmas(module,fullModPars);
1175
1176 // select active parameters based on jobOption properties
1177 DataVector<Trk::AlignPar> * activeModPars = new DataVector<Trk::AlignPar>(SG::VIEW_ELEMENTS);
1178 for(unsigned int ipar=0;ipar<fullModPars->size();++ipar) {
1179
1180 Identifier AlimodID = module->identify();
1181 Identifier modID = ((module->detElementCollection(Trk::AlignModule::SCT))->at(0))->identify();
1182
1183 if(m_idHelper->is_barrel(modID)) {
1184 ATH_MSG_DEBUG("SCT barrel module with id "<<AlimodID);
1185 if( (fullModPars->at(ipar)->paramType() == Trk::AlignModule::TransX && m_alignBarrelX)
1186 || (fullModPars->at(ipar)->paramType() == Trk::AlignModule::TransY && m_alignBarrelY)
1187 || (fullModPars->at(ipar)->paramType() == Trk::AlignModule::TransZ && m_alignBarrelZ)
1188 || (fullModPars->at(ipar)->paramType() == Trk::AlignModule::RotX && m_alignBarrelRotX)
1189 || (fullModPars->at(ipar)->paramType() == Trk::AlignModule::RotY && m_alignBarrelRotY)
1190 || (fullModPars->at(ipar)->paramType() == Trk::AlignModule::RotZ && m_alignBarrelRotZ) ) {
1191 ATH_MSG_DEBUG("parameter type "<<fullModPars->at(ipar)->paramType()<<" is now active");
1192 activeModPars->push_back(fullModPars->at(ipar));
1193 }
1194 else
1195 ATH_MSG_DEBUG("parameter type "<<fullModPars->at(ipar)->paramType()<<" is NOT active");
1196 }
1197 else {
1198 ATH_MSG_DEBUG("SCT endcap module with id "<<AlimodID);
1199 if( (fullModPars->at(ipar)->paramType() == Trk::AlignModule::TransX && m_alignEndcapX)
1200 || (fullModPars->at(ipar)->paramType() == Trk::AlignModule::TransY && m_alignEndcapY)
1201 || (fullModPars->at(ipar)->paramType() == Trk::AlignModule::TransZ && m_alignEndcapZ)
1202 || (fullModPars->at(ipar)->paramType() == Trk::AlignModule::RotX && m_alignEndcapRotX)
1203 || (fullModPars->at(ipar)->paramType() == Trk::AlignModule::RotY && m_alignEndcapRotY)
1204 || (fullModPars->at(ipar)->paramType() == Trk::AlignModule::RotZ && m_alignEndcapRotZ) ) {
1205 ATH_MSG_DEBUG("parameter type "<<fullModPars->at(ipar)->paramType()<<" is now active");
1206 activeModPars->push_back(fullModPars->at(ipar));
1207 }
1208 else
1209 ATH_MSG_DEBUG("parameter type "<<fullModPars->at(ipar)->paramType()<<" is NOT active");
1210 }
1211 }
1212
1213 // now add parameters to the list
1214 allFullModPars->push_back(fullModPars);
1215 allActiveModPars->push_back(activeModPars);
1216 }
const T * at(size_type n) const
Access an element, as an rvalue.
value_type push_back(value_type pElem)
Add an element to the end of the collection.
size_type size() const noexcept
Returns the number of elements in the collection.
Gaudi::Property< bool > m_alignEndcapRotX
void setSigmas(Trk::AlignModule *mod, DataVector< Trk::AlignPar > *modPars)
sets sigmas for modules
Gaudi::Property< bool > m_alignEndcapRotZ
Gaudi::Property< bool > m_alignEndcapY
Gaudi::Property< bool > m_alignEndcapZ
const SCT_ID * m_idHelper
pointer to SCT detector manager
Gaudi::Property< bool > m_alignEndcapRotY
Gaudi::Property< bool > m_alignEndcapX
@ OWN_ELEMENTS
this data object owns its elements
@ VIEW_ELEMENTS
this data object is a view, it does not own its elmts

◆ buildGeometry()

void InDet::SCTGeometryManagerTool::buildGeometry ( )

builds geometry for SCT alignment

Definition at line 215 of file SCTGeometryManagerTool.cxx.

216 {
217 ATH_MSG_INFO("Preparing the SCT geometry");
218
219 if(m_alignLevel == 0)
220 buildL0();
221 else if (m_alignLevel == 2 && m_useOldL2)
222 buildL2Old();
223 else {
224
225 if(m_alignBarrel)
226 switch(m_alignLevelBarrel) {
227 case 1:
229 break;
230 case 2:
232 break;
233 case 27:
235 break;
236 case 3:
238 break;
239 default:
240 break;
241 }
242
244 switch(m_alignLevelEndcaps) {
245 case 1:
247 break;
248 case 2:
250 break;
251 case 25:
253 break;
254 case 3:
256 break;
257 default:
258 break;
259 }
260
261 }
262 }
#define ATH_MSG_INFO(x,...)
void buildL2Endcaps()
creates L2 AlignModules for SCT endcaps
void buildL3Barrel()
creates L3 AlignModules for SCT barrel
Gaudi::Property< bool > m_alignBarrel
void buildL3Endcaps()
creates L3 AlignModules for SCT endcaps
void buildL1Barrel()
creates L1 AlignModules for SCT barrel
Gaudi::Property< bool > m_alignEndcaps
void buildL25Endcaps()
creates L25 AlignModules for SCT endcaps
void buildL2Old()
creates L2 AlignModules for the full Pixel in the ordering equal to the old code
void buildL27Barrel()
creates L27 AlignModules for SCT barrel
void buildL0()
creates L0 AlignModules for SCT
void buildL2Barrel()
creates L2 AlignModules for SCT barrel
void buildL1Endcaps()
creates L1 AlignModules for SCT endcaps

◆ buildL0()

void InDet::SCTGeometryManagerTool::buildL0 ( )
private

creates L0 AlignModules for SCT

Definition at line 265 of file SCTGeometryManagerTool.cxx.

266 {
267 ATH_MSG_INFO("Preparing the SCT geometry for L0: the whole SCT");
268 // ===================================================
269 // Level 0 is just one module containing the whole SCT
270
271 Trk::AlignModule * sct = new Trk::AlignModule(this);
272 sct->setIdHash(getNextIDHash());
273 sct->setName("SCT");
274
275 // use the identifier of the SCT barrel for the whole SCT at L0
276 sct->setIdentifier(m_idHelper->wafer_id(0,0,0,0,0));
277
278 ATH_MSG_DEBUG("Created module "<<sct->name()<<" idHash: "<<sct->identifyHash()<<" identifier: "<<sct->identify());
279
280 // for L0 alignment the alignment frame is equal to the global frame
281 // and since the SCT detector element positions are also stored
282 // in the global frame in DB, transform is identity
283 const Amg::Transform3D transform = Amg::Transform3D::Identity();
284
285 // get maximum number of elements from the helper
286 unsigned int sctmaxHash = m_idHelper->wafer_hash_max();
287 ATH_MSG_DEBUG("maxHash for the SCT: "<<sctmaxHash);
288
289 if(!m_idHashToAlignModuleMapsPtr->at(Trk::AlignModule::SCT))
290 m_idHashToAlignModuleMapsPtr->at(Trk::AlignModule::SCT) = new Trk::AlignModuleList((size_t)(sctmaxHash),nullptr);
291 Trk::AlignModuleList * sctIdHashMap = m_idHashToAlignModuleMapsPtr->at(Trk::AlignModule::SCT);
292
293 // ================================================================
294 // loop over SCT elements and add them to respective alignModules
295 // ================================================================
296 for (unsigned int index = 0; index < sctmaxHash; index++) {
297 IdentifierHash idHash = index;
298 Identifier id = m_idHelper->wafer_id(idHash);
299
300 ATH_MSG_DEBUG(" SCT DetectorElement idhash: "<<index);
301 ATH_MSG_DEBUG(" DetectorElement id: "<<id);
302
303 // get the element via hash
304 const SiDetectorElement * element = m_detManager->getDetectorElement(id);
305 if (element) {
306 // add element to respective AlignModule
307 // add to the sct barrel structure
308 if(msgLvl(MSG::DEBUG)) {
309 if (m_idHelper->is_barrel(id))
310 msg(MSG::DEBUG)<<"... SCT barrel element"<<endmsg;
311 else
312 msg(MSG::DEBUG)<<"... SCT endcap element"<<endmsg;
313 }
314 sct->addDetElement(Trk::AlignModule::SCT,element,transform);
315
316 // and fill the corresponding map
317 (*sctIdHashMap)[idHash] = sct;
318 }
319 else
320 ATH_MSG_DEBUG("No SCT detector with id: "<<id);
321 }
322
323 // add created module to the geometry
324 m_alignModuleListPtr->push_back(sct);
325
326 ATH_MSG_DEBUG("SCT L0 module successfully added to the geometry");
327 }
#define endmsg
const InDetDD::SCT_DetectorManager * m_detManager
pointer to SCT detector manager
void setIdHash(IdentifierHash id)
Definition AlignModule.h:94
Identifier identify() const
Definition AlignModule.h:98
void setIdentifier(Identifier identifier)
Set and return identifier of module.
Definition AlignModule.h:97
const std::string & name() const
Definition AlignModule.h:90
void setName(const std::string &name)
Set and return name of align module (i.e.
Definition AlignModule.h:89
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...
IdentifierHash identifyHash() const
Set and return index of module, used by alignment classes to keep track of order of align module.
Definition AlignModule.h:93
Eigen::Affine3d Transform3D
str index
Definition DeMoScan.py:362
std::vector< AlignModule * > AlignModuleList
MsgStream & msg
Definition testRead.cxx:32

◆ buildL1Barrel()

void InDet::SCTGeometryManagerTool::buildL1Barrel ( )
private

creates L1 AlignModules for SCT barrel

Definition at line 330 of file SCTGeometryManagerTool.cxx.

331 {
332 // ===========================
333 // BARREL
334 // ===========================
335 ATH_MSG_INFO("Preparing the SCT Barrel geometry for L1: barrel + 2 endcaps");
336
337 // ========================================
338 // Level 1 is whole SCT barrel
339
340 // get maximum number of elements from the helper
341 unsigned int maxHash = m_idHelper->wafer_hash_max();
342 ATH_MSG_DEBUG("maxHash for the SCT "<<maxHash);
343
344 if(!m_idHashToAlignModuleMapsPtr->at(Trk::AlignModule::SCT))
345 m_idHashToAlignModuleMapsPtr->at(Trk::AlignModule::SCT) = new Trk::AlignModuleList((size_t)(maxHash),nullptr);
346 Trk::AlignModuleList * sctIdHashMap = m_idHashToAlignModuleMapsPtr->at(Trk::AlignModule::SCT);
347
348 // use the 'real' identifier of the Pixel
349 // build barrel module
350 Trk::AlignModule * mod = new Trk::AlignModule(this);
351 mod->setIdHash(getNextIDHash());
352 mod->setName("SCT Barrel");
353 mod->setIdentifier(m_idHelper->wafer_id(0,0,0,0,0));
354
355 // check if selected
356 if(!m_alignBarrel || !moduleSelected(mod)) {
357 ATH_MSG_DEBUG("Module "<<mod->name()<<" NOT selected");
358 delete mod;
359 return;
360 }
361
362 // fill module with detector elements
363 ATH_MSG_DEBUG("Building module "<<mod->name());
364
365 const Amg::Transform3D transform = Amg::Transform3D::Identity();
366
367 for (int iLayer = 0; iLayer < m_detManager->numerology().numLayers(); iLayer++) {
368 if (!m_detManager->numerology().useLayer(iLayer))
369 ATH_MSG_INFO(" Layer "<<iLayer<<" not present");
370
371 for (int iPhi = 0; iPhi < m_detManager->numerology().numPhiModulesForLayer(iLayer); iPhi++) {
372 ATH_MSG_DEBUG("iPhi "<<iPhi);
373 for (int iEta = m_detManager->numerology().beginEtaModuleForLayer(iLayer); iEta < m_detManager->numerology().endEtaModuleForLayer(iLayer); iEta++) {
374 ATH_MSG_DEBUG("iEta "<<iEta);
375
376 if (!iEta && m_detManager->numerology().skipEtaZeroForLayer(iLayer))
377 // iEta=0 is not defined for the SCT
378 continue;
379
380 for (int is = 0; is < 2; is++) { // module side
381 const SiDetectorElement* element = m_detManager->getDetectorElement(0, iLayer, iPhi, iEta, is);
382
383 if (element) {
384 // get element location for debugging
385 // HepGeom::Point3D<double> center = element->transform() * HepGeom::Point3D<double>();
386 // ATH_MSG_DEBUG(" SCTDetectorElement id: " << id << " with center = " << center);
387 // ATH_MSG_DEBUG(" Is Barrel: "<< m_idHelper->is_barrel(id));
388
389 // add element to the AlignModule
390 mod->addDetElement(Trk::AlignModule::SCT,element,transform);
391 // and fill the corresponding map
392 (*sctIdHashMap)[element->identifyHash()] = mod;
393 }
394 }
395 }
396 }
397 }
398
399 m_alignModuleListPtr->push_back(mod);
400
401 ATH_MSG_DEBUG("SCT Barrel successfully added to the geometry");
402 }
virtual IdentifierHash identifyHash() const override final
identifier hash (inline)
bool moduleSelected(Trk::AlignModule *mod)
check wheather module is selected for module pointer
constexpr unsigned int numLayers()
Definition HIEventDefs.h:23
@ iPhi
Definition ParamDefs.h:47
setScale setgFexType iEta

◆ buildL1Endcaps()

void InDet::SCTGeometryManagerTool::buildL1Endcaps ( )
private

creates L1 AlignModules for SCT endcaps

Definition at line 405 of file SCTGeometryManagerTool.cxx.

406 {
407 // ===========================
408 // ENDCAPs
409 // ===========================
410 ATH_MSG_INFO("Preparing the SCT Endcap geometry for L1: 2 endcaps");
411
412 // ========================================
413 // Level 1 is 2 SCT endcaps
414
415 // get maximum number of elements from the helper
416 unsigned int maxHash = m_idHelper->wafer_hash_max();
417 ATH_MSG_DEBUG("maxHash for the SCT "<<maxHash);
418
419 if(!m_idHashToAlignModuleMapsPtr->at(Trk::AlignModule::SCT))
420 m_idHashToAlignModuleMapsPtr->at(Trk::AlignModule::SCT) = new Trk::AlignModuleList((size_t)(maxHash),nullptr);
421 Trk::AlignModuleList * sctIdHashMap = m_idHashToAlignModuleMapsPtr->at(Trk::AlignModule::SCT);
422
423 for (int iEndcapIndex = 0; iEndcapIndex < m_detManager->numerology().numEndcaps(); iEndcapIndex++) {
424 int iSide = m_detManager->numerology().endcapId(iEndcapIndex);
425
426 Trk::AlignModule * mod = new Trk::AlignModule(this);
427 mod->setIdHash(getNextIDHash());
428 mod->setIdentifier(m_idHelper->wafer_id(iSide,0,0,0,0));
429 if(iEndcapIndex == 0)
430 mod->setName("SCT EndCap A");
431 else
432 mod->setName("SCT EndCap C");
433
434 if(!m_alignEndcaps || !moduleSelected(mod)) {
435 ATH_MSG_DEBUG("Module "<<mod->name()<<" NOT selected");
436 delete mod;
437 continue;
438 }
439
440 ATH_MSG_DEBUG("Building module "<<mod->name());
441
442 const Amg::Transform3D transform = Amg::Transform3D::Identity();
443
444 for (int iWheel = 0; iWheel < m_detManager->numerology().numDisks(); iWheel++) {
445 if (!m_detManager->numerology().useDisk(iWheel))
446 ATH_MSG_INFO(" Disk "<<iWheel<<" not present");
447
448 for (int iEta = 0; iEta < m_detManager->numerology().numRingsForDisk(iWheel); iEta++) {
449 ATH_MSG_DEBUG("iEta "<<iEta);
450 for (int iPhi = 0; iPhi < m_detManager->numerology().numPhiModulesForDiskRing(iWheel,iEta); iPhi++) {
451 ATH_MSG_DEBUG("iPhi "<<iPhi);
452 for(int is=0; is<2; is++) { // module side
453
454 const SiDetectorElement * element = m_detManager->getDetectorElement(iSide, iWheel, iPhi, iEta, is);
455 if (element) {
456 // get element location for debugging
457 // HepGeom::Point3D<double> center = element->transform() * HepGeom::Point3D<double>();
458 // ATH_MSG_DEBUG(" SCTDetectorElement id: " << id << " with center = " << center);
459 // ATH_MSG_DEBUG(" Is Barrel: "<< m_idHelper->is_barrel(id));
460
461 // add element to the AlignModule
462 mod->addDetElement(Trk::AlignModule::SCT,element,transform);
463 // and fill the corresponding map
464 (*sctIdHashMap)[element->identifyHash()] = mod;
465 }
466 }
467 }
468 }
469 }
470
471 // for endcap we move the CoG
472 Amg::Translation3D translation(mod->centerOfGravity());
473 ATH_MSG_DEBUG("Endcap:" << iSide << " , CoG (" << translation.x() << " , " << translation.y() << " , " << translation.z() << " ) " );
474 Amg::Transform3D localtoglobal = translation * Amg::RotationMatrix3D::Identity();
475
476 mod->setGlobalFrameToAlignFrameTransform(localtoglobal.inverse());
477
478 m_alignModuleListPtr->push_back(mod);
479 }
480
481 ATH_MSG_DEBUG("SCT End-caps successfully added to the geometry");
482 }
Eigen::Translation< double, 3 > Translation3D

◆ buildL25Endcaps()

void InDet::SCTGeometryManagerTool::buildL25Endcaps ( )
private

creates L25 AlignModules for SCT endcaps

Definition at line 733 of file SCTGeometryManagerTool.cxx.

734 {
735 // ========================================
736 // END CAPS
737 ATH_MSG_INFO("Preparing the SCT Endcap geometry for L25: 2 x 22 rings");
738
739 if(!m_alignEndcaps) {
740 ATH_MSG_DEBUG("Not aligning endcaps");
741 return;
742 }
743
744 // ========================================
745 // get all modules for Level 2 alignment of the Endcaps
746 // 2 x 22 SCT Endcap rings
747
748 const Amg::Transform3D transform = Amg::Transform3D::Identity();
749
750 unsigned int maxHash = m_idHelper->wafer_hash_max();
751 ATH_MSG_DEBUG("maxHash for the SCT "<<maxHash);
752
753 if(!m_idHashToAlignModuleMapsPtr->at(Trk::AlignModule::SCT))
754 m_idHashToAlignModuleMapsPtr->at(Trk::AlignModule::SCT) = new Trk::AlignModuleList((size_t)(maxHash),nullptr);
755 Trk::AlignModuleList * sctIdHashMap = m_idHashToAlignModuleMapsPtr->at(Trk::AlignModule::SCT);
756
757 for (int iEndcapIndex = 0; iEndcapIndex < m_detManager->numerology().numEndcaps(); iEndcapIndex++) {
758 int iSide = m_detManager->numerology().endcapId(iEndcapIndex);
759 for (int iWheel = 0; iWheel < m_detManager->numerology().numDisks(); iWheel++) {
760 if (!m_detManager->numerology().useDisk(iWheel))
761 ATH_MSG_INFO(" Disk "<<iWheel<<" not present");
762 for (int iEta = 0; iEta < m_detManager->numerology().numRingsForDisk(iWheel); iEta++) {
763 ATH_MSG_DEBUG("iEta "<<iEta);
764
765 Trk::AlignModule * mod = new Trk::AlignModule(this);
766 mod->setIdHash(getNextIDHash());
767 mod->setIdentifier(m_idHelper->wafer_id(iSide,iWheel,iEta,0,0));
768
769 std::stringstream name;
770 if(iEndcapIndex == 0)
771 name <<"SCT/EndcapA/Disk_"<<iWheel<<"/Ring_"<<iEta;
772 else
773 name <<"SCT/EndcapC/Disk_"<<iWheel<<"/Ring_"<<iEta;
774 mod->setName(name.str());
775
776 if(!moduleSelected(mod)) {
777 ATH_MSG_DEBUG("Module "<<mod->name()<<" NOT selected");
778 delete mod;
779 continue;
780 }
781
782 ATH_MSG_DEBUG("Building module "<<mod->name());
783
784 for (int iPhi = 0; iPhi < m_detManager->numerology().numPhiModulesForDiskRing(iWheel,iEta); iPhi++) {
785 ATH_MSG_DEBUG("iPhi "<<iPhi);
786 for(int is=0; is<2; is++) { // module side
787
788 const SiDetectorElement * element = m_detManager->getDetectorElement(iSide, iWheel, iPhi, iEta, is);
789 if (element) {
790 // get element location for debugging
791 // HepGeom::Point3D<double> center = element->transform() * HepGeom::Point3D<double>();
792 // ATH_MSG_DEBUG(" SCTDetectorElement id: " << id << " with center = " << center);
793 // ATH_MSG_DEBUG(" Is Barrel: "<< m_idHelper->is_barrel(id));
794
795 // add element to the AlignModule
796 mod->addDetElement(Trk::AlignModule::SCT,element,transform);
797 // and fill the corresponding map
798 (*sctIdHashMap)[element->identifyHash()] = mod;
799 }
800 }
801 }
802
803 // for endcap we move the CoG
804
805
806
807 Amg::Translation3D translation(mod->centerOfGravity());
808 ATH_MSG_DEBUG("Endcap:" << iSide << " , disk: " << iWheel << " , CoG (" << translation.x() << " , " << translation.y() << " , " << translation.z() << " ) " );
809 Amg::Transform3D localtoglobal = translation * Amg::RotationMatrix3D::Identity();
810 mod->setGlobalFrameToAlignFrameTransform(localtoglobal.inverse());
811
812 m_alignModuleListPtr->push_back(mod);
813 }
814 }
815 }
816 }

◆ buildL27Barrel()

void InDet::SCTGeometryManagerTool::buildL27Barrel ( )
private

creates L27 AlignModules for SCT barrel

Definition at line 555 of file SCTGeometryManagerTool.cxx.

556 {
557 // ========================================
558 // BARREL
559 ATH_MSG_INFO("Preparing the SCT Barrel geometry for L27: 176 staves (ladders)");
560
561 if(!m_alignBarrel) {
562 ATH_MSG_DEBUG("Not aligning barrel");
563 return;
564 }
565
566 // ========================================
567 // get all modules for Level 27 alignment of the Barrel
568 // 176 staves (ladders)
569
570 const Amg::Transform3D transform = Amg::Transform3D::Identity();
571
572 unsigned int maxHash = m_idHelper->wafer_hash_max();
573 ATH_MSG_DEBUG("maxHash for the SCT "<<maxHash);
574
575 if(!m_idHashToAlignModuleMapsPtr->at(Trk::AlignModule::SCT))
576 m_idHashToAlignModuleMapsPtr->at(Trk::AlignModule::SCT) = new Trk::AlignModuleList((size_t)(maxHash),nullptr);
577 Trk::AlignModuleList * sctIdHashMap = m_idHashToAlignModuleMapsPtr->at(Trk::AlignModule::SCT);
578
579 for (int iLayer = 0; iLayer < m_detManager->numerology().numLayers(); iLayer++) {
580 if (!m_detManager->numerology().useLayer(iLayer))
581 ATH_MSG_INFO(" Layer "<<iLayer<<" not present");
582 for (int iPhi = 0; iPhi < m_detManager->numerology().numPhiModulesForLayer(iLayer); iPhi++) {
583 ATH_MSG_DEBUG("iPhi "<<iPhi);
584
585 // create the AlignModule
586 Trk::AlignModule * mod = new Trk::AlignModule(this);
587 mod->setIdHash(getNextIDHash());
588
589 // even though there is no iEta=0 module for SCT barrel, the
590 // Identifier is still valid so we use it for the stave
591 mod->setIdentifier(m_idHelper->wafer_id(0, iLayer, iPhi, 0, 0));
592
593 std::stringstream name;
594 name <<"SCT/Barrel/Layer_"<<iLayer<<"/PhiStave_"<<iPhi;
595 mod->setName(name.str());
596
597 if(!moduleSelected(mod)) {
598 ATH_MSG_DEBUG("Module "<<mod->name()<<" NOT selected");
599 delete mod;
600 continue;
601 }
602
603 ATH_MSG_DEBUG("Building module "<<mod->name());
604
605 // rotation of the stave alignment frame
607
608 for (int iEta = m_detManager->numerology().beginEtaModuleForLayer(iLayer); iEta < m_detManager->numerology().endEtaModuleForLayer(iLayer); iEta++) {
609 ATH_MSG_DEBUG("iEta "<<iEta);
610 if (!iEta && m_detManager->numerology().skipEtaZeroForLayer(iLayer))
611 // iEta=0 is not defined for the SCT
612 continue;
613 for (int is = 0; is < 2; is++) { // module side
614
615 const SiDetectorElement * element = m_detManager->getDetectorElement(0, iLayer, iPhi, iEta, is);
616 if (element) {
617 // get element location for debugging
618 // HepGeom::Point3D<double> center = element->transform() * HepGeom::Point3D<double>();
619 // ATH_MSG_DEBUG(" SCTDetectorElement id: " << id << " with center = " << center);
620 // ATH_MSG_DEBUG(" Is Barrel: "<< m_idHelper->is_barrel(id));
621
622 // add element to the AlignModule
623 mod->addDetElement(Trk::AlignModule::SCT,element,transform);
624 // and fill the corresponding map
625 (*sctIdHashMap)[element->identifyHash()] = mod;
626 // for the stave alignment frame rotation we use the one of the iEta=1
627 // non-stereo side (which is the module local frame)
628 if(iEta==1 && !element->isStereo())
629 rotation = element->moduleTransform().rotation();
630 }
631 }
632 }
633
634 // we set the alignment frame to be the CoG of the stave
635 // with rotation being the one of the iEta=1 module set above
636 Amg::Translation3D translation(mod->centerOfGravity());
637 Amg::Transform3D localToGlobal = translation * rotation;
638
639
640 ATH_MSG_DEBUG("Prepared local to global transform :");
641 ATH_MSG_DEBUG(" - translation: "<<localToGlobal.translation().x()<<" "<<localToGlobal.translation().y()<<" "<<localToGlobal.translation().z());
642 ATH_MSG_DEBUG(" - rotation:");
643 ATH_MSG_DEBUG(" "<<localToGlobal.rotation()(0,0)<<" "<<localToGlobal.rotation()(0,1)<<" "<<localToGlobal.rotation()(0,2));
644 ATH_MSG_DEBUG(" "<<localToGlobal.rotation()(1,0)<<" "<<localToGlobal.rotation()(1,1)<<" "<<localToGlobal.rotation()(1,2));
645 ATH_MSG_DEBUG(" "<<localToGlobal.rotation()(2,0)<<" "<<localToGlobal.rotation()(2,1)<<" "<<localToGlobal.rotation()(2,2));
646
647 mod->setGlobalFrameToAlignFrameTransform(localToGlobal.inverse());
648
649 m_alignModuleListPtr->push_back(mod);
650 }
651 }
652 }
bool isStereo() const
Check if it is the stereo side (useful for SCT).
const Amg::Transform3D & moduleTransform() const
Module to global frame transform.
Eigen::Matrix< double, 3, 3 > RotationMatrix3D

◆ buildL2Barrel()

void InDet::SCTGeometryManagerTool::buildL2Barrel ( )
private

creates L2 AlignModules for SCT barrel

Definition at line 485 of file SCTGeometryManagerTool.cxx.

486 {
487 // ========================================
488 // BARREL
489 ATH_MSG_INFO("Preparing the SCT Barrel geometry for L2: 4 layers");
490
491 // ========================================
492 // get all modules for Level 2 alignment of the Barrel
493 // Level 2 is 4 SCT barrel layers
494
495 const Amg::Transform3D transform = Amg::Transform3D::Identity();
496
497 unsigned int maxHash = m_idHelper->wafer_hash_max();
498 ATH_MSG_DEBUG("maxHash for the SCT "<<maxHash);
499
500 if(!m_idHashToAlignModuleMapsPtr->at(Trk::AlignModule::SCT))
501 m_idHashToAlignModuleMapsPtr->at(Trk::AlignModule::SCT) = new Trk::AlignModuleList((size_t)(maxHash),nullptr);
502 Trk::AlignModuleList * sctIdHashMap = m_idHashToAlignModuleMapsPtr->at(Trk::AlignModule::SCT);
503
504 for (int iLayer = 0; iLayer < m_detManager->numerology().numLayers(); iLayer++) {
505 if (!m_detManager->numerology().useLayer(iLayer))
506 ATH_MSG_INFO(" Layer "<<iLayer<<" not present");
507
508 // create the AlignModule
509 Trk::AlignModule * mod = new Trk::AlignModule(this);
510 mod->setIdHash(getNextIDHash());
511 mod->setIdentifier(m_idHelper->wafer_id(0, iLayer, 0, 0, 0));
512
513 std::stringstream name;
514 name <<"SCT/Barrel/Layer_"<<iLayer;
515 mod->setName(name.str());
516
517 if(!m_alignBarrel || !moduleSelected(mod)) {
518 ATH_MSG_DEBUG("Module "<<mod->name()<<" NOT selected");
519 delete mod;
520 continue;
521 }
522
523 ATH_MSG_DEBUG("Building module "<<mod->name());
524
525 for (int iPhi = 0; iPhi < m_detManager->numerology().numPhiModulesForLayer(iLayer); iPhi++) {
526 ATH_MSG_DEBUG("iPhi "<<iPhi);
527 for (int iEta = m_detManager->numerology().beginEtaModuleForLayer(iLayer); iEta < m_detManager->numerology().endEtaModuleForLayer(iLayer); iEta++) {
528 ATH_MSG_DEBUG("iEta "<<iEta);
529 if (!iEta && m_detManager->numerology().skipEtaZeroForLayer(iLayer))
530 // iEta=0 is not defined for the SCT
531 continue;
532 for (int is = 0; is < 2; is++) { // module side
533
534 const SiDetectorElement * element = m_detManager->getDetectorElement(0, iLayer, iPhi, iEta, is);
535 if (element) {
536 // get element location for debugging
537 // HepGeom::Point3D<double> center = element->transform() * HepGeom::Point3D<double>();
538 // ATH_MSG_DEBUG(" SCTDetectorElement id: " << id << " with center = " << center);
539 // ATH_MSG_DEBUG(" Is Barrel: "<< m_idHelper->is_barrel(id));
540
541 // add element to the AlignModule
542 mod->addDetElement(Trk::AlignModule::SCT,element,transform);
543 // and fill the corresponding map
544 (*sctIdHashMap)[element->identifyHash()] = mod;
545 }
546 }
547 }
548 }
549
550 m_alignModuleListPtr->push_back(mod);
551 }
552 }

◆ buildL2Endcaps()

void InDet::SCTGeometryManagerTool::buildL2Endcaps ( )
private

creates L2 AlignModules for SCT endcaps

Definition at line 655 of file SCTGeometryManagerTool.cxx.

656 {
657 // ========================================
658 // END CAPS
659 ATH_MSG_INFO("Preparing the SCT Endcap geometry for L2: 2 x 9 disks");
660
661 // ========================================
662 // get all modules for Level 2 alignment of the Endcaps
663 // Level 2 is 2 x 9 SCT Endcap disks
664
665 const Amg::Transform3D transform = Amg::Transform3D::Identity();
666
667 unsigned int maxHash = m_idHelper->wafer_hash_max();
668 ATH_MSG_DEBUG("maxHash for the SCT "<<maxHash);
669
670 if(!m_idHashToAlignModuleMapsPtr->at(Trk::AlignModule::SCT))
671 m_idHashToAlignModuleMapsPtr->at(Trk::AlignModule::SCT) = new Trk::AlignModuleList((size_t)(maxHash),nullptr);
672 Trk::AlignModuleList * sctIdHashMap = m_idHashToAlignModuleMapsPtr->at(Trk::AlignModule::SCT);
673
674 for (int iEndcapIndex = 0; iEndcapIndex < m_detManager->numerology().numEndcaps(); iEndcapIndex++) {
675 int iSide = m_detManager->numerology().endcapId(iEndcapIndex);
676 for (int iWheel = 0; iWheel < m_detManager->numerology().numDisks(); iWheel++) {
677 if (!m_detManager->numerology().useDisk(iWheel))
678 ATH_MSG_INFO(" Disk "<<iWheel<<" not present");
679
680 Trk::AlignModule * mod = new Trk::AlignModule(this);
681 mod->setIdHash(getNextIDHash());
682 mod->setIdentifier(m_idHelper->wafer_id(iSide,iWheel,0,0,0));
683
684 std::stringstream name;
685 if(iEndcapIndex == 0)
686 name <<"SCT/EndcapA/Disk_" << iWheel;
687 else
688 name <<"SCT/EndcapC/Disk_" << iWheel;
689 mod->setName(name.str());
690
691 if(!m_alignEndcaps || !moduleSelected(mod)) {
692 ATH_MSG_DEBUG("Module "<<mod->name()<<" NOT selected");
693 delete mod;
694 continue;
695 }
696
697 ATH_MSG_DEBUG("Building module "<<mod->name());
698
699 for (int iEta = 0; iEta < m_detManager->numerology().numRingsForDisk(iWheel); iEta++) {
700 ATH_MSG_DEBUG("iEta "<<iEta);
701 for (int iPhi = 0; iPhi < m_detManager->numerology().numPhiModulesForDiskRing(iWheel,iEta); iPhi++) {
702 ATH_MSG_DEBUG("iPhi "<<iPhi);
703 for(int is=0; is<2; is++) { // module side
704
705 const SiDetectorElement * element = m_detManager->getDetectorElement(iSide, iWheel, iPhi, iEta, is);
706 if (element) {
707 // get element location for debugging
708 // HepGeom::Point3D<double> center = element->transform() * HepGeom::Point3D<double>();
709 // ATH_MSG_DEBUG(" SCTDetectorElement id: " << id << " with center = " << center);
710 // ATH_MSG_DEBUG(" Is Barrel: "<< m_idHelper->is_barrel(id));
711
712 // add element to the AlignModule
713 mod->addDetElement(Trk::AlignModule::SCT,element,transform);
714 // and fill the corresponding map
715 (*sctIdHashMap)[element->identifyHash()] = mod;
716 }
717 }
718 }
719 }
720
721 // for endcap we move the CoG
722 Amg::Translation3D translation(mod->centerOfGravity());
723 ATH_MSG_DEBUG("Endcap:" << iSide << " , disk: " << iWheel << " , CoG (" << translation.x() << " , " << translation.y() << " , " << translation.z() << " ) " );
724 Amg::Transform3D localtoglobal = translation * Amg::RotationMatrix3D::Identity();
725 mod->setGlobalFrameToAlignFrameTransform(localtoglobal.inverse());
726
727 m_alignModuleListPtr->push_back(mod);
728 }
729 }
730 }

◆ buildL2Old()

void InDet::SCTGeometryManagerTool::buildL2Old ( )
private

creates L2 AlignModules for the full Pixel in the ordering equal to the old code

Definition at line 819 of file SCTGeometryManagerTool.cxx.

820 {
821 ATH_MSG_INFO("Preparing the old SCT Barrel geometry for L2: 4 barrel layers + 2 x 9 endcap disks");
822
823 const Amg::Transform3D transform = Amg::Transform3D::Identity();
824
825 unsigned int maxHash = m_idHelper->wafer_hash_max();
826 ATH_MSG_DEBUG("maxHash for the SCT "<<maxHash);
827
828 if(!m_idHashToAlignModuleMapsPtr->at(Trk::AlignModule::SCT))
829 m_idHashToAlignModuleMapsPtr->at(Trk::AlignModule::SCT) = new Trk::AlignModuleList((size_t)(maxHash),nullptr);
830 Trk::AlignModuleList * sctIdHashMap = m_idHashToAlignModuleMapsPtr->at(Trk::AlignModule::SCT);
831
832 // first endcaap C
833 int iEndcapIndex = 1;
834 int iSide = m_detManager->numerology().endcapId(iEndcapIndex);
835 for (int iWheel = 0; iWheel < m_detManager->numerology().numDisks(); iWheel++) {
836 if (!m_detManager->numerology().useDisk(iWheel))
837 ATH_MSG_INFO(" Disk "<<iWheel<<" not present");
838
839 Trk::AlignModule * mod = new Trk::AlignModule(this);
840 mod->setIdHash(getNextIDHash());
841 mod->setIdentifier(m_idHelper->wafer_id(iSide,iWheel,0,0,0));
842
843 std::stringstream name;
844 name <<"SCT/EndcapC/Disk_" << iWheel;
845 mod->setName(name.str());
846
847 if(!m_alignEndcaps || !moduleSelected(mod)) {
848 ATH_MSG_DEBUG("Module "<<mod->name()<<" NOT selected");
849 delete mod;
850 continue;
851 }
852
853 ATH_MSG_DEBUG("Building module "<<mod->name());
854
855 for (int iEta = 0; iEta < m_detManager->numerology().numRingsForDisk(iWheel); iEta++) {
856 ATH_MSG_DEBUG("iEta "<<iEta);
857 for (int iPhi = 0; iPhi < m_detManager->numerology().numPhiModulesForDiskRing(iWheel,iEta); iPhi++) {
858 ATH_MSG_DEBUG("iPhi "<<iPhi);
859 for(int is=0; is<2; is++) { // module side
860 const SiDetectorElement * element = m_detManager->getDetectorElement(iSide, iWheel, iPhi, iEta, is);
861 if (element) {
862 // get element location for debugging
863 // HepGeom::Point3D<double> center = element->transform() * HepGeom::Point3D<double>();
864 // ATH_MSG_DEBUG(" SCTDetectorElement id: " << id << " with center = " << center);
865 // ATH_MSG_DEBUG(" Is Barrel: "<< m_idHelper->is_barrel(id));
866
867 // add element to the AlignModule
868 mod->addDetElement(Trk::AlignModule::SCT,element,transform);
869 // and fill the corresponding map
870 (*sctIdHashMap)[element->identifyHash()] = mod;
871 }
872 }
873 }
874 }
875
876 // for endcap we move the CoG
877 Amg::Translation3D translation(mod->centerOfGravity());
878 ATH_MSG_DEBUG("Endcap:" << iSide << " , disk: " << iWheel << " , CoG (" << translation.x() << " , " << translation.y() << " , " << translation.z() << " ) " );
879 Amg::Transform3D localtoglobal = translation * Amg::RotationMatrix3D::Identity();
880 mod->setGlobalFrameToAlignFrameTransform(localtoglobal.inverse());
881
882 m_alignModuleListPtr->push_back(mod);
883 }
884
885 // now barrel
886 for (int iLayer = 0; iLayer < m_detManager->numerology().numLayers(); iLayer++) {
887 if (!m_detManager->numerology().useLayer(iLayer))
888 ATH_MSG_INFO(" Layer "<<iLayer<<" not present");
889
890 // create the AlignModule
891 Trk::AlignModule * mod = new Trk::AlignModule(this);
892 mod->setIdHash(getNextIDHash());
893 mod->setIdentifier(m_idHelper->wafer_id(0, iLayer, 0, 0, 0));
894
895 std::stringstream name;
896 name <<"SCT/Barrel/Layer_"<<iLayer;
897 mod->setName(name.str());
898
899 if(!m_alignBarrel || !moduleSelected(mod)) {
900 ATH_MSG_DEBUG("Module "<<mod->name()<<" NOT selected");
901 delete mod;
902 continue;
903 }
904
905 ATH_MSG_DEBUG("Building module "<<mod->name());
906
907 for (int iPhi = 0; iPhi < m_detManager->numerology().numPhiModulesForLayer(iLayer); iPhi++) {
908 ATH_MSG_DEBUG("iPhi "<<iPhi);
909 for (int iEta = m_detManager->numerology().beginEtaModuleForLayer(iLayer); iEta < m_detManager->numerology().endEtaModuleForLayer(iLayer); iEta++) {
910 ATH_MSG_DEBUG("iEta "<<iEta);
911 if (!iEta && m_detManager->numerology().skipEtaZeroForLayer(iLayer))
912 // iEta=0 is not defined for the SCT
913 continue;
914 for (int is = 0; is < 2; is++) { // module side
915
916 const SiDetectorElement * element = m_detManager->getDetectorElement(0, iLayer, iPhi, iEta, is);
917 if (element) {
918 // get element location for debugging
919 // HepGeom::Point3D<double> center = element->transform() * HepGeom::Point3D<double>();
920 // ATH_MSG_DEBUG(" SCTDetectorElement id: " << id << " with center = " << center);
921 // ATH_MSG_DEBUG(" Is Barrel: "<< m_idHelper->is_barrel(id));
922
923 // add element to the AlignModule
924 mod->addDetElement(Trk::AlignModule::SCT,element,transform);
925 // and fill the corresponding map
926 (*sctIdHashMap)[element->identifyHash()] = mod;
927 }
928 }
929 }
930 }
931
932 m_alignModuleListPtr->push_back(mod);
933 }
934
935 // and endcaap A
936 iEndcapIndex = 0;
937 iSide = m_detManager->numerology().endcapId(iEndcapIndex);
938 for (int iWheel = 0; iWheel < m_detManager->numerology().numDisks(); iWheel++) {
939 if (!m_detManager->numerology().useDisk(iWheel))
940 ATH_MSG_INFO(" Disk "<<iWheel<<" not present");
941
942 Trk::AlignModule * mod = new Trk::AlignModule(this);
943 mod->setIdHash(getNextIDHash());
944 mod->setIdentifier(m_idHelper->wafer_id(iSide,iWheel,0,0,0));
945
946 std::stringstream name;
947 name <<"SCT/EndcapA/Disk_" << iWheel;
948 mod->setName(name.str());
949
950 if(!m_alignEndcaps || !moduleSelected(mod)) {
951 ATH_MSG_DEBUG("Module "<<mod->name()<<" NOT selected");
952 delete mod;
953 continue;
954 }
955
956 ATH_MSG_DEBUG("Building module "<<mod->name());
957
958 for (int iEta = 0; iEta < m_detManager->numerology().numRingsForDisk(iWheel); iEta++) {
959 ATH_MSG_DEBUG("iEta "<<iEta);
960 for (int iPhi = 0; iPhi < m_detManager->numerology().numPhiModulesForDiskRing(iWheel,iEta); iPhi++) {
961 ATH_MSG_DEBUG("iPhi "<<iPhi);
962 for(int is=0; is<2; is++) { // module side
963 const SiDetectorElement * element = m_detManager->getDetectorElement(iSide, iWheel, iPhi, iEta, is);
964 if (element) {
965 // get element location for debugging
966 // HepGeom::Point3D<double> center = element->transform() * HepGeom::Point3D<double>();
967 // ATH_MSG_DEBUG(" SCTDetectorElement id: " << id << " with center = " << center);
968 // ATH_MSG_DEBUG(" Is Barrel: "<< m_idHelper->is_barrel(id));
969
970 // add element to the AlignModule
971 mod->addDetElement(Trk::AlignModule::SCT,element,transform);
972 // and fill the corresponding map
973 (*sctIdHashMap)[element->identifyHash()] = mod;
974 }
975 }
976 }
977 }
978
979 // for endcap we move the CoG
980 Amg::Translation3D translation(mod->centerOfGravity());
981 ATH_MSG_DEBUG("Endcap:" << iSide << " , disk: " << iWheel << " , CoG (" << translation.x() << " , " << translation.y() << " , " << translation.z() << " ) " );
982
983 Amg::Transform3D localtoglobal = translation * Amg::RotationMatrix3D::Identity();
984
985 mod->setGlobalFrameToAlignFrameTransform(localtoglobal.inverse());
986
987 m_alignModuleListPtr->push_back(mod);
988 }
989 }

◆ buildL3Barrel()

void InDet::SCTGeometryManagerTool::buildL3Barrel ( )
private

creates L3 AlignModules for SCT barrel

Definition at line 992 of file SCTGeometryManagerTool.cxx.

993 {
994 // ========================================
995 // BARREL
996 ATH_MSG_INFO("Preparing the SCT Barrel geometry for L3: module (bi-wafer) level");
997
998 // =========================================
999 // get all modules for SCT Barrel Level 3 alignment
1000 // 2112 modules
1001
1002 unsigned int maxHash = m_idHelper->wafer_hash_max();
1003 ATH_MSG_DEBUG("maxHash for the SCT "<<maxHash);
1004
1005 if(!m_idHashToAlignModuleMapsPtr->at(Trk::AlignModule::SCT))
1006 m_idHashToAlignModuleMapsPtr->at(Trk::AlignModule::SCT) = new Trk::AlignModuleList((size_t)(maxHash),nullptr);
1007 Trk::AlignModuleList * sctIdHashMap = m_idHashToAlignModuleMapsPtr->at(Trk::AlignModule::SCT);
1008
1009 for (int iLayer = 0; iLayer < m_detManager->numerology().numLayers(); iLayer++) {
1010 if (!m_detManager->numerology().useLayer(iLayer))
1011 ATH_MSG_INFO(" Layer "<<iLayer<<" not present");
1012 for (int iPhi = 0; iPhi < m_detManager->numerology().numPhiModulesForLayer(iLayer); iPhi++) {
1013 ATH_MSG_DEBUG("iPhi "<<iPhi);
1014 for (int iEta = m_detManager->numerology().beginEtaModuleForLayer(iLayer); iEta < m_detManager->numerology().endEtaModuleForLayer(iLayer); iEta++) {
1015 ATH_MSG_DEBUG("iEta "<<iEta);
1016 if (!iEta && m_detManager->numerology().skipEtaZeroForLayer(iLayer))
1017 // iEta=0 is not defined for the SCT
1018 continue;
1019
1020 // create the AlignModule
1021 Trk::AlignModule * mod = new Trk::AlignModule(this);
1022 mod->setIdHash(getNextIDHash());
1023 mod->setIdentifier(m_idHelper->wafer_id(0, iLayer, iPhi, iEta, 0));
1024
1025 std::stringstream name;
1026 name <<"SCT/Barrel/Layer_"<<iLayer<<"/Phi_"<<iPhi<<"/Eta_"<<iEta;
1027 mod->setName(name.str());
1028
1029 if(!m_alignBarrel || !moduleSelected(mod)) {
1030 ATH_MSG_DEBUG("Module "<<mod->name()<<" NOT selected");
1031 delete mod;
1032 continue;
1033 }
1034
1035 ATH_MSG_DEBUG("Building module "<<mod->name());
1036
1037 for(int is=0;is<2;is++) { // module side
1038
1039 const SiDetectorElement * element = m_detManager->getDetectorElement(0, iLayer, iPhi, iEta, is);
1040
1041 if (element) {
1042 // get element location for debugging
1043 // HepGeom::Point3D<double> center = element->transform() * HepGeom::Point3D<double>();
1044 // ATH_MSG_DEBUG(" SCTDetectorElement id: " << id << " with center = " << center);
1045 // ATH_MSG_DEBUG(" Is Barrel: "<< m_idHelper->is_barrel(id));
1046
1047 // !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
1048 // should this be identity? if yes, it means that the
1049 // db frame constants are in the global frame. Or not?
1050 const Amg::Transform3D transform = Amg::Transform3D::Identity();
1051 // !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
1052
1053 // add element to the AlignModule
1054 mod->addDetElement(Trk::AlignModule::SCT,element,transform);
1055 // and fill the corresponding map
1056 (*sctIdHashMap)[element->identifyHash()] = mod;
1057
1058 // the local frame for the SCT barrel modules is always that
1059 // of the Rphi element, NOT stereo !
1060 // in any case the correct frame can be obtained using moduleTransform() call
1061 // regardless of the side, but we only need it once so we retrieve it
1062 // for the non-stereo side
1063 if(!element->isStereo())
1064 mod->setGlobalFrameToAlignFrameTransform(element->moduleTransform().inverse());
1065 }
1066 }
1067
1068 m_alignModuleListPtr->push_back(mod);
1069 }
1070 }
1071
1072 }
1073 }

◆ buildL3Endcaps()

void InDet::SCTGeometryManagerTool::buildL3Endcaps ( )
private

creates L3 AlignModules for SCT endcaps

Definition at line 1076 of file SCTGeometryManagerTool.cxx.

1077 {
1078 // ========================================
1079 // ENDCAPs
1080 ATH_MSG_INFO("Preparing the SCT Endcap geometry for L3: module (bi-wafer) level");
1081
1082 // =========================================
1083 // get all modules for SCT Endcap Level 3 alignment
1084 // 2 * 988
1085
1086 unsigned int maxHash = m_idHelper->wafer_hash_max();
1087 ATH_MSG_DEBUG("maxHash for the SCT "<<maxHash);
1088
1089 if(!m_idHashToAlignModuleMapsPtr->at(Trk::AlignModule::SCT))
1090 m_idHashToAlignModuleMapsPtr->at(Trk::AlignModule::SCT) = new Trk::AlignModuleList((size_t)(maxHash),nullptr);
1091 Trk::AlignModuleList * sctIdHashMap = m_idHashToAlignModuleMapsPtr->at(Trk::AlignModule::SCT);
1092
1093 for (int iEndcapIndex = 0; iEndcapIndex < m_detManager->numerology().numEndcaps(); iEndcapIndex++) {
1094 int iSide = m_detManager->numerology().endcapId(iEndcapIndex);
1095 for (int iWheel = 0; iWheel < m_detManager->numerology().numDisks(); iWheel++) {
1096 if (!m_detManager->numerology().useDisk(iWheel))
1097 ATH_MSG_INFO(" Disk "<<iWheel<<" not present");
1098 for (int iEta = 0; iEta < m_detManager->numerology().numRingsForDisk(iWheel); iEta++) {
1099 ATH_MSG_DEBUG("iEta "<<iEta);
1100 for (int iPhi = 0; iPhi < m_detManager->numerology().numPhiModulesForDiskRing(iWheel,iEta); iPhi++) {
1101 ATH_MSG_DEBUG("iPhi "<<iPhi);
1102
1103 Trk::AlignModule * mod = new Trk::AlignModule(this);
1104 mod->setIdHash(getNextIDHash());
1105 mod->setIdentifier(m_idHelper->wafer_id(iSide,iWheel,iPhi,iEta,0));
1106
1107 std::stringstream name;
1108 if(iEndcapIndex == 0)
1109 name<<"SCT/EndcapA";
1110 else
1111 name<<"SCT/EndcapC";
1112 name<<"/Disk_"<<iWheel<<"/Phi_"<<iPhi<<"/Eta_"<<iEta;
1113 mod->setName(name.str());
1114
1115 if(!m_alignEndcaps || !moduleSelected(mod)) {
1116 ATH_MSG_DEBUG("Module "<<mod->name()<<" NOT selected");
1117 delete mod;
1118 continue;
1119 }
1120
1121 ATH_MSG_DEBUG("Building module "<<mod->name());
1122
1123 for(int is=0; is<2; is++) { // module side
1124
1125 const SiDetectorElement * element = m_detManager->getDetectorElement(iSide, iWheel, iPhi, iEta, is);
1126 if (element) {
1127 // get element location for debugging
1128 // HepGeom::Point3D<double> center = element->transform() * HepGeom::Point3D<double>();
1129 // ATH_MSG_DEBUG(" SCTDetectorElement id: " << id << " with center = " << center);
1130 // ATH_MSG_DEBUG(" Is Barrel: "<< m_idHelper->is_barrel(id));
1131
1132 // !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
1133 // should this be identity? if yes, it means that the
1134 // db frame constants are in the global frame. Or not?
1135 const Amg::Transform3D transform = Amg::Transform3D::Identity();
1136 // !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
1137
1138 // add element to the AlignModule
1139 mod->addDetElement(Trk::AlignModule::SCT,element,transform);
1140 // and fill the corresponding map
1141 (*sctIdHashMap)[element->identifyHash()] = mod;
1142
1143 // the local frame for the SCT endcap modules is always that
1144 // of the Rphi element, NOT stereo !
1145 // in any case the correct frame can be obtained using moduleTransform() call
1146 // regardless of the side, but we only need it once so we retrieve it
1147 // for the non-stereo side
1148 if(!element->isStereo())
1149 mod->setGlobalFrameToAlignFrameTransform(element->moduleTransform().inverse());
1150 }
1151 }
1152
1153 m_alignModuleListPtr->push_back(mod);
1154 }
1155 }
1156 }
1157 }
1158
1159 }

◆ checkAlignLevel()

bool InDet::SCTGeometryManagerTool::checkAlignLevel ( )

check whether the alignment level is correct

Definition at line 107 of file SCTGeometryManagerTool.cxx.

108 {
109 if(m_alignLevel == 0) {
110 ATH_MSG_INFO("Alignment level for SCT is "<<m_alignLevel);
111 return true;
112 }
113
114 if(m_alignLevel == 2 && m_useOldL2) {
115 ATH_MSG_INFO("Setting up OLD L2 alignment level for SCT");
116 m_alignLevelBarrel = m_alignLevel;
117 m_alignLevelEndcaps = m_alignLevel;
118 return true;
119 }
120
121 if(m_alignLevelBarrel == -1)
122 m_alignLevelBarrel = m_alignLevel;
123
124 if(m_alignLevelEndcaps == -1)
125 m_alignLevelEndcaps = m_alignLevel;
126
128
129 // if the alignment level for barrel and EC is set correctly
130 // reset the global alignment level
131 if(ok)
132 m_alignLevel = -1;
133
134 return ok;
135 }
bool checkAlignLevelEndcaps()
check whether the Endcap alignment level is correct
bool checkAlignLevelBarrel()
check whether the Barrel alignment level is correct

◆ checkAlignLevelBarrel()

bool InDet::SCTGeometryManagerTool::checkAlignLevelBarrel ( )

check whether the Barrel alignment level is correct

Definition at line 138 of file SCTGeometryManagerTool.cxx.

139 {
140 if(!m_alignBarrel)
141 return true;
142
143 // check whether geometry level is allowed
144 switch(m_alignLevelBarrel) {
145 case 1: case 2: case 27: case 3:
146 ATH_MSG_INFO("Alignment level for SCT Barrel is "<<m_alignLevelBarrel);
147 return true;
148 default:
149 msg(MSG::FATAL)<<"Alignment level "<<m_alignLevelBarrel<<" does not exist for SCT Barrel"<<endmsg;
150 return false;
151 }
152 }

◆ checkAlignLevelEndcaps()

bool InDet::SCTGeometryManagerTool::checkAlignLevelEndcaps ( )

check whether the Endcap alignment level is correct

Definition at line 155 of file SCTGeometryManagerTool.cxx.

156 {
157 if(!m_alignEndcaps)
158 return true;
159
160 // check whether geometry level is allowed
161 switch(m_alignLevelEndcaps) {
162 case 1: case 2: case 25: case 3:
163 ATH_MSG_INFO("Alignment level for SCT Endcaps is "<<m_alignLevelBarrel);
164 return true;
165 default:
166 msg(MSG::FATAL)<<"Alignment level "<<m_alignLevelEndcaps<<" does not exist for SCT Endcaps"<<endmsg;
167 return false;
168 }
169 }

◆ dumpGeometry()

void InDet::SCTGeometryManagerTool::dumpGeometry ( )
private

print basic geometry info to screen

Definition at line 1306 of file SCTGeometryManagerTool.cxx.

1307 {
1308 ATH_MSG_INFO("---------------------------------------------------");
1309 ATH_MSG_INFO("Summary of the alignment geometry");
1310 ATH_MSG_INFO("Number of alignable objects: "<< m_alignModuleList.size());
1311 for(unsigned int i=0;i<m_alignModuleList.size();i++) {
1312 const Trk::AlignModule* module = m_alignModuleList.at(i);
1313 ATH_MSG_INFO(i<<". "<< module->name());
1314 ATH_MSG_INFO(" - identifier: "<<module->identify());
1315 ATH_MSG_INFO(" - has "<<module->detElementCollection(Trk::AlignModule::SCT)->size()<<" SCT modules");
1316
1317 Amg::Transform3D localtoglobal = (module->globalFrameToAlignFrame()).inverse();
1318 ATH_MSG_DEBUG(" - local to global : "<<std::setprecision(12)<<localtoglobal.translation()<<" "<<localtoglobal.rotation());
1319
1320 DataVector<Trk::AlignPar> * pars = m_alignModuleTool->getAlignPars(module);
1321 int npars = pars->size();
1322 ATH_MSG_DEBUG(" - number of active transform parameters: "<<npars);
1323 for(int j=0;j<npars;j++)
1324 ATH_MSG_DEBUG(" * par "<<j<<" \'"<<(*pars)[j]->dumpType()<<"\' : sigma = "<<(*pars)[j]->sigma()<<" , softCut = "<<(*pars)[j]->softCut());
1325 }
1326 ATH_MSG_INFO("---------------------------------------------------");
1327 }
PublicToolHandle< Trk::IAlignModuleTool > m_alignModuleTool
pointer to AlignModuleTool
float j(const xAOD::IParticle &, const xAOD::TrackMeasurementValidation &hit, const Eigen::Matrix3d &jab_inv)

◆ finalize()

StatusCode InDet::SCTGeometryManagerTool::finalize ( )

Definition at line 92 of file SCTGeometryManagerTool.cxx.

93 {
94 ATH_MSG_DEBUG("finalize() of SCTGeometryManagerTool");
95
96 return StatusCode::SUCCESS;
97 }

◆ initialize()

StatusCode InDet::SCTGeometryManagerTool::initialize ( )

Definition at line 44 of file SCTGeometryManagerTool.cxx.

45 {
46 ATH_MSG_DEBUG("initialize() of SCTGeometryManagerTool");
47
48 // alignment levels are members of the IGeometryManagerTool base class
49 m_alignLevel = m_alignLevelProp;
50 m_alignLevelBarrel = m_alignLevelBarrelProp;
51 m_alignLevelEndcaps = m_alignLevelEndcapsProp;
52
53 // retrieve AlignModuleTool
54 if ( m_alignModuleTool.retrieve().isFailure() ) {
55 msg(MSG::FATAL)<<"Could not get " << m_alignModuleTool << endmsg;
56 return StatusCode::FAILURE;
57 }
58 else
59 ATH_MSG_INFO("Retrieved " << m_alignModuleTool);
60
61 // retrieve SCT helper
62 if ( detStore()->retrieve(m_idHelper).isFailure() ) {
63 msg(MSG::FATAL) << " Cannot retrieve SCT Helper " << endmsg;
64 return StatusCode::FAILURE;
65 }
66 else
67 ATH_MSG_INFO("retrieved Silicon SCT Helper");
68
69 // retrieve SCT detector manager
70 if ( detStore()->retrieve(m_detManager,m_stripDetManagerName).isFailure() ) {
71 msg(MSG::FATAL) << " Cannot retrieve SCT Detector Manager " << endmsg;
72 return StatusCode::FAILURE;
73 }
74 else
75 ATH_MSG_INFO("retrieved SCT Detector Manager");
76
77 // dump module selection
78 if(m_doModuleSelection && msgLvl(MSG::INFO)) {
79 msg(MSG::INFO)<<"Creating geometry for selected "<<m_moduleSelection.value().size()<<" modules:"<<endmsg;
80 for(unsigned int i=0;i<m_moduleSelection.value().size();i++)
81 msg(MSG::INFO)<<" "<<i<<". "<<m_moduleSelection.value().at(i)<<endmsg;
82 }
83
84 // check the allowed geometry levels
85 if(!checkAlignLevel())
86 return StatusCode::FAILURE;
87
88 return StatusCode::SUCCESS;
89 }
size_t size() const
Number of registered mappings.
Gaudi::Property< bool > m_doModuleSelection
Gaudi::Property< std::vector< unsigned long long > > m_moduleSelection
Gaudi::Property< int > m_alignLevelProp
property, copied to m_alignLevel in initialize()
Gaudi::Property< int > m_alignLevelBarrelProp
property, copied to m_alignLevelBarrel in initialize()
bool checkAlignLevel()
check whether the alignment level is correct
Gaudi::Property< std::string > m_stripDetManagerName
Gaudi::Property< int > m_alignLevelEndcapsProp
property, copied to m_alignLevelEndcaps in initialize()

◆ moduleSelected() [1/2]

bool InDet::SCTGeometryManagerTool::moduleSelected ( Trk::AlignModule * mod)
private

check wheather module is selected for module pointer

Definition at line 1300 of file SCTGeometryManagerTool.cxx.

1301 {
1302 return moduleSelected(mod->identify().get_compact());
1303 }

◆ moduleSelected() [2/2]

bool InDet::SCTGeometryManagerTool::moduleSelected ( unsigned long long modId)
private

check wheather module is selected for module id

Definition at line 1286 of file SCTGeometryManagerTool.cxx.

1287 {
1289 return true;
1290
1291 int nsel = m_moduleSelection.value().size();
1292 for(int i=0;i<nsel;++i)
1293 if(m_moduleSelection.value().at(i) == id)
1294 return true;
1295
1296 return false;
1297 }

◆ PrintModPositions()

void InDet::SCTGeometryManagerTool::PrintModPositions ( )
inline

Definition at line 60 of file SCTGeometryManagerTool.h.

60{};

◆ ReadGeometry()

int InDet::SCTGeometryManagerTool::ReadGeometry ( int solveLevel)

read the geometry Method is called from the main AlignAlg to build the geometry based on the requested level of alignment.

It calls the other build() methods based on that.

Definition at line 172 of file SCTGeometryManagerTool.cxx.

173 {
174 ATH_MSG_DEBUG("in ReadGeometry() solveLevel="<<solveLevel);
175
176 // set pointers
177 m_idHashToAlignModuleMapsPtr = &m_idHashToAlignModuleMaps;
178 m_alignModuleListPtr = &m_alignModuleList;
179
180 // build alignment geometry
182
183 // now set the alignment parameters
184 // first prepare the parameter lists
185 m_alignParList = new DataVector< DataVector<Trk::AlignPar> >(SG::OWN_ELEMENTS);
186 m_fullAlignParList = new DataVector< DataVector<Trk::AlignPar> >(SG::OWN_ELEMENTS);
187 // loop over modules
188 ATH_MSG_DEBUG("Adding module parameters to modules");
189 std::vector<Trk::AlignModule *>::const_iterator imod = m_alignModuleList.begin();
190 std::vector<Trk::AlignModule *>::const_iterator imod_end = m_alignModuleList.end();
191 for( ; imod!=imod_end ; ++imod)
193
194 // set alignModuleList and hash table in the alignModuleTool
196 ATH_MSG_DEBUG(" geometry set in m_alignModuleTool");
197
198 // set alignPar lists in the alignModuleTool
199 ATH_MSG_DEBUG(" alignParList = "<<m_alignParList);
200 ATH_MSG_DEBUG(" fullAlignParList = "<<m_fullAlignParList);
202 ATH_MSG_DEBUG(" AlignParLists set in m_alignModuleTool");
203
204 // dump summary about the geometry setup
205 if (m_dumpGeometry)
206 dumpGeometry();
207
208 int nDoF= m_alignModuleTool->nAlignParameters();
209 ATH_MSG_INFO("Total number of degrees of freedom: "<<nDoF);
210
211 return nDoF;
212 }
std::vector< Trk::AlignModuleList * > m_idHashToAlignModuleMaps
Gaudi::Property< bool > m_dumpGeometry
void addModuleParameters(Trk::AlignModule *module, DataVector< DataVector< Trk::AlignPar > > *allFullModPars, DataVector< DataVector< Trk::AlignPar > > *allActiveModPars)
adds alignment parameters for the module checks for active parameters and calls setSigmas()
void buildGeometry()
builds geometry for SCT alignment
void dumpGeometry()
print basic geometry info to screen

◆ setAlignLevel()

void InDet::SCTGeometryManagerTool::setAlignLevel ( int level)

Definition at line 100 of file SCTGeometryManagerTool.cxx.

101 {
102 m_alignLevelBarrel = m_alignLevelEndcaps = -1;
103 m_alignLevel = level;
104 }

◆ setSigmas()

void InDet::SCTGeometryManagerTool::setSigmas ( Trk::AlignModule * mod,
DataVector< Trk::AlignPar > * modPars )
private

sets sigmas for modules

Definition at line 1219 of file SCTGeometryManagerTool.cxx.

1220 {
1221 for(unsigned int ipar=0;ipar<modPars->size();++ipar) {
1222 // barrel
1223 if(m_idHelper->is_barrel(module->identify()))
1224 switch(modPars->at(ipar)->paramType()) {
1226 modPars->at(ipar)->setSigma(m_sigmaBarrelX);
1227 modPars->at(ipar)->setSoftCut(m_softcutBarrelX);
1228 break;
1230 modPars->at(ipar)->setSigma(m_sigmaBarrelY);
1231 modPars->at(ipar)->setSoftCut(m_softcutBarrelY);
1232 break;
1234 modPars->at(ipar)->setSigma(m_sigmaBarrelZ);
1235 modPars->at(ipar)->setSoftCut(m_softcutBarrelZ);
1236 break;
1238 modPars->at(ipar)->setSigma(m_sigmaBarrelRotX);
1239 modPars->at(ipar)->setSoftCut(m_softcutBarrelRotX);
1240 break;
1242 modPars->at(ipar)->setSigma(m_sigmaBarrelRotY);
1243 modPars->at(ipar)->setSoftCut(m_softcutBarrelRotY);
1244 break;
1246 modPars->at(ipar)->setSigma(m_sigmaBarrelRotZ);
1247 modPars->at(ipar)->setSoftCut(m_softcutBarrelRotZ);
1248 break;
1249 default:
1250 break;
1251 }
1252 // end-caps
1253 else
1254 switch(modPars->at(ipar)->paramType()) {
1256 modPars->at(ipar)->setSigma(m_sigmaEndcapX);
1257 modPars->at(ipar)->setSoftCut(m_softcutEndcapX);
1258 break;
1260 modPars->at(ipar)->setSigma(m_sigmaEndcapY);
1261 modPars->at(ipar)->setSoftCut(m_softcutEndcapY);
1262 break;
1264 modPars->at(ipar)->setSigma(m_sigmaEndcapZ);
1265 modPars->at(ipar)->setSoftCut(m_softcutEndcapZ);
1266 break;
1268 modPars->at(ipar)->setSigma(m_sigmaEndcapRotX);
1269 modPars->at(ipar)->setSoftCut(m_softcutEndcapRotX);
1270 break;
1272 modPars->at(ipar)->setSigma(m_sigmaEndcapRotY);
1273 modPars->at(ipar)->setSoftCut(m_softcutEndcapRotY);
1274 break;
1276 modPars->at(ipar)->setSigma(m_sigmaEndcapRotZ);
1277 modPars->at(ipar)->setSoftCut(m_softcutEndcapRotZ);
1278 break;
1279 default:
1280 break;
1281 }
1282 }
1283 }
Gaudi::Property< double > m_softcutEndcapRotY
Gaudi::Property< double > m_sigmaBarrelRotX
Gaudi::Property< double > m_softcutBarrelX
Gaudi::Property< double > m_sigmaEndcapZ
Gaudi::Property< double > m_softcutEndcapZ
Gaudi::Property< double > m_softcutEndcapX
Gaudi::Property< double > m_sigmaEndcapRotX
Gaudi::Property< double > m_softcutEndcapRotX
Gaudi::Property< double > m_softcutBarrelRotY
Gaudi::Property< double > m_sigmaEndcapRotZ
Gaudi::Property< double > m_sigmaBarrelRotY
Gaudi::Property< double > m_sigmaBarrelY
Gaudi::Property< double > m_softcutBarrelRotX
Gaudi::Property< double > m_sigmaBarrelRotZ
Gaudi::Property< double > m_softcutEndcapY
Gaudi::Property< double > m_sigmaEndcapRotY
Gaudi::Property< double > m_sigmaBarrelZ
Gaudi::Property< double > m_softcutBarrelZ
Gaudi::Property< double > m_softcutBarrelY
Gaudi::Property< double > m_softcutBarrelRotZ
Gaudi::Property< double > m_sigmaEndcapX
Gaudi::Property< double > m_sigmaBarrelX
Gaudi::Property< double > m_sigmaEndcapY
Gaudi::Property< double > m_softcutEndcapRotZ

◆ StoreModPositions()

void InDet::SCTGeometryManagerTool::StoreModPositions ( std::string )
inline

Definition at line 61 of file SCTGeometryManagerTool.h.

61{};

Member Data Documentation

◆ m_alignBarrel

Gaudi::Property<bool> InDet::SCTGeometryManagerTool::m_alignBarrel {this, "AlignBarrel", true}
private

Definition at line 146 of file SCTGeometryManagerTool.h.

146{this, "AlignBarrel", true};

◆ m_alignBarrelRotX

Gaudi::Property<bool> InDet::SCTGeometryManagerTool::m_alignBarrelRotX {this, "AlignBarrelRotX", true}
private

Definition at line 152 of file SCTGeometryManagerTool.h.

152{this, "AlignBarrelRotX", true};

◆ m_alignBarrelRotY

Gaudi::Property<bool> InDet::SCTGeometryManagerTool::m_alignBarrelRotY {this, "AlignBarrelRotY", true}
private

Definition at line 153 of file SCTGeometryManagerTool.h.

153{this, "AlignBarrelRotY", true};

◆ m_alignBarrelRotZ

Gaudi::Property<bool> InDet::SCTGeometryManagerTool::m_alignBarrelRotZ {this, "AlignBarrelRotZ", true}
private

Definition at line 154 of file SCTGeometryManagerTool.h.

154{this, "AlignBarrelRotZ", true};

◆ m_alignBarrelX

Gaudi::Property<bool> InDet::SCTGeometryManagerTool::m_alignBarrelX {this, "AlignBarrelX", true}
private

Definition at line 149 of file SCTGeometryManagerTool.h.

149{this, "AlignBarrelX", true};

◆ m_alignBarrelY

Gaudi::Property<bool> InDet::SCTGeometryManagerTool::m_alignBarrelY {this, "AlignBarrelY", true}
private

Definition at line 150 of file SCTGeometryManagerTool.h.

150{this, "AlignBarrelY", true};

◆ m_alignBarrelZ

Gaudi::Property<bool> InDet::SCTGeometryManagerTool::m_alignBarrelZ {this, "AlignBarrelZ", true}
private

Definition at line 151 of file SCTGeometryManagerTool.h.

151{this, "AlignBarrelZ", true};

◆ m_alignEndcapRotX

Gaudi::Property<bool> InDet::SCTGeometryManagerTool::m_alignEndcapRotX {this, "AlignEndcapRotX", true}
private

Definition at line 159 of file SCTGeometryManagerTool.h.

159{this, "AlignEndcapRotX", true};

◆ m_alignEndcapRotY

Gaudi::Property<bool> InDet::SCTGeometryManagerTool::m_alignEndcapRotY {this, "AlignEndcapRotY", true}
private

Definition at line 160 of file SCTGeometryManagerTool.h.

160{this, "AlignEndcapRotY", true};

◆ m_alignEndcapRotZ

Gaudi::Property<bool> InDet::SCTGeometryManagerTool::m_alignEndcapRotZ {this, "AlignEndcapRotZ", true}
private

Definition at line 161 of file SCTGeometryManagerTool.h.

161{this, "AlignEndcapRotZ", true};

◆ m_alignEndcaps

Gaudi::Property<bool> InDet::SCTGeometryManagerTool::m_alignEndcaps {this, "AlignEndcaps", true}
private

Definition at line 147 of file SCTGeometryManagerTool.h.

147{this, "AlignEndcaps", true};

◆ m_alignEndcapX

Gaudi::Property<bool> InDet::SCTGeometryManagerTool::m_alignEndcapX {this, "AlignEndcapX", true}
private

Definition at line 156 of file SCTGeometryManagerTool.h.

156{this, "AlignEndcapX", true};

◆ m_alignEndcapY

Gaudi::Property<bool> InDet::SCTGeometryManagerTool::m_alignEndcapY {this, "AlignEndcapY", true}
private

Definition at line 157 of file SCTGeometryManagerTool.h.

157{this, "AlignEndcapY", true};

◆ m_alignEndcapZ

Gaudi::Property<bool> InDet::SCTGeometryManagerTool::m_alignEndcapZ {this, "AlignEndcapZ", true}
private

Definition at line 158 of file SCTGeometryManagerTool.h.

158{this, "AlignEndcapZ", true};

◆ m_alignLevelBarrelProp

Gaudi::Property<int> InDet::SCTGeometryManagerTool::m_alignLevelBarrelProp {this, "AlignmentLevelBarrel", -1}
private

property, copied to m_alignLevelBarrel in initialize()

Definition at line 141 of file SCTGeometryManagerTool.h.

141{this, "AlignmentLevelBarrel", -1};

◆ m_alignLevelEndcapsProp

Gaudi::Property<int> InDet::SCTGeometryManagerTool::m_alignLevelEndcapsProp {this, "AlignmentLevelEndcaps", -1}
private

property, copied to m_alignLevelEndcaps in initialize()

Definition at line 142 of file SCTGeometryManagerTool.h.

142{this, "AlignmentLevelEndcaps", -1};

◆ m_alignLevelProp

Gaudi::Property<int> InDet::SCTGeometryManagerTool::m_alignLevelProp {this, "AlignmentLevel", 1}
private

property, copied to m_alignLevel in initialize()

Definition at line 140 of file SCTGeometryManagerTool.h.

140{this, "AlignmentLevel", 1};

◆ m_alignModuleList

Trk::AlignModuleList InDet::SCTGeometryManagerTool::m_alignModuleList
private

Definition at line 132 of file SCTGeometryManagerTool.h.

◆ m_alignModuleTool

PublicToolHandle<Trk::IAlignModuleTool> InDet::SCTGeometryManagerTool::m_alignModuleTool {this, "AlignModuleTool", "Trk::AlignModuleTool/AlignModuleTool"}
private

pointer to AlignModuleTool

Definition at line 130 of file SCTGeometryManagerTool.h.

130{this, "AlignModuleTool", "Trk::AlignModuleTool/AlignModuleTool"};

◆ m_alignParList

DataVector< DataVector<Trk::AlignPar> >* InDet::SCTGeometryManagerTool::m_alignParList {nullptr}
private

Definition at line 137 of file SCTGeometryManagerTool.h.

137{nullptr};

◆ m_detManager

const InDetDD::SCT_DetectorManager* InDet::SCTGeometryManagerTool::m_detManager {nullptr}
private

pointer to SCT detector manager

Definition at line 126 of file SCTGeometryManagerTool.h.

126{nullptr};

◆ m_doModuleSelection

Gaudi::Property<bool> InDet::SCTGeometryManagerTool::m_doModuleSelection {this, "doModuleSelection", false}
private

Definition at line 143 of file SCTGeometryManagerTool.h.

143{this, "doModuleSelection", false};

◆ m_dumpGeometry

Gaudi::Property<bool> InDet::SCTGeometryManagerTool::m_dumpGeometry {this, "DumpGeometry", true}
private

Definition at line 192 of file SCTGeometryManagerTool.h.

192{this, "DumpGeometry", true};

◆ m_fullAlignParList

DataVector< DataVector<Trk::AlignPar> >* InDet::SCTGeometryManagerTool::m_fullAlignParList {nullptr}
private

Definition at line 138 of file SCTGeometryManagerTool.h.

138{nullptr};

◆ m_idHashToAlignModuleMap

Trk::AlignModuleList InDet::SCTGeometryManagerTool::m_idHashToAlignModuleMap
private

Definition at line 133 of file SCTGeometryManagerTool.h.

◆ m_idHashToAlignModuleMaps

std::vector<Trk::AlignModuleList *> InDet::SCTGeometryManagerTool::m_idHashToAlignModuleMaps {std::vector<Trk::AlignModuleList *>(Trk::AlignModule::NDetectorTypes, nullptr)}
private

Definition at line 135 of file SCTGeometryManagerTool.h.

135{std::vector<Trk::AlignModuleList *>(Trk::AlignModule::NDetectorTypes, nullptr)};

◆ m_idHelper

const SCT_ID* InDet::SCTGeometryManagerTool::m_idHelper {nullptr}
private

pointer to SCT detector manager

Definition at line 128 of file SCTGeometryManagerTool.h.

128{nullptr};

◆ m_moduleSelection

Gaudi::Property<std::vector<unsigned long long> > InDet::SCTGeometryManagerTool::m_moduleSelection {this, "ModuleSelection", {}}
private

Definition at line 144 of file SCTGeometryManagerTool.h.

144{this, "ModuleSelection", {}};

◆ m_sigmaBarrelRotX

Gaudi::Property<double> InDet::SCTGeometryManagerTool::m_sigmaBarrelRotX {this, "SetSigmaBarrelRotX", 0.001}
private

Definition at line 166 of file SCTGeometryManagerTool.h.

166{this, "SetSigmaBarrelRotX", 0.001};

◆ m_sigmaBarrelRotY

Gaudi::Property<double> InDet::SCTGeometryManagerTool::m_sigmaBarrelRotY {this, "SetSigmaBarrelRotY", 0.001}
private

Definition at line 167 of file SCTGeometryManagerTool.h.

167{this, "SetSigmaBarrelRotY", 0.001};

◆ m_sigmaBarrelRotZ

Gaudi::Property<double> InDet::SCTGeometryManagerTool::m_sigmaBarrelRotZ {this, "SetSigmaBarrelRotZ", 0.001}
private

Definition at line 168 of file SCTGeometryManagerTool.h.

168{this, "SetSigmaBarrelRotZ", 0.001};

◆ m_sigmaBarrelX

Gaudi::Property<double> InDet::SCTGeometryManagerTool::m_sigmaBarrelX {this, "SetSigmaBarrelX", 1.}
private

Definition at line 163 of file SCTGeometryManagerTool.h.

163{this, "SetSigmaBarrelX", 1.};

◆ m_sigmaBarrelY

Gaudi::Property<double> InDet::SCTGeometryManagerTool::m_sigmaBarrelY {this, "SetSigmaBarrelY", 1.}
private

Definition at line 164 of file SCTGeometryManagerTool.h.

164{this, "SetSigmaBarrelY", 1.};

◆ m_sigmaBarrelZ

Gaudi::Property<double> InDet::SCTGeometryManagerTool::m_sigmaBarrelZ {this, "SetSigmaBarrelZ", 1.}
private

Definition at line 165 of file SCTGeometryManagerTool.h.

165{this, "SetSigmaBarrelZ", 1.};

◆ m_sigmaEndcapRotX

Gaudi::Property<double> InDet::SCTGeometryManagerTool::m_sigmaEndcapRotX {this, "SetSigmaEndcapRotX", 0.001}
private

Definition at line 173 of file SCTGeometryManagerTool.h.

173{this, "SetSigmaEndcapRotX", 0.001};

◆ m_sigmaEndcapRotY

Gaudi::Property<double> InDet::SCTGeometryManagerTool::m_sigmaEndcapRotY {this, "SetSigmaEndcapRotY", 0.001}
private

Definition at line 174 of file SCTGeometryManagerTool.h.

174{this, "SetSigmaEndcapRotY", 0.001};

◆ m_sigmaEndcapRotZ

Gaudi::Property<double> InDet::SCTGeometryManagerTool::m_sigmaEndcapRotZ {this, "SetSigmaEndcapRotZ", 0.001}
private

Definition at line 175 of file SCTGeometryManagerTool.h.

175{this, "SetSigmaEndcapRotZ", 0.001};

◆ m_sigmaEndcapX

Gaudi::Property<double> InDet::SCTGeometryManagerTool::m_sigmaEndcapX {this, "SetSigmaEndcapX", 1.}
private

Definition at line 170 of file SCTGeometryManagerTool.h.

170{this, "SetSigmaEndcapX", 1.};

◆ m_sigmaEndcapY

Gaudi::Property<double> InDet::SCTGeometryManagerTool::m_sigmaEndcapY {this, "SetSigmaEndcapY", 1.}
private

Definition at line 171 of file SCTGeometryManagerTool.h.

171{this, "SetSigmaEndcapY", 1.};

◆ m_sigmaEndcapZ

Gaudi::Property<double> InDet::SCTGeometryManagerTool::m_sigmaEndcapZ {this, "SetSigmaEndcapZ", 1.}
private

Definition at line 172 of file SCTGeometryManagerTool.h.

172{this, "SetSigmaEndcapZ", 1.};

◆ m_softcutBarrelRotX

Gaudi::Property<double> InDet::SCTGeometryManagerTool::m_softcutBarrelRotX {this, "SetSoftCutBarrelRotX", 1.}
private

Definition at line 180 of file SCTGeometryManagerTool.h.

180{this, "SetSoftCutBarrelRotX", 1.};

◆ m_softcutBarrelRotY

Gaudi::Property<double> InDet::SCTGeometryManagerTool::m_softcutBarrelRotY {this, "SetSoftCutBarrelRotY", 1.}
private

Definition at line 181 of file SCTGeometryManagerTool.h.

181{this, "SetSoftCutBarrelRotY", 1.};

◆ m_softcutBarrelRotZ

Gaudi::Property<double> InDet::SCTGeometryManagerTool::m_softcutBarrelRotZ {this, "SetSoftCutBarrelRotZ", 1.}
private

Definition at line 182 of file SCTGeometryManagerTool.h.

182{this, "SetSoftCutBarrelRotZ", 1.};

◆ m_softcutBarrelX

Gaudi::Property<double> InDet::SCTGeometryManagerTool::m_softcutBarrelX {this, "SetSoftCutBarrelX", 1.}
private

Definition at line 177 of file SCTGeometryManagerTool.h.

177{this, "SetSoftCutBarrelX", 1.};

◆ m_softcutBarrelY

Gaudi::Property<double> InDet::SCTGeometryManagerTool::m_softcutBarrelY {this, "SetSoftCutBarrelY", 1.}
private

Definition at line 178 of file SCTGeometryManagerTool.h.

178{this, "SetSoftCutBarrelY", 1.};

◆ m_softcutBarrelZ

Gaudi::Property<double> InDet::SCTGeometryManagerTool::m_softcutBarrelZ {this, "SetSoftCutBarrelZ", 1.}
private

Definition at line 179 of file SCTGeometryManagerTool.h.

179{this, "SetSoftCutBarrelZ", 1.};

◆ m_softcutEndcapRotX

Gaudi::Property<double> InDet::SCTGeometryManagerTool::m_softcutEndcapRotX {this, "SetSoftCutEndcapRotX", 1.}
private

Definition at line 187 of file SCTGeometryManagerTool.h.

187{this, "SetSoftCutEndcapRotX", 1.};

◆ m_softcutEndcapRotY

Gaudi::Property<double> InDet::SCTGeometryManagerTool::m_softcutEndcapRotY {this, "SetSoftCutEndcapRotY", 1.}
private

Definition at line 188 of file SCTGeometryManagerTool.h.

188{this, "SetSoftCutEndcapRotY", 1.};

◆ m_softcutEndcapRotZ

Gaudi::Property<double> InDet::SCTGeometryManagerTool::m_softcutEndcapRotZ {this, "SetSoftCutEndcapRotZ", 1.}
private

Definition at line 189 of file SCTGeometryManagerTool.h.

189{this, "SetSoftCutEndcapRotZ", 1.};

◆ m_softcutEndcapX

Gaudi::Property<double> InDet::SCTGeometryManagerTool::m_softcutEndcapX {this, "SetSoftCutEndcapX", 1.}
private

Definition at line 184 of file SCTGeometryManagerTool.h.

184{this, "SetSoftCutEndcapX", 1.};

◆ m_softcutEndcapY

Gaudi::Property<double> InDet::SCTGeometryManagerTool::m_softcutEndcapY {this, "SetSoftCutEndcapY", 1.}
private

Definition at line 185 of file SCTGeometryManagerTool.h.

185{this, "SetSoftCutEndcapY", 1.};

◆ m_softcutEndcapZ

Gaudi::Property<double> InDet::SCTGeometryManagerTool::m_softcutEndcapZ {this, "SetSoftCutEndcapZ", 1.}
private

Definition at line 186 of file SCTGeometryManagerTool.h.

186{this, "SetSoftCutEndcapZ", 1.};

◆ m_stripDetManagerName

Gaudi::Property<std::string> InDet::SCTGeometryManagerTool::m_stripDetManagerName {this,"StripDetectorManager","SCT","Name of the Strip Detector Manager to attempt to retrieve"}
private

Definition at line 194 of file SCTGeometryManagerTool.h.

194{this,"StripDetectorManager","SCT","Name of the Strip Detector Manager to attempt to retrieve"};

◆ m_useOldL2

Gaudi::Property<bool> InDet::SCTGeometryManagerTool::m_useOldL2 {this, "UseOldL2", false}
private

Definition at line 191 of file SCTGeometryManagerTool.h.

191{this, "UseOldL2", false};

The documentation for this class was generated from the following files: