21 for (
auto& hcalHit : hcalHits) {
29 if ((det == 2) && (
layer == 2) && (
eta == 18))
33 double energy = wt * (hcalHit.energy());
37 edm::LogVerbatim(
"HcalSim") <<
"Hit " <<
ii <<
" out of " << hcalHits.size() <<
" " << std::hex << newid
50 edm::LogWarning(
"HcalSim") <<
"HcalHitRelabeller: no valid HcalDDDRecConstants";
68 sign = (
z == 0) ? (-1) : (1);
70 int depth0 = ((det == 1) && (
layer == 2) && (
eta == 15)) ?
depth :
id.depth;
83 <<
"subdet: " << det <<
" " 85 <<
"depth: " <<
depth <<
" " 86 <<
"ieta: " <<
eta <<
" " 87 <<
"iphi: " <<
phi <<
" " 88 <<
"layer: " <<
layer <<
" new HcalDetId -> hex.RawID = " << std::hex << hid.
rawId()
89 <<
std::dec <<
" subdet, z, depth, eta, phi = " << det <<
" " <<
z <<
" " <<
id.depth
90 <<
" " <<
id.eta <<
" " <<
id.phi <<
" ---> " << hid;
98 int zside = (
z == 0) ? (-1) : (1);
99 double wt = ((((det == 1) && (
layer <= 1)) || ((det == 2) && (
layer <= 2))) && (
depth == 1))
104 <<
" ieta: " <<
eta <<
" iphi: " <<
phi <<
" layer: " <<
layer <<
" wt " << wt;
Log< level::Info, true > LogVerbatim
constexpr int zside() const
get the z-side of the cell (1/-1)
constexpr int ietaAbs() const
get the absolute value of the cell ieta
HcalID getHCID(int subdet, int ieta, int iphi, int lay, int idepth) const
void setGeometry(const HcalDDDRecConstants *&)
constexpr std::array< uint8_t, layerIndexSize< TrackerTraits > > layer
constexpr HcalSubdetector subdet() const
get the subdetector
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)
DetId relabel(const uint32_t testId) const
void process(std::vector< PCaloHit > &hcalHits)
constexpr uint32_t rawId() const
get the raw id
double energyWt(const uint32_t testId) const
double getLayer0Wt(const int &det, const int &phi, const int &zside) const
HcalHitRelabeller(bool nd=false)
const HcalDDDRecConstants * theRecNumber
Log< level::Warning, false > LogWarning
constexpr int iphi() const
get the cell iphi
constexpr int depth() const
get the tower depth