CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
ESTBNumberingScheme Class Reference

#include <ESTBNumberingScheme.h>

Inheritance diagram for ESTBNumberingScheme:
EcalNumberingScheme CaloNumberingScheme

Public Member Functions

 ESTBNumberingScheme ()
 
uint32_t getUnitID (const EcalBaseNumber &baseNumber) const override
 
 ~ESTBNumberingScheme () override
 
- Public Member Functions inherited from EcalNumberingScheme
 EcalNumberingScheme ()
 
 ~EcalNumberingScheme () override
 
- Public Member Functions inherited from CaloNumberingScheme
 CaloNumberingScheme (int iv=0)
 Constructor with optional verbosity control. More...
 
void setVerbosity (int)
 Verbosity setting. More...
 
virtual ~CaloNumberingScheme ()
 

Private Attributes

int iX [30]
 
int iY [30]
 

Additional Inherited Members

- Protected Attributes inherited from CaloNumberingScheme
int verbosity
 Verbosity field: Zero = quiet, increasing integers mean more output. More...
 

Detailed Description

Definition at line 6 of file ESTBNumberingScheme.h.

Constructor & Destructor Documentation

◆ ESTBNumberingScheme()

ESTBNumberingScheme::ESTBNumberingScheme ( )

Definition at line 6 of file ESTBNumberingScheme.cc.

7  int ix[30] = {3, 2, 4, 3, 2, 1, 4, 3, 2, 1, 4, 3, 2, 1, 1, 1, 1, 1, 2, 2, 2, 2, 3, 3, 3, 3, 4, 4, 4, 4};
8  int iy[30] = {4, 4, 3, 3, 3, 3, 2, 2, 2, 2, 1, 1, 1, 1, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4};
9 
10  int i;
11  for (i = 0; i < 30; ++i) {
12  iX[i] = ix[i];
13  iY[i] = iy[i];
14  }
15 
16  edm::LogInfo("EcalGeom") << "Creating ESTBNumberingScheme";
17 }

References mps_fire::i, iX, and iY.

◆ ~ESTBNumberingScheme()

ESTBNumberingScheme::~ESTBNumberingScheme ( )
override

Definition at line 19 of file ESTBNumberingScheme.cc.

19 { edm::LogInfo("EcalGeom") << "Deleting ESTBNumberingScheme"; }

Member Function Documentation

◆ getUnitID()

uint32_t ESTBNumberingScheme::getUnitID ( const EcalBaseNumber baseNumber) const
overridevirtual

Implements EcalNumberingScheme.

Definition at line 21 of file ESTBNumberingScheme.cc.

21  {
22  int level = baseNumber.getLevels();
23  uint32_t intIndex = 0;
24  if (level > 0) {
25  // depth index - silicon layer 1-st or 2-nd
26  int layer = 0;
27  if (baseNumber.getLevelName(0) == "SFSX") {
28  layer = 1;
29  } else if (baseNumber.getLevelName(0) == "SFSY") {
30  layer = 2;
31  } else {
32  edm::LogWarning("EcalGeom") << "ESTBNumberingScheme: Wrong name"
33  << " of Presh. Si. Strip : " << baseNumber.getLevelName(0);
34  }
35 
36  // Z index +Z = 1 ; -Z = 2
37  int zside = baseNumber.getCopyNumber("EREG");
38  zside = 2 * (1 - zside) + 1;
39  // wafer number
40  int wafer = baseNumber.getCopyNumber(3);
41  int x = 0, y = 0;
42  // strip number inside wafer
43  int strip = baseNumber.getCopyNumber(0);
44 
45  x = iX[wafer];
46  y = iY[wafer];
47 
48  intIndex = ESDetId(strip, x, y, layer, zside).rawId();
49 
50  LogDebug("EcalGeom") << "ESTBNumberingScheme : zside " << zside << " layer " << layer << " wafer " << wafer << " X "
51  << x << " Y " << y << " strip " << strip << " UnitID 0x" << std::hex << intIndex << std::dec;
52  for (int ich = 0; ich < level; ich++) {
53  LogDebug("EcalGeom") << "Name = " << baseNumber.getLevelName(ich) << " copy = " << baseNumber.getCopyNumber(ich);
54  }
55  }
56 
57  return intIndex;
58 }

References TauDecayModes::dec, EcalBaseNumber::getCopyNumber(), EcalBaseNumber::getLevelName(), EcalBaseNumber::getLevels(), iX, iY, phase1PixelTopology::layer, personalPlayback::level, LogDebug, DetId::rawId(), digitizers_cfi::strip, x, y, and ecaldqm::zside().

Member Data Documentation

◆ iX

int ESTBNumberingScheme::iX[30]
private

Definition at line 13 of file ESTBNumberingScheme.h.

Referenced by ESTBNumberingScheme(), and getUnitID().

◆ iY

int ESTBNumberingScheme::iY[30]
private

Definition at line 14 of file ESTBNumberingScheme.h.

Referenced by ESTBNumberingScheme(), and getUnitID().

personalPlayback.level
level
Definition: personalPlayback.py:22
DDAxes::y
mps_fire.i
i
Definition: mps_fire.py:428
EcalBaseNumber::getCopyNumber
int getCopyNumber(int level) const
Definition: EcalBaseNumber.cc:24
EcalBaseNumber::getLevelName
std::string const & getLevelName(int level) const
Definition: EcalBaseNumber.cc:35
ecaldqm::zside
int zside(DetId const &)
Definition: EcalDQMCommonUtils.cc:189
digitizers_cfi.strip
strip
Definition: digitizers_cfi.py:19
ESDetId
Definition: ESDetId.h:15
DDAxes::x
edm::LogInfo
Log< level::Info, false > LogInfo
Definition: MessageLogger.h:125
ESTBNumberingScheme::iY
int iY[30]
Definition: ESTBNumberingScheme.h:14
edm::LogWarning
Log< level::Warning, false > LogWarning
Definition: MessageLogger.h:122
ESTBNumberingScheme::iX
int iX[30]
Definition: ESTBNumberingScheme.h:13
phase1PixelTopology::layer
constexpr std::array< uint8_t, layerIndexSize > layer
Definition: phase1PixelTopology.h:99
LogDebug
#define LogDebug(id)
Definition: MessageLogger.h:233
EcalBaseNumber::getLevels
int getLevels() const
Definition: EcalBaseNumber.cc:22
DetId::rawId
constexpr uint32_t rawId() const
get the raw id
Definition: DetId.h:57
TauDecayModes.dec
dec
Definition: TauDecayModes.py:142
EcalNumberingScheme::EcalNumberingScheme
EcalNumberingScheme()
Definition: EcalNumberingScheme.cc:9