CMS 3D CMS Logo

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

#include <HcalTestNumberingScheme.h>

Inheritance diagram for HcalTestNumberingScheme:
HcalNumberingScheme CaloNumberingScheme

Public Member Functions

uint32_t getUnitID (const HcalNumberingFromDDD::HcalID &id) override
 
 HcalTestNumberingScheme (bool forTB)
 
 ~HcalTestNumberingScheme () override
 
- Public Member Functions inherited from HcalNumberingScheme
 HcalNumberingScheme ()
 
 ~HcalNumberingScheme () 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 ()
 

Static Public Member Functions

static uint32_t packHcalIndex (int det, int z, int depth, int eta, int phi, int lay)
 
static void unpackHcalIndex (const uint32_t &idx, int &det, int &z, int &depth, int &eta, int &phi, int &lay)
 

Private Member Functions

 HcalTestNumberingScheme ()=delete
 

Private Attributes

bool forTBH2
 

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 11 of file HcalTestNumberingScheme.h.

Constructor & Destructor Documentation

◆ HcalTestNumberingScheme() [1/2]

HcalTestNumberingScheme::HcalTestNumberingScheme ( bool  forTB)

Definition at line 13 of file HcalTestNumberingScheme.cc.

13  : HcalNumberingScheme(), forTBH2(forTB) {
14  edm::LogVerbatim("HcalSim") << "Creating HcalTestNumberingScheme with TB Flag " << forTBH2;
15 }

References forTBH2.

◆ ~HcalTestNumberingScheme()

HcalTestNumberingScheme::~HcalTestNumberingScheme ( )
override

Definition at line 17 of file HcalTestNumberingScheme.cc.

17  {
18  edm::LogVerbatim("HcalSim") << "Deleting HcalTestNumberingScheme";
19 }

◆ HcalTestNumberingScheme() [2/2]

HcalTestNumberingScheme::HcalTestNumberingScheme ( )
privatedelete

Member Function Documentation

◆ getUnitID()

uint32_t HcalTestNumberingScheme::getUnitID ( const HcalNumberingFromDDD::HcalID id)
overridevirtual

Reimplemented from HcalNumberingScheme.

Definition at line 21 of file HcalTestNumberingScheme.cc.

21  {
22  //pack it into an integer
23  uint32_t index = 0;
24  if (forTBH2) {
25  // TB H2 Case
26  int etaR = id.etaR;
27  int phi = id.phis;
28  HcalSubdetector subdet = (HcalSubdetector)(id.subdet);
29  if (subdet == HcalBarrel && phi > 4) { // HB2
30  if (etaR > 4 && etaR < 10)
31  index = HcalDetId(subdet, id.lay, id.phis, 1).rawId();
32  } else { // HB1
33  index = HcalDetId(subdet, etaR, id.phis, id.depth).rawId();
34  }
35  } else {
36  // Test case
37  index = HcalTestNumbering::packHcalIndex(id.subdet, id.zside, id.depth, id.etaR, id.phis, id.lay);
38  }
39 #ifdef EDM_ML_DEBUG
40  edm::LogVerbatim("HcalSim") << "HcalTestNumberingScheme det = " << id.subdet << " depth/lay = " << id.depth << "/"
41  << id.lay << " zside = " << id.zside << " eta/R = " << id.etaR << " phi = " << id.phis
42  << " packed index = 0x" << std::hex << index << std::dec << std::endl;
43 #endif
44  return index;
45 }

References TauDecayModes::dec, LEDCalibrationChannels::depth, forTBH2, HcalBarrel, HcalTestNumbering::packHcalIndex(), phi, DetId::rawId(), and ecaldqm::zside().

Referenced by HcalTestAnalysis::fill(), SimG4HcalValidation::fill(), and HcalTestAnalysis::qieAnalysis().

◆ packHcalIndex()

uint32_t HcalTestNumberingScheme::packHcalIndex ( int  det,
int  z,
int  depth,
int  eta,
int  phi,
int  lay 
)
static

◆ unpackHcalIndex()

void HcalTestNumberingScheme::unpackHcalIndex ( const uint32_t &  idx,
int &  det,
int &  z,
int &  depth,
int &  eta,
int &  phi,
int &  lay 
)
static

Member Data Documentation

◆ forTBH2

bool HcalTestNumberingScheme::forTBH2
private

Definition at line 22 of file HcalTestNumberingScheme.h.

Referenced by getUnitID(), and HcalTestNumberingScheme().

ecaldqm::zside
int zside(DetId const &)
Definition: EcalDQMCommonUtils.cc:189
charmTagsComputerCvsB_cfi.idx
idx
Definition: charmTagsComputerCvsB_cfi.py:108
HcalBarrel
Definition: HcalAssistant.h:33
HcalTestNumbering::unpackHcalIndex
static void unpackHcalIndex(const uint32_t &idx, int &det, int &z, int &depth, int &eta, int &phi, int &lay)
Definition: HcalTestNumbering.cc:18
PVValHelper::eta
Definition: PVValidationHelpers.h:69
DDAxes::z
LEDCalibrationChannels.depth
depth
Definition: LEDCalibrationChannels.py:65
HcalTestNumbering::packHcalIndex
static uint32_t packHcalIndex(int det, int z, int depth, int eta, int phi, int lay)
Definition: HcalTestNumbering.cc:7
HcalNumberingScheme::HcalNumberingScheme
HcalNumberingScheme()
Definition: HcalNumberingScheme.cc:13
HcalTestNumberingScheme::forTBH2
bool forTBH2
Definition: HcalTestNumberingScheme.h:22
HcalDetId
Definition: HcalDetId.h:12
edm::LogVerbatim
Definition: MessageLogger.h:297
HcalSubdetector
HcalSubdetector
Definition: HcalAssistant.h:31
DDAxes::phi
DetId::rawId
constexpr uint32_t rawId() const
get the raw id
Definition: DetId.h:57
AlignmentPI::index
index
Definition: AlignmentPayloadInspectorHelper.h:46
TauDecayModes.dec
dec
Definition: TauDecayModes.py:143