CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
AlignmentPI::topolInfo Struct Reference

#include <AlignmentPayloadInspectorHelper.h>

Public Member Functions

void fillGeometryInfo (const DetId &detId, const TrackerTopology &tTopo, bool isPhase0)
 
AlignmentPI::regions filterThePartition ()
 
void init ()
 
void printAll ()
 
bool sanityCheck ()
 
virtual ~topolInfo ()
 

Private Attributes

bool m_isDoubleSide
 
bool m_isInternal
 
bool m_isRphi
 
int m_layer
 
uint32_t m_rawid
 
int m_ring
 
int m_side
 
int m_subdetid
 

Detailed Description

Definition at line 359 of file AlignmentPayloadInspectorHelper.h.

Constructor & Destructor Documentation

◆ ~topolInfo()

virtual AlignmentPI::topolInfo::~topolInfo ( )
inlinevirtual

Definition at line 376 of file AlignmentPayloadInspectorHelper.h.

376 {}

Member Function Documentation

◆ fillGeometryInfo()

void AlignmentPI::topolInfo::fillGeometryInfo ( const DetId detId,
const TrackerTopology tTopo,
bool  isPhase0 
)
inline

Definition at line 413 of file AlignmentPayloadInspectorHelper.h.

References hcalRecHitTable_cff::detId, AlignmentPI::isBPixOuterLadder(), TrackerTopology::isRPhi(), m_isDoubleSide, m_isInternal, m_isRphi, m_layer, m_rawid, m_ring, m_side, m_subdetid, PixelSubdetector::PixelBarrel, PixelSubdetector::PixelEndcap, TrackerTopology::pxbLayer(), TrackerTopology::pxfDisk(), TrackerTopology::pxfSide(), StripSubdetector::TEC, TrackerTopology::tecIsDoubleSide(), TrackerTopology::tecPetalInfo(), TrackerTopology::tecRing(), TrackerTopology::tecSide(), TrackerTopology::tecWheel(), StripSubdetector::TIB, TrackerTopology::tibIsDoubleSide(), TrackerTopology::tibIsInternalString(), TrackerTopology::tibLayer(), TrackerTopology::tibSide(), StripSubdetector::TID, TrackerTopology::tidIsDoubleSide(), TrackerTopology::tidModuleInfo(), TrackerTopology::tidRing(), TrackerTopology::tidSide(), TrackerTopology::tidWheel(), StripSubdetector::TOB, TrackerTopology::tobIsDoubleSide(), TrackerTopology::tobLayer(), TrackerTopology::tobModule(), and TrackerTopology::tobSide().

415  {
416  unsigned int subdetId = static_cast<unsigned int>(detId.subdetId());
417 
418  m_rawid = detId.rawId();
419  m_subdetid = subdetId;
420 
421  if (subdetId == StripSubdetector::TIB) {
422  m_layer = tTopo.tibLayer(detId.rawId());
423  m_side = tTopo.tibSide(detId.rawId());
424  m_isRphi = tTopo.isRPhi(detId.rawId());
425  m_isDoubleSide = tTopo.tibIsDoubleSide(detId.rawId());
426  m_isInternal = tTopo.tibIsInternalString(detId.rawId());
427  } else if (subdetId == StripSubdetector::TOB) {
428  m_layer = tTopo.tobLayer(detId.rawId());
429  m_side = tTopo.tobSide(detId.rawId());
430  m_isRphi = tTopo.isRPhi(detId.rawId());
431  m_isDoubleSide = tTopo.tobIsDoubleSide(detId.rawId());
432  m_isInternal = tTopo.tobModule(detId.rawId()) % 2;
433  } else if (subdetId == StripSubdetector::TID) {
434  m_layer = tTopo.tidWheel(detId.rawId());
435  m_side = tTopo.tidSide(detId.rawId());
436  m_isRphi = tTopo.isRPhi(detId.rawId());
437  m_ring = tTopo.tidRing(detId.rawId());
438  m_isDoubleSide = tTopo.tidIsDoubleSide(detId.rawId());
439  m_isInternal = tTopo.tidModuleInfo(detId.rawId())[0];
440  } else if (subdetId == StripSubdetector::TEC) {
441  m_layer = tTopo.tecWheel(detId.rawId());
442  m_side = tTopo.tecSide(detId.rawId());
443  m_isRphi = tTopo.isRPhi(detId.rawId());
444  m_ring = tTopo.tecRing(detId.rawId());
445  m_isDoubleSide = tTopo.tecIsDoubleSide(detId.rawId());
446  m_isInternal = tTopo.tecPetalInfo(detId.rawId())[0];
447  } else if (subdetId == PixelSubdetector::PixelBarrel) {
448  m_layer = tTopo.pxbLayer(detId.rawId());
450  } else if (subdetId == PixelSubdetector::PixelEndcap) {
451  m_layer = tTopo.pxfDisk(detId.rawId());
452  m_side = tTopo.pxfSide(detId.rawId());
453  } else
454  edm::LogWarning("LogicError") << "Unknown subdetid: " << subdetId;
455  }
static constexpr auto TEC
bool tibIsDoubleSide(const DetId &id) const
bool tecIsDoubleSide(const DetId &id) const
bool tidIsDoubleSide(const DetId &id) const
unsigned int tobLayer(const DetId &id) const
unsigned int pxbLayer(const DetId &id) const
unsigned int tibSide(const DetId &id) const
unsigned int tobSide(const DetId &id) const
std::vector< unsigned int > tidModuleInfo(const DetId &id) const
unsigned int tidSide(const DetId &id) const
std::vector< unsigned int > tecPetalInfo(const DetId &id) const
unsigned int tidWheel(const DetId &id) const
unsigned int tecWheel(const DetId &id) const
bool isBPixOuterLadder(const DetId &detid, const TrackerTopology &tTopo, bool isPhase0)
bool isRPhi(const DetId &id) const
unsigned int tecRing(const DetId &id) const
ring id
bool tobIsDoubleSide(const DetId &id) const
unsigned int tecSide(const DetId &id) const
unsigned int pxfDisk(const DetId &id) const
static constexpr auto TOB
unsigned int pxfSide(const DetId &id) const
static constexpr auto TIB
bool tibIsInternalString(const DetId &id) const
unsigned int tidRing(const DetId &id) const
unsigned int tibLayer(const DetId &id) const
unsigned int tobModule(const DetId &id) const
Log< level::Warning, false > LogWarning
static constexpr auto TID

◆ filterThePartition()

AlignmentPI::regions AlignmentPI::topolInfo::filterThePartition ( )
inline

Definition at line 460 of file AlignmentPayloadInspectorHelper.h.

References AlignmentPI::BPixL1i, AlignmentPI::BPixL1o, AlignmentPI::BPixL2i, AlignmentPI::BPixL2o, AlignmentPI::BPixL3i, AlignmentPI::BPixL3o, AlignmentPI::BPixL4i, AlignmentPI::BPixL4o, AlignmentPI::FPixmL1, AlignmentPI::FPixmL2, AlignmentPI::FPixmL3, AlignmentPI::FPixpL1, AlignmentPI::FPixpL2, AlignmentPI::FPixpL3, m_isDoubleSide, m_isInternal, m_isRphi, m_layer, m_ring, m_side, m_subdetid, AlignmentPI::NUM_OF_REGIONS, runTheMatrix::ret, AlignmentPI::StripDoubleSide, AlignmentPI::TECmR1R, AlignmentPI::TECmR1S, AlignmentPI::TECmR2R, AlignmentPI::TECmR2S, AlignmentPI::TECmR3, AlignmentPI::TECmR4, AlignmentPI::TECmR5, AlignmentPI::TECmR6, AlignmentPI::TECmR7, AlignmentPI::TECpR1R, AlignmentPI::TECpR1S, AlignmentPI::TECpR2R, AlignmentPI::TECpR2S, AlignmentPI::TECpR3, AlignmentPI::TECpR4, AlignmentPI::TECpR5, AlignmentPI::TECpR6, AlignmentPI::TECpR7, AlignmentPI::TIBL1Ri, AlignmentPI::TIBL1Ro, AlignmentPI::TIBL1Si, AlignmentPI::TIBL1So, AlignmentPI::TIBL2Ri, AlignmentPI::TIBL2Ro, AlignmentPI::TIBL2Si, AlignmentPI::TIBL2So, AlignmentPI::TIBL3i, AlignmentPI::TIBL3o, AlignmentPI::TIBL4i, AlignmentPI::TIBL4o, AlignmentPI::TIDmR1R, AlignmentPI::TIDmR1S, AlignmentPI::TIDmR2R, AlignmentPI::TIDmR2S, AlignmentPI::TIDmR3, AlignmentPI::TIDpR1R, AlignmentPI::TIDpR1S, AlignmentPI::TIDpR2R, AlignmentPI::TIDpR2S, AlignmentPI::TIDpR3, AlignmentPI::TOBL1Ri, AlignmentPI::TOBL1Ro, AlignmentPI::TOBL1Si, AlignmentPI::TOBL1So, AlignmentPI::TOBL2Ri, AlignmentPI::TOBL2Ro, AlignmentPI::TOBL2Si, AlignmentPI::TOBL2So, AlignmentPI::TOBL3i, AlignmentPI::TOBL3o, AlignmentPI::TOBL4i, AlignmentPI::TOBL4o, AlignmentPI::TOBL5i, AlignmentPI::TOBL5o, AlignmentPI::TOBL6i, and AlignmentPI::TOBL6o.

462  {
464 
465  if (m_isDoubleSide) {
467  }
468 
469  // BPix
470  if (m_subdetid == 1) {
471  switch (m_layer) {
472  case 1:
474  break;
475  case 2:
477  break;
478  case 3:
480  break;
481  case 4:
483  break;
484  default:
485  edm::LogWarning("LogicError") << "Unknow BPix layer: " << m_layer;
486  break;
487  }
488  // FPix
489  } else if (m_subdetid == 2) {
490  switch (m_layer) {
491  case 1:
493  break;
494  case 2:
496  break;
497  case 3:
499  break;
500  default:
501  edm::LogWarning("LogicError") << "Unknow FPix disk: " << m_layer;
502  break;
503  }
504  // TIB
505  } else if (m_subdetid == 3) {
506  switch (m_layer) {
507  case 1:
508  if (m_isRphi) {
510  } else {
512  }
513  break;
514  case 2:
515  if (m_isRphi) {
517  } else {
519  }
520  break;
521  case 3:
523  break;
524  case 4:
526  break;
527  default:
528  edm::LogWarning("LogicError") << "Unknow TIB layer: " << m_layer;
529  break;
530  }
531  // TID
532  } else if (m_subdetid == 4) {
533  switch (m_ring) {
534  case 1:
535  if (m_isRphi) {
537  } else {
539  }
540  break;
541  case 2:
542  if (m_isRphi) {
544  } else {
546  }
547  break;
548  case 3:
550  break;
551  default:
552  edm::LogWarning("LogicError") << "Unknow TID wheel: " << m_layer;
553  break;
554  }
555  // TOB
556  } else if (m_subdetid == 5) {
557  switch (m_layer) {
558  case 1:
559  if (m_isRphi) {
561  } else {
563  }
564  break;
565  case 2:
566  if (m_isRphi) {
568  } else {
570  }
571  break;
572  case 3:
574  break;
575  case 4:
577  break;
578  case 5:
580  break;
581  case 6:
583  break;
584  default:
585  edm::LogWarning("LogicError") << "Unknow TOB layer: " << m_layer;
586  break;
587  }
588  // TEC
589  } else if (m_subdetid == 6) {
590  switch (m_ring) {
591  case 1:
592  if (m_isRphi) {
594  } else {
596  }
597  break;
598  case 2:
599  if (m_isRphi) {
601  } else {
603  }
604  break;
605  case 3:
607  break;
608  case 4:
610  break;
611  case 5:
613  break;
614  case 6:
616  break;
617  case 7:
619  break;
620  default:
621  edm::LogWarning("LogicError") << "Unknow TEC ring: " << m_ring;
622  break;
623  }
624  }
625 
626  return ret;
627  }
ret
prodAgent to be discontinued
Log< level::Warning, false > LogWarning

◆ init()

void AlignmentPI::topolInfo::init ( void  )
inline

◆ printAll()

void AlignmentPI::topolInfo::printAll ( )
inline

◆ sanityCheck()

bool AlignmentPI::topolInfo::sanityCheck ( )
inline

Definition at line 403 of file AlignmentPayloadInspectorHelper.h.

References m_layer, and m_subdetid.

405  {
406  if (m_layer == 0 || (m_subdetid == 1 && m_layer > 4) || (m_subdetid == 2 && m_layer > 3)) {
407  return false;
408  } else {
409  return true;
410  }
411  }

Member Data Documentation

◆ m_isDoubleSide

bool AlignmentPI::topolInfo::m_isDoubleSide
private

◆ m_isInternal

bool AlignmentPI::topolInfo::m_isInternal
private

◆ m_isRphi

bool AlignmentPI::topolInfo::m_isRphi
private

◆ m_layer

int AlignmentPI::topolInfo::m_layer
private

◆ m_rawid

uint32_t AlignmentPI::topolInfo::m_rawid
private

Definition at line 361 of file AlignmentPayloadInspectorHelper.h.

Referenced by fillGeometryInfo(), init(), and printAll().

◆ m_ring

int AlignmentPI::topolInfo::m_ring
private

◆ m_side

int AlignmentPI::topolInfo::m_side
private

◆ m_subdetid

int AlignmentPI::topolInfo::m_subdetid
private