CMS 3D CMS Logo

Typedefs | Enumerations | Functions | Variables
hcaldqm::hashfunctions Namespace Reference

Typedefs

typedef uint32_t(* hash_function_did) (HcalDetId const &)
 
typedef uint32_t(* hash_function_eid) (HcalElectronicsId const &)
 
typedef uint32_t(* hash_function_tid) (HcalTrigTowerDetId const &)
 
typedef std::string(* name_function_did) (HcalDetId const &)
 
typedef std::string(* name_function_eid) (HcalElectronicsId const &)
 
typedef std::string(* name_function_tid) (HcalTrigTowerDetId const &)
 

Enumerations

enum  HashType {
  fSubdet = 0, fSubdetiphi = 1, fSubdetieta = 2, fSubdetdepth = 3,
  fSubdetPM = 4, fSubdetPMiphi = 5, fiphi = 6, fieta = 7,
  fdepth = 8, fHFPMiphi = 9, fHBHEPartition = 10, fDChannel = 11,
  nHashType_did = 12, fFED = 13, fFEDSpigot = 14, fFEDSlot = 15,
  fCrate = 16, fCrateSpigot = 17, fCrateSlot = 18, fFiber = 19,
  fFiberFiberCh = 20, fFiberCh = 21, fElectronics = 22, fEChannel = 23,
  nHashType_eid = 24, fTTSubdet = 25, fTTSubdetPM = 26, fTTSubdetPMiphi = 27,
  fTTSubdetieta = 28, fTTdepth = 29, fTChannel = 30, nHashType_tid = 31,
  nHashType = 32
}
 

Functions

uint32_t hash_Crate (HcalElectronicsId const &)
 
uint32_t hash_Crate (std::string const &)
 
uint32_t hash_CrateSlot (HcalElectronicsId const &)
 
uint32_t hash_CrateSlot (std::string const &)
 
uint32_t hash_CrateSpigot (HcalElectronicsId const &)
 
uint32_t hash_CrateSpigot (std::string const &)
 
uint32_t hash_DChannel (HcalDetId const &)
 
uint32_t hash_DChannel (std::string const &)
 
uint32_t hash_depth (HcalDetId const &)
 
uint32_t hash_depth (std::string const &)
 
uint32_t hash_EChannel (HcalElectronicsId const &)
 
uint32_t hash_EChannel (std::string const &)
 
uint32_t hash_Electronics (HcalElectronicsId const &)
 
uint32_t hash_Electronics (std::string const &)
 
uint32_t hash_FED (HcalElectronicsId const &)
 
uint32_t hash_FED (std::string const &)
 
uint32_t hash_FEDSlot (HcalElectronicsId const &)
 
uint32_t hash_FEDSlot (std::string const &)
 
uint32_t hash_FEDSpigot (HcalElectronicsId const &)
 
uint32_t hash_FEDSpigot (std::string const &)
 
uint32_t hash_Fiber (HcalElectronicsId const &)
 
uint32_t hash_Fiber (std::string const &)
 
uint32_t hash_FiberCh (HcalElectronicsId const &)
 
uint32_t hash_FiberCh (std::string const &)
 
uint32_t hash_FiberFiberCh (HcalElectronicsId const &)
 
uint32_t hash_FiberFiberCh (std::string const &)
 
uint32_t hash_HBHEPartition (HcalDetId const &)
 
uint32_t hash_HBHEPartition (std::string const &)
 
uint32_t hash_HFPMiphi (HcalDetId const &)
 
uint32_t hash_HFPMiphi (std::string const &)
 
uint32_t hash_ieta (HcalDetId const &)
 
uint32_t hash_ieta (std::string const &)
 
uint32_t hash_iphi (HcalDetId const &)
 
uint32_t hash_iphi (std::string const &)
 
uint32_t hash_Subdet (HcalDetId const &)
 
uint32_t hash_Subdet (std::string const &)
 
uint32_t hash_Subdetdepth (HcalDetId const &)
 
uint32_t hash_Subdetdepth (std::string const &)
 
uint32_t hash_Subdetieta (HcalDetId const &)
 
uint32_t hash_Subdetieta (std::string const &)
 
uint32_t hash_Subdetiphi (HcalDetId const &)
 
uint32_t hash_Subdetiphi (std::string const &)
 
uint32_t hash_SubdetPM (HcalDetId const &)
 
uint32_t hash_SubdetPM (std::string const &)
 
uint32_t hash_SubdetPMiphi (HcalDetId const &)
 
uint32_t hash_SubdetPMiphi (std::string const &)
 
uint32_t hash_TChannel (HcalTrigTowerDetId const &)
 
uint32_t hash_TChannel (std::string const &)
 
uint32_t hash_TTdepth (HcalTrigTowerDetId const &)
 
uint32_t hash_TTdepth (std::string const &)
 
uint32_t hash_TTSubdet (HcalTrigTowerDetId const &)
 
uint32_t hash_TTSubdet (std::string const &)
 
uint32_t hash_TTSubdetieta (HcalTrigTowerDetId const &)
 
uint32_t hash_TTSubdetieta (std::string const &)
 
uint32_t hash_TTSubdetPM (HcalTrigTowerDetId const &)
 
uint32_t hash_TTSubdetPM (std::string const &)
 
uint32_t hash_TTSubdetPMiphi (HcalTrigTowerDetId const &)
 
uint32_t hash_TTSubdetPMiphi (std::string const &)
 
std::string name_Crate (HcalElectronicsId const &)
 
std::string name_CrateSlot (HcalElectronicsId const &)
 
std::string name_CrateSpigot (HcalElectronicsId const &)
 
std::string name_DChannel (HcalDetId const &)
 
std::string name_depth (HcalDetId const &)
 
std::string name_EChannel (HcalElectronicsId const &)
 
std::string name_Electronics (HcalElectronicsId const &)
 
std::string name_FED (HcalElectronicsId const &)
 
std::string name_FEDSlot (HcalElectronicsId const &)
 
std::string name_FEDSpigot (HcalElectronicsId const &)
 
std::string name_Fiber (HcalElectronicsId const &)
 
std::string name_FiberCh (HcalElectronicsId const &)
 
std::string name_FiberFiberCh (HcalElectronicsId const &)
 
std::string name_HBHEPartition (HcalDetId const &)
 
std::string name_HFPMiphi (HcalDetId const &)
 
std::string name_ieta (HcalDetId const &)
 
std::string name_iphi (HcalDetId const &)
 
std::string name_Subdet (HcalDetId const &)
 
std::string name_Subdetdepth (HcalDetId const &)
 
std::string name_Subdetieta (HcalDetId const &)
 
std::string name_Subdetiphi (HcalDetId const &)
 
std::string name_SubdetPM (HcalDetId const &)
 
std::string name_SubdetPMiphi (HcalDetId const &)
 
std::string name_TChannel (HcalTrigTowerDetId const &)
 
std::string name_TTdepth (HcalTrigTowerDetId const &)
 
std::string name_TTSubdet (HcalTrigTowerDetId const &)
 
std::string name_TTSubdetieta (HcalTrigTowerDetId const &)
 
std::string name_TTSubdetPM (HcalTrigTowerDetId const &)
 
std::string name_TTSubdetPMiphi (HcalTrigTowerDetId const &)
 

Variables

hash_function_did const hash_did [nHashType_did]
 
hash_function_eid const hash_eid [nHashType_eid-nHashType_did-1]
 
std::string const hash_names [nhashes]
 
hash_function_tid const hash_tid [nHashType_tid-nHashType_eid-1]
 
name_function_did const name_did [nHashType_did]
 
name_function_eid const name_eid [nHashType_eid-nHashType_did-1]
 
name_function_tid const name_tid [nHashType_tid-nHashType_eid-1]
 
int const nhashes = nHashType_did + (nHashType_eid - nHashType_did - 1) + (nHashType_tid - nHashType_eid - 1)
 

Typedef Documentation

typedef uint32_t(* hcaldqm::hashfunctions::hash_function_did) (HcalDetId const &)

Definition at line 157 of file HashFunctions.h.

typedef uint32_t(* hcaldqm::hashfunctions::hash_function_eid) (HcalElectronicsId const &)

Definition at line 158 of file HashFunctions.h.

typedef uint32_t(* hcaldqm::hashfunctions::hash_function_tid) (HcalTrigTowerDetId const &)

Definition at line 159 of file HashFunctions.h.

typedef std::string(* hcaldqm::hashfunctions::name_function_did) (HcalDetId const &)

Definition at line 160 of file HashFunctions.h.

typedef std::string(* hcaldqm::hashfunctions::name_function_eid) (HcalElectronicsId const &)

Definition at line 161 of file HashFunctions.h.

typedef std::string(* hcaldqm::hashfunctions::name_function_tid) (HcalTrigTowerDetId const &)

Definition at line 162 of file HashFunctions.h.

Enumeration Type Documentation

Enumerator
fSubdet 
fSubdetiphi 
fSubdetieta 
fSubdetdepth 
fSubdetPM 
fSubdetPMiphi 
fiphi 
fieta 
fdepth 
fHFPMiphi 
fHBHEPartition 
fDChannel 
nHashType_did 
fFED 
fFEDSpigot 
fFEDSlot 
fCrate 
fCrateSpigot 
fCrateSlot 
fFiber 
fFiberFiberCh 
fFiberCh 
fElectronics 
fEChannel 
nHashType_eid 
fTTSubdet 
fTTSubdetPM 
fTTSubdetPMiphi 
fTTSubdetieta 
fTTdepth 
fTChannel 
nHashType_tid 
nHashType 

Definition at line 122 of file HashFunctions.h.

122  {
123  fSubdet = 0,
124  fSubdetiphi = 1,
125  fSubdetieta = 2,
126  fSubdetdepth = 3,
127  fSubdetPM = 4,
128  fSubdetPMiphi = 5,
129  fiphi = 6,
130  fieta = 7,
131  fdepth = 8,
132  fHFPMiphi = 9,
133  fHBHEPartition = 10,
134  fDChannel = 11,
135  nHashType_did = 12,
136  fFED = 13,
137  fFEDSpigot = 14,
138  fFEDSlot = 15,
139  fCrate = 16,
140  fCrateSpigot = 17,
141  fCrateSlot = 18,
142  fFiber = 19,
143  fFiberFiberCh = 20,
144  fFiberCh = 21,
145  fElectronics = 22,
146  fEChannel = 23,
147  nHashType_eid = 24,
148  fTTSubdet = 25,
149  fTTSubdetPM = 26,
150  fTTSubdetPMiphi = 27,
151  fTTSubdetieta = 28,
152  fTTdepth = 29,
153  fTChannel = 30,
154  nHashType_tid = 31,
155  nHashType = 32
156  };

Function Documentation

uint32_t hcaldqm::hashfunctions::hash_Crate ( HcalElectronicsId const &  eid)

Definition at line 257 of file HashFunctions.cc.

References HcalElectronicsId::crateId(), HcalElectronicsId::dccid(), hcaldqm::constants::FIBER_uTCA_MIN1, hcaldqm::constants::FIBER_VME_MIN, hcaldqm::constants::FIBERCH_MIN, hcaldqm::utilities::hash(), HcalElectronicsId::isVMEid(), hcaldqm::constants::SLOT_uTCA_MIN, and hcaldqm::constants::SPIGOT_MIN.

257  {
258  // note hashing of VME is done with dccId
259  // note 2: there are two dccids per crate, <even> and <even+1>. We don't
260  // care about this, so use the even one.
261  return eid.isVMEid()
263  FIBERCH_MIN, FIBER_VME_MIN, SPIGOT_MIN, (eid.dccid() % 2 == 0 ? eid.dccid() : eid.dccid() - 1)))
264  : utilities::hash(
266  }
int const SPIGOT_MIN
Definition: Constants.h:116
int const FIBER_VME_MIN
Definition: Constants.h:121
int const FIBERCH_MIN
Definition: Constants.h:130
int const FIBER_uTCA_MIN1
Definition: Constants.h:124
Readout chain identification for Hcal.
int const SLOT_uTCA_MIN
Definition: Constants.h:103
uint32_t hcaldqm::hashfunctions::hash_Crate ( std::string const &  )

Definition at line 395 of file HashFunctions.cc.

References HcalElectronicsId::rawId().

395 { return HcalElectronicsId().rawId(); }
constexpr uint32_t rawId() const
Readout chain identification for Hcal.
uint32_t hcaldqm::hashfunctions::hash_CrateSlot ( HcalElectronicsId const &  eid)
uint32_t hcaldqm::hashfunctions::hash_CrateSlot ( std::string const &  )

Definition at line 413 of file HashFunctions.cc.

References HcalElectronicsId::rawId().

413 { return HcalElectronicsId().rawId(); }
constexpr uint32_t rawId() const
Readout chain identification for Hcal.
uint32_t hcaldqm::hashfunctions::hash_CrateSpigot ( HcalElectronicsId const &  eid)

Definition at line 268 of file HashFunctions.cc.

References HcalElectronicsId::crateId(), HcalElectronicsId::dccid(), hcaldqm::constants::FIBER_uTCA_MIN1, hcaldqm::constants::FIBER_VME_MIN, hcaldqm::constants::FIBERCH_MIN, hcaldqm::utilities::hash(), HcalElectronicsId::isVMEid(), HcalElectronicsId::slot(), and HcalElectronicsId::spigot().

268  {
269  // note hashing of VME is done with dccid and
270  // uTCA with Slots
271  return eid.isVMEid()
273  FIBERCH_MIN, FIBER_VME_MIN, eid.spigot(), (eid.dccid() % 2 == 0 ? eid.dccid() : eid.dccid() - 1)))
274  : utilities::hash(HcalElectronicsId(eid.crateId(), eid.slot(), FIBER_uTCA_MIN1, FIBERCH_MIN, false));
275  }
int const FIBER_VME_MIN
Definition: Constants.h:121
int const FIBERCH_MIN
Definition: Constants.h:130
int const FIBER_uTCA_MIN1
Definition: Constants.h:124
Readout chain identification for Hcal.
uint32_t hcaldqm::hashfunctions::hash_CrateSpigot ( std::string const &  )

Definition at line 404 of file HashFunctions.cc.

References HcalElectronicsId::rawId().

404 { return HcalElectronicsId().rawId(); }
constexpr uint32_t rawId() const
Readout chain identification for Hcal.
uint32_t hcaldqm::hashfunctions::hash_DChannel ( HcalDetId const &  did)

Definition at line 55 of file HashFunctions.cc.

References hcaldqm::utilities::hash().

55 { return utilities::hash(did); }
uint32_t hcaldqm::hashfunctions::hash_DChannel ( std::string const &  name)

Definition at line 226 of file HashFunctions.cc.

References HcalBarrel, and DetId::rawId().

226 { return HcalDetId(HcalBarrel, 1, 1, 1).rawId(); }
constexpr uint32_t rawId() const
get the raw id
Definition: DetId.h:50
uint32_t hcaldqm::hashfunctions::hash_depth ( HcalDetId const &  did)

Definition at line 36 of file HashFunctions.cc.

References HcalDetId::depth(), hcaldqm::utilities::hash(), and HcalBarrel.

36 { return utilities::hash(HcalDetId(HcalBarrel, 1, 1, did.depth())); }
uint32_t hcaldqm::hashfunctions::hash_depth ( std::string const &  name)

Definition at line 176 of file HashFunctions.cc.

References egammaForCoreTracking_cff::depth, HcalBarrel, and DetId::rawId().

176  {
177  int depth = std::stoi(name.substr(5, name.length() - 5), nullptr);
178  return HcalDetId(HcalBarrel, 1, 1, depth).rawId();
179  }
constexpr uint32_t rawId() const
get the raw id
Definition: DetId.h:50
uint32_t hcaldqm::hashfunctions::hash_EChannel ( HcalElectronicsId const &  eid)

Definition at line 312 of file HashFunctions.cc.

References HcalElectronicsId::crateId(), HcalElectronicsId::dccid(), HcalElectronicsId::fiberChanId(), HcalElectronicsId::fiberIndex(), hcaldqm::utilities::hash(), HcalElectronicsId::isVMEid(), HcalElectronicsId::slot(), and HcalElectronicsId::spigot().

Referenced by hcaldqm::electronicsmap::ElectronicsMap::initialize().

312  {
313  return eid.isVMEid()
314  ? utilities::hash(HcalElectronicsId(eid.fiberChanId(), eid.fiberIndex(), eid.spigot(), eid.dccid()))
315  : utilities::hash(
316  HcalElectronicsId(eid.crateId(), eid.slot(), eid.fiberIndex(), eid.fiberChanId(), false));
317  }
Readout chain identification for Hcal.
uint32_t hcaldqm::hashfunctions::hash_EChannel ( std::string const &  )

Definition at line 453 of file HashFunctions.cc.

References HcalElectronicsId::rawId().

453 { return HcalElectronicsId().rawId(); }
constexpr uint32_t rawId() const
Readout chain identification for Hcal.
uint32_t hcaldqm::hashfunctions::hash_Electronics ( HcalElectronicsId const &  eid)

Definition at line 290 of file HashFunctions.cc.

References hcaldqm::constants::CRATE_uTCA_MIN, hcaldqm::constants::CRATE_VME_MIN, hcaldqm::constants::FIBER_uTCA_MIN1, hcaldqm::constants::FIBER_VME_MIN, hcaldqm::constants::FIBERCH_MIN, hcaldqm::utilities::hash(), HcalElectronicsId::isVMEid(), hcaldqm::constants::SLOT_uTCA_MIN, and hcaldqm::constants::SPIGOT_MIN.

290  {
292  : utilities::hash(
294  /* NOTE: as an update - should separate Trigger Eid and Det
295  Eid * return eid.isVMEid() ? eid.isTriggerChainId()?
296  utilities::hash(HcalElectronicsId(SLBCH_MIN,
297  SLB_MIN, SPIGOT_MIN,
298  CRATE_VME_MIN, CRATE_VME_MIN, SLOT_VME_MIN1, 0)):
299  utilities::hash(HcalElectronicsId(FIBERCH_MIN,
300  FIBER_VME_MIN, SPIGOT_MIN,
301  CRATE_VME_MIN))
302  :
303  eid.isTriggerChainId()?
304  utilities::hash(HcalElectronicsId(CRATE_uTCA_MIN,
305  SLOT_uTCA_MIN, TPFIBER_MIN,
306  TPFIBERCH_MIN, true)): utilities::hash(HcalElectronicsId(CRATE_uTCA_MIN,
307  SLOT_uTCA_MIN, FIBER_uTCA_MIN1,
308  FIBERCH_MIN, false));
309  */
310  }
int const CRATE_VME_MIN
Definition: Constants.h:91
int const SPIGOT_MIN
Definition: Constants.h:116
int const FIBER_VME_MIN
Definition: Constants.h:121
int const FIBERCH_MIN
Definition: Constants.h:130
int const FIBER_uTCA_MIN1
Definition: Constants.h:124
int const CRATE_uTCA_MIN
Definition: Constants.h:96
Readout chain identification for Hcal.
int const SLOT_uTCA_MIN
Definition: Constants.h:103
uint32_t hcaldqm::hashfunctions::hash_Electronics ( std::string const &  name)
uint32_t hcaldqm::hashfunctions::hash_FED ( HcalElectronicsId const &  eid)

by ElectronicsId

Definition at line 231 of file HashFunctions.cc.

References HcalElectronicsId::crateId(), HcalElectronicsId::dccid(), hcaldqm::constants::FIBER_uTCA_MIN1, hcaldqm::constants::FIBER_VME_MIN, hcaldqm::constants::FIBERCH_MIN, hcaldqm::utilities::hash(), HcalElectronicsId::isVMEid(), HcalElectronicsId::slot(), hcaldqm::constants::SLOT_uTCA_MIN, and hcaldqm::constants::SPIGOT_MIN.

231  {
232  if (eid.isVMEid())
234  else {
235  // tmp - we need to hash HF's FEDs with slot in mind
236  // bool isHF = eid.crateId()==22 || eid.crateId()==29 || eid.crateId()==32;
237  // for HF, slot number is either
238  int slotToUse = eid.slot() > 6 ? SLOT_uTCA_MIN + 6 : SLOT_uTCA_MIN;
239  return utilities::hash(HcalElectronicsId(eid.crateId(), slotToUse, FIBER_uTCA_MIN1, FIBERCH_MIN, false));
240  }
241  }
int const SPIGOT_MIN
Definition: Constants.h:116
int const FIBER_VME_MIN
Definition: Constants.h:121
int const FIBERCH_MIN
Definition: Constants.h:130
int const FIBER_uTCA_MIN1
Definition: Constants.h:124
Readout chain identification for Hcal.
int const SLOT_uTCA_MIN
Definition: Constants.h:103
uint32_t hcaldqm::hashfunctions::hash_FED ( std::string const &  name)

Definition at line 325 of file HashFunctions.cc.

References hcaldqm::utilities::fed2crate(), hcaldqm::constants::FED_uTCA_MIN, hcaldqm::constants::FED_VME_MIN, hcaldqm::constants::FIBER_uTCA_MIN1, hcaldqm::constants::FIBER_VME_MIN, hcaldqm::constants::FIBERCH_MIN, HcalElectronicsId::rawId(), and hcaldqm::constants::SPIGOT_MIN.

325  {
326  int fed = std::stoi(name.substr(3, name.length() - 3), nullptr);
327  if (fed >= constants::FED_uTCA_MIN) {
328  std::pair<uint16_t, uint16_t> cspair = utilities::fed2crate(fed);
329  return HcalElectronicsId(cspair.first, cspair.second, FIBER_uTCA_MIN1, FIBERCH_MIN, false).rawId();
330  } else
332 
333  return HcalElectronicsId().rawId();
334  }
constexpr uint32_t rawId() const
std::pair< uint16_t, uint16_t > fed2crate(int fed)
Definition: Utilities.cc:10
int const SPIGOT_MIN
Definition: Constants.h:116
int const FIBER_VME_MIN
Definition: Constants.h:121
int const FED_uTCA_MIN
Definition: Constants.h:83
int const FIBERCH_MIN
Definition: Constants.h:130
int const FED_VME_MIN
Definition: Constants.h:78
int const FIBER_uTCA_MIN1
Definition: Constants.h:124
Readout chain identification for Hcal.
uint32_t hcaldqm::hashfunctions::hash_FEDSlot ( HcalElectronicsId const &  eid)
uint32_t hcaldqm::hashfunctions::hash_FEDSlot ( std::string const &  name)

Definition at line 367 of file HashFunctions.cc.

References hcaldqm::utilities::fed2crate(), hcaldqm::constants::FED_uTCA_MIN, hcaldqm::constants::FED_VME_MIN, hcaldqm::constants::FIBER_uTCA_MIN1, hcaldqm::constants::FIBER_VME_MIN, hcaldqm::constants::FIBERCH_MIN, HcalElectronicsId::rawId(), and alignCSCRings::s.

367  {
368  int pos = name.find("S");
369  int fed = std::stoi(name.substr(3, pos - 3), nullptr);
370  int s = std::stoi(name.substr(pos + 1, name.length() - pos - 1), nullptr);
371  if (fed >= FED_uTCA_MIN) {
372  std::pair<uint16_t, uint16_t> cspair = utilities::fed2crate(fed);
373  return HcalElectronicsId(cspair.first, cspair.second, FIBER_uTCA_MIN1, FIBERCH_MIN, false).rawId();
374  } else
376 
377  return HcalElectronicsId().rawId();
378  }
constexpr uint32_t rawId() const
std::pair< uint16_t, uint16_t > fed2crate(int fed)
Definition: Utilities.cc:10
int const FIBER_VME_MIN
Definition: Constants.h:121
int const FED_uTCA_MIN
Definition: Constants.h:83
int const FIBERCH_MIN
Definition: Constants.h:130
int const FED_VME_MIN
Definition: Constants.h:78
int const FIBER_uTCA_MIN1
Definition: Constants.h:124
Readout chain identification for Hcal.
uint32_t hcaldqm::hashfunctions::hash_FEDSpigot ( HcalElectronicsId const &  eid)
uint32_t hcaldqm::hashfunctions::hash_FEDSpigot ( std::string const &  name)

Definition at line 345 of file HashFunctions.cc.

References hcaldqm::utilities::fed2crate(), hcaldqm::constants::FED_uTCA_MIN, hcaldqm::constants::FED_VME_MIN, hcaldqm::constants::FIBER_uTCA_MIN1, hcaldqm::constants::FIBER_VME_MIN, hcaldqm::constants::FIBERCH_MIN, HcalElectronicsId::rawId(), and alignCSCRings::s.

345  {
346  int pos = name.find("S");
347  int fed = std::stoi(name.substr(3, pos - 3), nullptr);
348  int s = std::stoi(name.substr(pos + 1, name.length() - pos - 1), nullptr);
349  if (fed >= FED_uTCA_MIN) {
350  std::pair<uint16_t, uint16_t> cspair = utilities::fed2crate(fed);
351  return HcalElectronicsId(cspair.first, cspair.second, FIBER_uTCA_MIN1, FIBERCH_MIN, false).rawId();
352  } else
354 
355  return HcalElectronicsId().rawId();
356  }
constexpr uint32_t rawId() const
std::pair< uint16_t, uint16_t > fed2crate(int fed)
Definition: Utilities.cc:10
int const FIBER_VME_MIN
Definition: Constants.h:121
int const FED_uTCA_MIN
Definition: Constants.h:83
int const FIBERCH_MIN
Definition: Constants.h:130
int const FED_VME_MIN
Definition: Constants.h:78
int const FIBER_uTCA_MIN1
Definition: Constants.h:124
Readout chain identification for Hcal.
uint32_t hcaldqm::hashfunctions::hash_Fiber ( HcalElectronicsId const &  )

Definition at line 284 of file HashFunctions.cc.

284 { return 0; }
uint32_t hcaldqm::hashfunctions::hash_Fiber ( std::string const &  )

Definition at line 418 of file HashFunctions.cc.

References HcalElectronicsId::rawId().

418 { return HcalElectronicsId().rawId(); }
constexpr uint32_t rawId() const
Readout chain identification for Hcal.
uint32_t hcaldqm::hashfunctions::hash_FiberCh ( HcalElectronicsId const &  eid)

Definition at line 288 of file HashFunctions.cc.

288 { return 0; }
uint32_t hcaldqm::hashfunctions::hash_FiberCh ( std::string const &  )

Definition at line 428 of file HashFunctions.cc.

References HcalElectronicsId::rawId().

428 { return HcalElectronicsId().rawId(); }
constexpr uint32_t rawId() const
Readout chain identification for Hcal.
uint32_t hcaldqm::hashfunctions::hash_FiberFiberCh ( HcalElectronicsId const &  )

Definition at line 286 of file HashFunctions.cc.

286 { return 0; }
uint32_t hcaldqm::hashfunctions::hash_FiberFiberCh ( std::string const &  )

Definition at line 423 of file HashFunctions.cc.

References HcalElectronicsId::rawId().

423 { return HcalElectronicsId().rawId(); }
constexpr uint32_t rawId() const
Readout chain identification for Hcal.
uint32_t hcaldqm::hashfunctions::hash_HBHEPartition ( HcalDetId const &  did)

Definition at line 42 of file HashFunctions.cc.

References cond::hash, hcaldqm::utilities::hash(), HcalBarrel, and HcalDetId::iphi().

42  {
43  int iphi = did.iphi();
44  uint32_t hash = 0;
45  if (iphi >= 3 && iphi <= 26)
46  hash = utilities::hash(HcalDetId(HcalBarrel, 1, 3, 1));
47  else if (iphi >= 27 && iphi <= 50)
48  hash = utilities::hash(HcalDetId(HcalBarrel, 1, 27, 1));
49  else
50  hash = utilities::hash(HcalDetId(HcalBarrel, 1, 1, 1));
51 
52  return hash;
53  }
uint32_t hcaldqm::hashfunctions::hash_HBHEPartition ( std::string const &  name)

Definition at line 206 of file HashFunctions.cc.

References HcalBarrel, and DetId::rawId().

206  {
207  if (name[4] == 'a')
208  return HcalDetId(HcalBarrel, 1, 5, 1).rawId();
209  else if (name[4] == 'b')
210  return HcalDetId(HcalBarrel, 1, 29, 1).rawId();
211  else
212  return HcalDetId(HcalBarrel, 1, 55, 1).rawId();
213 
214  return HcalDetId().rawId();
215  }
constexpr uint32_t rawId() const
get the raw id
Definition: DetId.h:50
uint32_t hcaldqm::hashfunctions::hash_HFPMiphi ( HcalDetId const &  did)

Definition at line 38 of file HashFunctions.cc.

References hcaldqm::utilities::hash(), HcalForward, HcalDetId::ieta(), and HcalDetId::iphi().

38  {
39  return utilities::hash(HcalDetId(HcalForward, did.ieta() > 0 ? 1 : -1, did.iphi(), 1));
40  }
uint32_t hcaldqm::hashfunctions::hash_HFPMiphi ( std::string const &  name)

Definition at line 187 of file HashFunctions.cc.

References HcalForward, and DetId::rawId().

187  {
188  int iphi = std::stoi(name.substr(7, name.length() - 7), nullptr);
189  int ieta = name[2] == 'P' ? 1 : -1;
190  return HcalDetId(HcalForward, ieta, iphi, 1).rawId();
191  }
constexpr uint32_t rawId() const
get the raw id
Definition: DetId.h:50
uint32_t hcaldqm::hashfunctions::hash_ieta ( HcalDetId const &  did)

Definition at line 34 of file HashFunctions.cc.

References hcaldqm::utilities::hash(), HcalBarrel, and HcalDetId::ieta().

34 { return utilities::hash(HcalDetId(HcalBarrel, did.ieta(), 1, 1)); }
uint32_t hcaldqm::hashfunctions::hash_ieta ( std::string const &  name)

Definition at line 165 of file HashFunctions.cc.

References HcalBarrel, and DetId::rawId().

165  {
166  int ieta = std::stoi(name.substr(4, name.length() - 4), nullptr);
167  return HcalDetId(HcalBarrel, ieta, 1, 1).rawId();
168  }
constexpr uint32_t rawId() const
get the raw id
Definition: DetId.h:50
uint32_t hcaldqm::hashfunctions::hash_iphi ( HcalDetId const &  did)

Definition at line 32 of file HashFunctions.cc.

References hcaldqm::utilities::hash(), HcalBarrel, and HcalDetId::iphi().

32 { return utilities::hash(HcalDetId(HcalBarrel, 1, did.iphi(), 1)); }
uint32_t hcaldqm::hashfunctions::hash_iphi ( std::string const &  name)

Definition at line 154 of file HashFunctions.cc.

References HcalBarrel, and DetId::rawId().

154  {
155  int iphi = std::stoi(name.substr(4, name.length() - 4), nullptr);
156  return HcalDetId(HcalBarrel, 1, iphi, 1).rawId();
157  }
constexpr uint32_t rawId() const
get the raw id
Definition: DetId.h:50
uint32_t hcaldqm::hashfunctions::hash_Subdet ( HcalDetId const &  did)

by HcalDetId

HcalDetId

Definition at line 10 of file HashFunctions.cc.

References hcaldqm::utilities::hash(), and HcalDetId::subdet().

Referenced by DigiTask::endLuminosityBlock().

10 { return utilities::hash(HcalDetId(did.subdet(), 1, 1, 1)); }
uint32_t hcaldqm::hashfunctions::hash_Subdet ( std::string const &  name)

Definition at line 59 of file HashFunctions.cc.

References mps_fire::i, DetId::rawId(), hcaldqm::constants::SUBDET_NAME, and hcaldqm::constants::SUBDET_NUM.

59  {
60  for (int i = 0; i < constants::SUBDET_NUM; i++)
62  return (HcalDetId((HcalSubdetector)(i + 1), 1, 1, 1).rawId());
63 
64  return HcalDetId().rawId();
65  }
int const SUBDET_NUM
Definition: Constants.h:160
constexpr uint32_t rawId() const
get the raw id
Definition: DetId.h:50
std::string const SUBDET_NAME[SUBDET_NUM]
Definition: Constants.h:162
HcalSubdetector
Definition: HcalAssistant.h:31
uint32_t hcaldqm::hashfunctions::hash_Subdetdepth ( HcalDetId const &  did)

Definition at line 20 of file HashFunctions.cc.

References HcalDetId::depth(), hcaldqm::utilities::hash(), and HcalDetId::subdet().

20  {
21  return utilities::hash(HcalDetId(did.subdet(), 1, 1, did.depth()));
22  }
uint32_t hcaldqm::hashfunctions::hash_Subdetdepth ( std::string const &  name)

Definition at line 121 of file HashFunctions.cc.

References egammaForCoreTracking_cff::depth, mps_fire::i, DetId::rawId(), AlCaHLTBitMon_QueryRunRegistry::string, hcaldqm::constants::SUBDET_NAME, and hcaldqm::constants::SUBDET_NUM.

121  {
122  std::string sub = name.substr(0, 2);
123  int depth = std::stoi(name.substr(7, name.length() - 7), nullptr);
124  for (int i = 0; i < constants::SUBDET_NUM; i++)
125  if (constants::SUBDET_NAME[i] == sub)
126  return HcalDetId((HcalSubdetector)(i + 1), 1, 1, depth).rawId();
127 
128  return HcalDetId().rawId();
129  }
int const SUBDET_NUM
Definition: Constants.h:160
constexpr uint32_t rawId() const
get the raw id
Definition: DetId.h:50
std::string const SUBDET_NAME[SUBDET_NUM]
Definition: Constants.h:162
HcalSubdetector
Definition: HcalAssistant.h:31
uint32_t hcaldqm::hashfunctions::hash_Subdetieta ( HcalDetId const &  did)

Definition at line 16 of file HashFunctions.cc.

References hcaldqm::utilities::hash(), HcalDetId::ieta(), and HcalDetId::subdet().

16  {
17  return utilities::hash(HcalDetId(did.subdet(), did.ieta(), 1, 1));
18  }
uint32_t hcaldqm::hashfunctions::hash_Subdetieta ( std::string const &  name)

Definition at line 104 of file HashFunctions.cc.

References mps_fire::i, DetId::rawId(), AlCaHLTBitMon_QueryRunRegistry::string, hcaldqm::constants::SUBDET_NAME, and hcaldqm::constants::SUBDET_NUM.

104  {
105  std::string sub = name.substr(0, 2);
106  int ieta = std::stoi(name.substr(6, name.length() - 6), nullptr);
107  for (int i = 0; i < constants::SUBDET_NUM; i++)
108  if (constants::SUBDET_NAME[i] == sub)
109  return HcalDetId((HcalSubdetector)(i + 1), ieta, 1, 1).rawId();
110 
111  // default
112  return HcalDetId().rawId();
113  }
int const SUBDET_NUM
Definition: Constants.h:160
constexpr uint32_t rawId() const
get the raw id
Definition: DetId.h:50
std::string const SUBDET_NAME[SUBDET_NUM]
Definition: Constants.h:162
HcalSubdetector
Definition: HcalAssistant.h:31
uint32_t hcaldqm::hashfunctions::hash_Subdetiphi ( HcalDetId const &  did)

Definition at line 12 of file HashFunctions.cc.

References hcaldqm::utilities::hash(), HcalDetId::iphi(), and HcalDetId::subdet().

12  {
13  return utilities::hash(HcalDetId(did.subdet(), 1, did.iphi(), 1));
14  }
uint32_t hcaldqm::hashfunctions::hash_Subdetiphi ( std::string const &  name)

Definition at line 87 of file HashFunctions.cc.

References mps_fire::i, DetId::rawId(), AlCaHLTBitMon_QueryRunRegistry::string, hcaldqm::constants::SUBDET_NAME, and hcaldqm::constants::SUBDET_NUM.

87  {
88  std::string sub = name.substr(0, 2);
89  int iphi = std::stoi(name.substr(6, name.length() - 6), nullptr);
90  for (int i = 0; i < constants::SUBDET_NUM; i++)
91  if (constants::SUBDET_NAME[i] == sub)
92  return HcalDetId((HcalSubdetector)(i + 1), 1, iphi, 1).rawId();
93 
94  // default
95  return HcalDetId().rawId();
96  }
int const SUBDET_NUM
Definition: Constants.h:160
constexpr uint32_t rawId() const
get the raw id
Definition: DetId.h:50
std::string const SUBDET_NAME[SUBDET_NUM]
Definition: Constants.h:162
HcalSubdetector
Definition: HcalAssistant.h:31
uint32_t hcaldqm::hashfunctions::hash_SubdetPM ( HcalDetId const &  did)

Definition at line 24 of file HashFunctions.cc.

References hcaldqm::utilities::hash(), HcalDetId::ieta(), and HcalDetId::subdet().

24  {
25  return utilities::hash(HcalDetId(did.subdet(), did.ieta() > 0 ? 1 : -1, 1, 1));
26  }
uint32_t hcaldqm::hashfunctions::hash_SubdetPM ( std::string const &  name)

Definition at line 73 of file HashFunctions.cc.

References mps_fire::i, DetId::rawId(), hcaldqm::constants::SUBDET_NUM, and hcaldqm::constants::SUBDETPM_NAME.

73  {
74  for (int i = 0; i < constants::SUBDET_NUM * 2; i++)
76  return HcalDetId((HcalSubdetector)(i / 2 + 1), i % 2 == 0 ? -1 : 1, 1, 1).rawId();
77 
78  return HcalDetId().rawId();
79  }
int const SUBDET_NUM
Definition: Constants.h:160
constexpr uint32_t rawId() const
get the raw id
Definition: DetId.h:50
std::string const SUBDETPM_NAME[2 *SUBDET_NUM]
Definition: Constants.h:163
HcalSubdetector
Definition: HcalAssistant.h:31
uint32_t hcaldqm::hashfunctions::hash_SubdetPMiphi ( HcalDetId const &  did)

Definition at line 28 of file HashFunctions.cc.

References hcaldqm::utilities::hash(), HcalDetId::ieta(), HcalDetId::iphi(), and HcalDetId::subdet().

28  {
29  return utilities::hash(HcalDetId(did.subdet(), did.ieta() > 0 ? 1 : -1, did.iphi(), 1));
30  }
uint32_t hcaldqm::hashfunctions::hash_SubdetPMiphi ( std::string const &  name)

Definition at line 138 of file HashFunctions.cc.

References mps_fire::i, DetId::rawId(), AlCaHLTBitMon_QueryRunRegistry::string, hcaldqm::constants::SUBDET_NUM, and hcaldqm::constants::SUBDETPM_NAME.

138  {
139  std::string sub = name.substr(0, 3);
140  int iphi = std::stoi(name.substr(7, name.length() - 7), nullptr);
141  for (int i = 0; i < constants::SUBDET_NUM * 2; i++)
142  if (constants::SUBDETPM_NAME[i] == sub)
143  return HcalDetId((HcalSubdetector)(i / 2 + 1), i % 2 == 0 ? -1 : 1, iphi, 1).rawId();
144 
145  return HcalDetId().rawId();
146  }
int const SUBDET_NUM
Definition: Constants.h:160
constexpr uint32_t rawId() const
get the raw id
Definition: DetId.h:50
std::string const SUBDETPM_NAME[2 *SUBDET_NUM]
Definition: Constants.h:163
HcalSubdetector
Definition: HcalAssistant.h:31
uint32_t hcaldqm::hashfunctions::hash_TChannel ( HcalTrigTowerDetId const &  tid)

Definition at line 478 of file HashFunctions.cc.

References HcalTrigTowerDetId::depth(), hcaldqm::utilities::hash(), HcalTrigTowerDetId::ieta(), and HcalTrigTowerDetId::iphi().

478  {
479  return utilities::hash(HcalTrigTowerDetId(tid.ieta(), tid.iphi(), tid.depth()));
480  }
uint32_t hcaldqm::hashfunctions::hash_TChannel ( std::string const &  )

Definition at line 557 of file HashFunctions.cc.

References DetId::rawId().

557 { return HcalTrigTowerDetId().rawId(); }
constexpr uint32_t rawId() const
get the raw id
Definition: DetId.h:50
uint32_t hcaldqm::hashfunctions::hash_TTdepth ( HcalTrigTowerDetId const &  tid)

Definition at line 474 of file HashFunctions.cc.

References HcalTrigTowerDetId::depth(), and hcaldqm::utilities::hash().

474  {
475  return utilities::hash(HcalTrigTowerDetId(1, 1, tid.depth()));
476  }
uint32_t hcaldqm::hashfunctions::hash_TTdepth ( std::string const &  name)

Definition at line 545 of file HashFunctions.cc.

References egammaForCoreTracking_cff::depth.

545  {
546  int depth = std::stoi(name.substr(5, name.length() - 5), nullptr);
547  return HcalTrigTowerDetId(1, 1, depth);
548  }
uint32_t hcaldqm::hashfunctions::hash_TTSubdet ( HcalTrigTowerDetId const &  tid)

by TrigTowerDetId

Definition at line 458 of file HashFunctions.cc.

References hcaldqm::utilities::hash(), and HcalTrigTowerDetId::ietaAbs().

458  {
459  return utilities::hash(HcalTrigTowerDetId(tid.ietaAbs() >= 29 ? 29 : 1, 1));
460  }
uint32_t hcaldqm::hashfunctions::hash_TTSubdet ( std::string const &  name)

Definition at line 486 of file HashFunctions.cc.

References DetId::rawId().

486  {
487  if (name == "HBHE")
488  return HcalTrigTowerDetId(1, 1).rawId();
489  else
490  return HcalTrigTowerDetId(29, 1).rawId();
491 
492  return HcalTrigTowerDetId().rawId();
493  }
constexpr uint32_t rawId() const
get the raw id
Definition: DetId.h:50
uint32_t hcaldqm::hashfunctions::hash_TTSubdetieta ( HcalTrigTowerDetId const &  tid)

Definition at line 472 of file HashFunctions.cc.

472 { return 0; }
uint32_t hcaldqm::hashfunctions::hash_TTSubdetieta ( std::string const &  )

Definition at line 537 of file HashFunctions.cc.

References DetId::rawId().

537 { return HcalTrigTowerDetId().rawId(); }
constexpr uint32_t rawId() const
get the raw id
Definition: DetId.h:50
uint32_t hcaldqm::hashfunctions::hash_TTSubdetPM ( HcalTrigTowerDetId const &  tid)

Definition at line 462 of file HashFunctions.cc.

References hcaldqm::utilities::hash(), HcalTrigTowerDetId::ieta(), and HcalTrigTowerDetId::ietaAbs().

462  {
463  return utilities::hash(
464  HcalTrigTowerDetId(tid.ietaAbs() < 29 ? (tid.ieta() < 0 ? -1 : 1) : (tid.ieta() < 0 ? -29 : 29), 1));
465  }
uint32_t hcaldqm::hashfunctions::hash_TTSubdetPM ( std::string const &  name)

Definition at line 499 of file HashFunctions.cc.

References DetId::rawId().

499  {
500  if (name == "HBHEM")
501  return HcalTrigTowerDetId(-1, 1).rawId();
502  else if (name == "HBHEP")
503  return HcalTrigTowerDetId(1, 1).rawId();
504  else if (name == "HFM")
505  return HcalTrigTowerDetId(-29, 1).rawId();
506  else
507  return HcalTrigTowerDetId(29, 1).rawId();
508 
509  return HcalTrigTowerDetId().rawId();
510  }
constexpr uint32_t rawId() const
get the raw id
Definition: DetId.h:50
uint32_t hcaldqm::hashfunctions::hash_TTSubdetPMiphi ( HcalTrigTowerDetId const &  tid)

Definition at line 467 of file HashFunctions.cc.

References hcaldqm::utilities::hash(), HcalTrigTowerDetId::ieta(), HcalTrigTowerDetId::ietaAbs(), and HcalTrigTowerDetId::iphi().

467  {
468  return utilities::hash(
469  HcalTrigTowerDetId(tid.ietaAbs() < 29 ? (tid.ieta() < 0 ? 0 : 1) : (tid.ieta() < 0 ? 2 : 3), tid.iphi()));
470  }
uint32_t hcaldqm::hashfunctions::hash_TTSubdetPMiphi ( std::string const &  name)

Definition at line 518 of file HashFunctions.cc.

References DetId::rawId(), and AlCaHLTBitMon_QueryRunRegistry::string.

518  {
519  int pos = name.find("iphi");
520  std::string sub = name.substr(0, pos);
521  int iphi = std::stoi(name.substr(pos + 4, name.length() - pos - 4), nullptr);
522  if (name == "HBHEM")
523  return HcalTrigTowerDetId(-1, iphi).rawId();
524  else if (name == "HBHEP")
525  return HcalTrigTowerDetId(1, iphi).rawId();
526  else if (name == "HFM")
527  return HcalTrigTowerDetId(-29, iphi).rawId();
528  else
529  return HcalTrigTowerDetId(29, iphi).rawId();
530 
531  return HcalTrigTowerDetId().rawId();
532  }
constexpr uint32_t rawId() const
get the raw id
Definition: DetId.h:50
std::string hcaldqm::hashfunctions::name_Crate ( HcalElectronicsId const &  eid)

Definition at line 380 of file HashFunctions.cc.

References HcalElectronicsId::crateId(), dataset::name, and AlCaHLTBitMon_QueryRunRegistry::string.

380  {
381  char name[16];
382  sprintf(name, "Crate%d", eid.crateId());
383 
384  // Note: previous, different hashes were returned for the two dccids in a VME
385  // crate. These now count as one crate.
386  // if (eid.isVMEid()) {
387  // sprintf(name, "Crate%d_VME_DCC%d", eid.crateId(), eid.dccid());
388  //} else {
389  // sprintf(name, "Crate%d", eid.crateId());
390  //}
391  return std::string(name);
392  }
std::string hcaldqm::hashfunctions::name_CrateSlot ( HcalElectronicsId const &  eid)

Definition at line 406 of file HashFunctions.cc.

References HcalElectronicsId::crateId(), HcalElectronicsId::isVMEid(), dataset::name, HcalElectronicsId::slot(), HcalElectronicsId::spigot(), and AlCaHLTBitMon_QueryRunRegistry::string.

406  {
407  char name[20];
408  sprintf(name, "Crate%dS%d", eid.crateId(), eid.isVMEid() ? eid.spigot() : eid.slot());
409  return std::string(name);
410  }
std::string hcaldqm::hashfunctions::name_CrateSpigot ( HcalElectronicsId const &  eid)

Definition at line 397 of file HashFunctions.cc.

References HcalElectronicsId::crateId(), HcalElectronicsId::isVMEid(), dataset::name, HcalElectronicsId::slot(), HcalElectronicsId::spigot(), and AlCaHLTBitMon_QueryRunRegistry::string.

397  {
398  char name[20];
399  sprintf(name, "Crate%dS%d", eid.crateId(), eid.isVMEid() ? eid.spigot() : eid.slot());
400  return std::string(name);
401  }
std::string hcaldqm::hashfunctions::name_DChannel ( HcalDetId const &  did)

Definition at line 217 of file HashFunctions.cc.

References HcalDetId::depth(), HcalDetId::ieta(), HcalDetId::iphi(), dataset::name, AlCaHLTBitMon_QueryRunRegistry::string, HcalDetId::subdet(), and hcaldqm::constants::SUBDET_NAME.

217  {
218  char name[40];
219  sprintf(
220  name, "%s-%d-%d-%d", constants::SUBDET_NAME[did.subdet() - 1].c_str(), did.ieta(), did.iphi(), did.depth());
221  return std::string(name);
222  }
std::string const SUBDET_NAME[SUBDET_NUM]
Definition: Constants.h:162
std::string hcaldqm::hashfunctions::name_depth ( HcalDetId const &  did)

Definition at line 170 of file HashFunctions.cc.

References HcalDetId::depth(), dataset::name, and AlCaHLTBitMon_QueryRunRegistry::string.

170  {
171  char name[10];
172  sprintf(name, "depth%d", did.depth());
173  return std::string(name);
174  }
std::string hcaldqm::hashfunctions::name_EChannel ( HcalElectronicsId const &  eid)

Definition at line 443 of file HashFunctions.cc.

References HcalElectronicsId::crateId(), HcalElectronicsId::dccid(), HcalElectronicsId::fiberChanId(), HcalElectronicsId::fiberIndex(), HcalElectronicsId::isVMEid(), dataset::name, HcalElectronicsId::slot(), HcalElectronicsId::spigot(), and AlCaHLTBitMon_QueryRunRegistry::string.

443  {
444  char name[20];
445  if (eid.isVMEid())
446  sprintf(name, "%d-%d-%d-%d", eid.dccid(), eid.spigot(), eid.fiberIndex(), eid.fiberChanId());
447  else
448  sprintf(name, "%d-%d-%d-%d", eid.crateId(), eid.slot(), eid.fiberIndex(), eid.fiberChanId());
449  return std::string(name);
450  }
std::string hcaldqm::hashfunctions::name_Electronics ( HcalElectronicsId const &  eid)
std::string hcaldqm::hashfunctions::name_FED ( HcalElectronicsId const &  eid)

Definition at line 319 of file HashFunctions.cc.

References hcaldqm::utilities::crate2fed(), HcalElectronicsId::crateId(), HcalElectronicsId::dccid(), HcalElectronicsId::isVMEid(), dataset::name, HcalElectronicsId::slot(), and AlCaHLTBitMon_QueryRunRegistry::string.

319  {
320  char name[10];
321  sprintf(name, "FED%d", eid.isVMEid() ? eid.dccid() + 700 : utilities::crate2fed(eid.crateId(), eid.slot()));
322  return std::string(name);
323  }
uint16_t crate2fed(int crate, int slot)
Definition: Utilities.cc:27
std::string hcaldqm::hashfunctions::name_FEDSlot ( HcalElectronicsId const &  eid)

Definition at line 358 of file HashFunctions.cc.

References hcaldqm::utilities::crate2fed(), HcalElectronicsId::crateId(), HcalElectronicsId::dccid(), HcalElectronicsId::isVMEid(), dataset::name, HcalElectronicsId::slot(), HcalElectronicsId::spigot(), and AlCaHLTBitMon_QueryRunRegistry::string.

358  {
359  char name[20];
360  sprintf(name,
361  "FED%dS%d",
362  eid.isVMEid() ? eid.dccid() + 700 : utilities::crate2fed(eid.crateId(), eid.slot()),
363  eid.isVMEid() ? eid.spigot() : eid.slot());
364  return std::string(name);
365  }
uint16_t crate2fed(int crate, int slot)
Definition: Utilities.cc:27
std::string hcaldqm::hashfunctions::name_FEDSpigot ( HcalElectronicsId const &  eid)

Definition at line 336 of file HashFunctions.cc.

References hcaldqm::utilities::crate2fed(), HcalElectronicsId::crateId(), HcalElectronicsId::dccid(), HcalElectronicsId::isVMEid(), dataset::name, HcalElectronicsId::slot(), HcalElectronicsId::spigot(), and AlCaHLTBitMon_QueryRunRegistry::string.

336  {
337  char name[20];
338  sprintf(name,
339  "FED%dS%d",
340  eid.isVMEid() ? eid.dccid() + 700 : utilities::crate2fed(eid.crateId(), eid.slot()),
341  eid.isVMEid() ? eid.spigot() : eid.slot());
342  return std::string(name);
343  }
uint16_t crate2fed(int crate, int slot)
Definition: Utilities.cc:27
std::string hcaldqm::hashfunctions::name_Fiber ( HcalElectronicsId const &  )

Definition at line 415 of file HashFunctions.cc.

415 { return "None"; }
std::string hcaldqm::hashfunctions::name_FiberCh ( HcalElectronicsId const &  )

Definition at line 425 of file HashFunctions.cc.

425 { return "None"; }
std::string hcaldqm::hashfunctions::name_FiberFiberCh ( HcalElectronicsId const &  )

Definition at line 420 of file HashFunctions.cc.

420 { return "None"; }
std::string hcaldqm::hashfunctions::name_HBHEPartition ( HcalDetId const &  did)

Definition at line 193 of file HashFunctions.cc.

References EnergyCorrector::c, HcalDetId::iphi(), dataset::name, and AlCaHLTBitMon_QueryRunRegistry::string.

193  {
194  char c;
195  if (did.iphi() >= 3 && did.iphi() <= 26)
196  c = 'a';
197  else if (did.iphi() >= 27 && did.iphi() <= 50)
198  c = 'b';
199  else
200  c = 'c';
201  char name[10];
202  sprintf(name, "HBHE%c", c);
203  return std::string(name);
204  }
std::string hcaldqm::hashfunctions::name_HFPMiphi ( HcalDetId const &  did)

Definition at line 181 of file HashFunctions.cc.

References HcalDetId::ieta(), HcalDetId::iphi(), dataset::name, and AlCaHLTBitMon_QueryRunRegistry::string.

181  {
182  char name[12];
183  snprintf(name, sizeof(name), "HF%ciphi%d", did.ieta() > 0 ? 'P' : 'M', did.iphi());
184  return std::string(name);
185  }
std::string hcaldqm::hashfunctions::name_ieta ( HcalDetId const &  did)

Definition at line 159 of file HashFunctions.cc.

References HcalDetId::ieta(), dataset::name, and AlCaHLTBitMon_QueryRunRegistry::string.

159  {
160  char name[10];
161  sprintf(name, "ieta%d", did.ieta());
162  return std::string(name);
163  }
std::string hcaldqm::hashfunctions::name_iphi ( HcalDetId const &  did)

Definition at line 148 of file HashFunctions.cc.

References HcalDetId::iphi(), dataset::name, and AlCaHLTBitMon_QueryRunRegistry::string.

148  {
149  char name[10];
150  sprintf(name, "iphi%d", did.iphi());
151  return std::string(name);
152  }
std::string hcaldqm::hashfunctions::name_Subdet ( HcalDetId const &  did)

Definition at line 57 of file HashFunctions.cc.

References HcalDetId::subdet(), and hcaldqm::constants::SUBDET_NAME.

57 { return constants::SUBDET_NAME[did.subdet() - 1]; }
std::string const SUBDET_NAME[SUBDET_NUM]
Definition: Constants.h:162
std::string hcaldqm::hashfunctions::name_Subdetdepth ( HcalDetId const &  did)

Definition at line 115 of file HashFunctions.cc.

References HcalDetId::depth(), dataset::name, AlCaHLTBitMon_QueryRunRegistry::string, HcalDetId::subdet(), and hcaldqm::constants::SUBDET_NAME.

115  {
116  char name[20];
117  sprintf(name, "%sdepth%d", constants::SUBDET_NAME[did.subdet() - 1].c_str(), did.depth());
118  return std::string(name);
119  }
std::string const SUBDET_NAME[SUBDET_NUM]
Definition: Constants.h:162
std::string hcaldqm::hashfunctions::name_Subdetieta ( HcalDetId const &  did)

Definition at line 98 of file HashFunctions.cc.

References HcalDetId::ieta(), dataset::name, AlCaHLTBitMon_QueryRunRegistry::string, HcalDetId::subdet(), and hcaldqm::constants::SUBDET_NAME.

98  {
99  char name[20];
100  sprintf(name, "%sieta%d", constants::SUBDET_NAME[did.subdet() - 1].c_str(), did.ieta());
101  return std::string(name);
102  }
std::string const SUBDET_NAME[SUBDET_NUM]
Definition: Constants.h:162
std::string hcaldqm::hashfunctions::name_Subdetiphi ( HcalDetId const &  did)

Definition at line 81 of file HashFunctions.cc.

References HcalDetId::iphi(), dataset::name, AlCaHLTBitMon_QueryRunRegistry::string, HcalDetId::subdet(), and hcaldqm::constants::SUBDET_NAME.

81  {
82  char name[10];
83  sprintf(name, "%siphi%d", constants::SUBDET_NAME[did.subdet() - 1].c_str(), did.iphi());
84  return std::string(name);
85  }
std::string const SUBDET_NAME[SUBDET_NUM]
Definition: Constants.h:162
std::string hcaldqm::hashfunctions::name_SubdetPM ( HcalDetId const &  did)

Definition at line 67 of file HashFunctions.cc.

References HcalDetId::ieta(), dataset::name, AlCaHLTBitMon_QueryRunRegistry::string, HcalDetId::subdet(), and hcaldqm::constants::SUBDET_NAME.

67  {
68  char name[10];
69  sprintf(name, "%s%s", constants::SUBDET_NAME[did.subdet() - 1].c_str(), did.ieta() > 0 ? "P" : "M");
70  return std::string(name);
71  }
std::string const SUBDET_NAME[SUBDET_NUM]
Definition: Constants.h:162
std::string hcaldqm::hashfunctions::name_SubdetPMiphi ( HcalDetId const &  did)

Definition at line 131 of file HashFunctions.cc.

References HcalDetId::ieta(), HcalDetId::iphi(), dataset::name, AlCaHLTBitMon_QueryRunRegistry::string, HcalDetId::subdet(), and hcaldqm::constants::SUBDET_NAME.

131  {
132  char name[20];
133  sprintf(
134  name, "%s%siphi%d", constants::SUBDET_NAME[did.subdet() - 1].c_str(), did.ieta() > 0 ? "P" : "M", did.iphi());
135  return std::string(name);
136  }
std::string const SUBDET_NAME[SUBDET_NUM]
Definition: Constants.h:162
std::string hcaldqm::hashfunctions::name_TChannel ( HcalTrigTowerDetId const &  tid)

Definition at line 550 of file HashFunctions.cc.

References AlCaHLTBitMon_QueryRunRegistry::string.

550  {
551  std::ostringstream stream;
552  stream << tid;
553  return std::string(stream.str());
554  }
std::string hcaldqm::hashfunctions::name_TTdepth ( HcalTrigTowerDetId const &  tid)

Definition at line 539 of file HashFunctions.cc.

References HcalTrigTowerDetId::depth(), dataset::name, and AlCaHLTBitMon_QueryRunRegistry::string.

539  {
540  char name[10];
541  sprintf(name, "depth%d", tid.depth());
542  return std::string(name);
543  }
std::string hcaldqm::hashfunctions::name_TTSubdet ( HcalTrigTowerDetId const &  tid)

Definition at line 482 of file HashFunctions.cc.

References HcalTrigTowerDetId::ietaAbs(), and hcaldqm::constants::TPSUBDET_NAME.

482  {
483  return constants::TPSUBDET_NAME[tid.ietaAbs() < 29 ? 0 : 1];
484  }
std::string const TPSUBDET_NAME[TPSUBDET_NUM]
Definition: Constants.h:165
std::string hcaldqm::hashfunctions::name_TTSubdetieta ( HcalTrigTowerDetId const &  tid)

Definition at line 534 of file HashFunctions.cc.

534 { return "None"; }
std::string hcaldqm::hashfunctions::name_TTSubdetPM ( HcalTrigTowerDetId const &  tid)

Definition at line 495 of file HashFunctions.cc.

References HcalTrigTowerDetId::ieta(), HcalTrigTowerDetId::ietaAbs(), and hcaldqm::constants::TPSUBDETPM_NAME.

Referenced by name_TTSubdetPMiphi().

495  {
496  return constants::TPSUBDETPM_NAME[tid.ietaAbs() < 29 ? (tid.ieta() < 0 ? 0 : 1) : (tid.ieta() < 0 ? 2 : 3)];
497  }
std::string const TPSUBDETPM_NAME[2 *TPSUBDET_NUM]
Definition: Constants.h:166
std::string hcaldqm::hashfunctions::name_TTSubdetPMiphi ( HcalTrigTowerDetId const &  tid)

Definition at line 512 of file HashFunctions.cc.

References HcalTrigTowerDetId::iphi(), dataset::name, name_TTSubdetPM(), and AlCaHLTBitMon_QueryRunRegistry::string.

512  {
513  char name[10];
514  sprintf(name, "%siphi%d", name_TTSubdetPM(tid).c_str(), tid.iphi());
515  return std::string(name);
516  }
std::string name_TTSubdetPM(HcalTrigTowerDetId const &)

Variable Documentation

hash_function_did const hcaldqm::hashfunctions::hash_did[nHashType_did]
Initial value:
uint32_t hash_Subdet(std::string const &)
uint32_t hash_depth(std::string const &)
uint32_t hash_Subdetiphi(std::string const &)
uint32_t hash_HFPMiphi(std::string const &)
uint32_t hash_DChannel(std::string const &)
uint32_t hash_Subdetieta(std::string const &)
uint32_t hash_Subdetdepth(std::string const &)
uint32_t hash_HBHEPartition(std::string const &)
uint32_t hash_ieta(std::string const &)
uint32_t hash_iphi(std::string const &)
uint32_t hash_SubdetPMiphi(std::string const &)
uint32_t hash_SubdetPM(std::string const &)

Definition at line 163 of file HashFunctions.h.

Referenced by RecHitTask::bookHistograms(), DigiTask::bookHistograms(), and hcaldqm::mapper::HashMapper::getHash().

hash_function_eid const hcaldqm::hashfunctions::hash_eid[nHashType_eid-nHashType_did-1]
Initial value:
uint32_t hash_FEDSpigot(std::string const &)
uint32_t hash_Electronics(std::string const &)
uint32_t hash_CrateSlot(std::string const &)
uint32_t hash_CrateSpigot(std::string const &)
uint32_t hash_Crate(std::string const &)
uint32_t hash_EChannel(std::string const &)
uint32_t hash_FiberFiberCh(std::string const &)
uint32_t hash_Fiber(std::string const &)
uint32_t hash_FED(std::string const &)
uint32_t hash_FEDSlot(std::string const &)
uint32_t hash_FiberCh(std::string const &)

Definition at line 175 of file HashFunctions.h.

Referenced by hcaldqm::mapper::HashMapper::getHash().

std::string const hcaldqm::hashfunctions::hash_names[nhashes]
Initial value:
= {
"Subdet", "Subdetiphi", "Subdetieta", "Subdetdepth", "SubdetPM", "SubdetPMiphi",
"iphi", "ieta", "depth", "HFPMiphi", "HBHEPartition", "DChannel",
"FED", "FEDSpigot", "FEDSlot", "Crate", "CrateSpigot", "CrateSlot",
"Fiber", "FiberFiberCh", "FiberCh", "Electronics", "EChannel",
"TTSubdet", "TTSubdetPM", "TTSubdetPMiphi", "TTSubdetieta", "TTdepth", "TChannel"}

Definition at line 214 of file HashFunctions.h.

Referenced by hcaldqm::mapper::HashMapper::getHashTypeName().

hash_function_tid const hcaldqm::hashfunctions::hash_tid[nHashType_tid-nHashType_eid-1]
Initial value:
= {
uint32_t hash_TTdepth(std::string const &)
uint32_t hash_TTSubdetPM(std::string const &)
uint32_t hash_TTSubdetieta(std::string const &)
uint32_t hash_TTSubdet(std::string const &)
uint32_t hash_TTSubdetPMiphi(std::string const &)
uint32_t hash_TChannel(std::string const &)

Definition at line 186 of file HashFunctions.h.

Referenced by hcaldqm::mapper::HashMapper::getHash().

name_function_did const hcaldqm::hashfunctions::name_did[nHashType_did]
Initial value:
std::string name_Subdetieta(HcalDetId const &)
std::string name_Subdetiphi(HcalDetId const &)
std::string name_SubdetPM(HcalDetId const &)
std::string name_DChannel(HcalDetId const &)
std::string name_HFPMiphi(HcalDetId const &)
std::string name_SubdetPMiphi(HcalDetId const &)
std::string name_ieta(HcalDetId const &)
std::string name_HBHEPartition(HcalDetId const &)
std::string name_depth(HcalDetId const &)
std::string name_iphi(HcalDetId const &)
std::string name_Subdet(HcalDetId const &)
std::string name_Subdetdepth(HcalDetId const &)

Definition at line 188 of file HashFunctions.h.

Referenced by hcaldqm::mapper::HashMapper::getName().

name_function_eid const hcaldqm::hashfunctions::name_eid[nHashType_eid-nHashType_did-1]
Initial value:
std::string name_CrateSpigot(HcalElectronicsId const &)
std::string name_Electronics(HcalElectronicsId const &)
std::string name_CrateSlot(HcalElectronicsId const &)
std::string name_Crate(HcalElectronicsId const &)
std::string name_FiberFiberCh(HcalElectronicsId const &)
std::string name_FiberCh(HcalElectronicsId const &)
std::string name_EChannel(HcalElectronicsId const &)
std::string name_FEDSpigot(HcalElectronicsId const &)
std::string name_FED(HcalElectronicsId const &)
std::string name_Fiber(HcalElectronicsId const &)
std::string name_FEDSlot(HcalElectronicsId const &)

Definition at line 200 of file HashFunctions.h.

Referenced by hcaldqm::mapper::HashMapper::getName().

name_function_tid const hcaldqm::hashfunctions::name_tid[nHashType_tid-nHashType_eid-1]
Initial value:
= {
std::string name_TTdepth(HcalTrigTowerDetId const &)
std::string name_TChannel(HcalTrigTowerDetId const &)
std::string name_TTSubdet(HcalTrigTowerDetId const &)
std::string name_TTSubdetieta(HcalTrigTowerDetId const &)
std::string name_TTSubdetPMiphi(HcalTrigTowerDetId const &)
std::string name_TTSubdetPM(HcalTrigTowerDetId const &)

Definition at line 211 of file HashFunctions.h.

Referenced by hcaldqm::mapper::HashMapper::getName().

int const hcaldqm::hashfunctions::nhashes = nHashType_did + (nHashType_eid - nHashType_did - 1) + (nHashType_tid - nHashType_eid - 1)

Definition at line 213 of file HashFunctions.h.