#include <HGCalTriggerTowerGeometryHelper.h>
Public Member Functions | |
const std::vector< l1t::HGCalTowerCoord > & | getTowerCoordinates () const |
std::unordered_map< unsigned short, float > | getTriggerTower (const l1t::HGCalTriggerCell &) const |
std::unordered_map< unsigned short, float > | getTriggerTower (const l1t::HGCalTriggerSums &) const |
unsigned short | getTriggerTowerFromEtaPhi (const float &eta, const float &phi) const |
HGCalTriggerTowerGeometryHelper (const edm::ParameterSet &conf) | |
const bool | isNose () |
int | moveToCorrectSector (int towerPhi_raw, int sector) const |
unsigned | packLayerSubdetWaferId (int subdet, int layer, int moduleU, int moduleV) const |
unsigned | packTowerIDandShare (int towerEta, int towerPhi, int towerShare) const |
void | reverseXaxis (int &towerPhi) const |
void | setGeometry (const HGCalTriggerGeometryBase *const geom) |
void | unpackTowerIDandShare (unsigned towerIDandShare, int &towerEta_raw, int &towerPhi_raw, int &towerShare) const |
~HGCalTriggerTowerGeometryHelper () | |
Private Attributes | |
std::vector< double > | binsEta_ |
std::vector< double > | binsPhi_ |
std::unordered_map< unsigned, short > | cells_to_trigger_towers_ |
bool | doNose_ |
double | maxEta_ |
double | maxPhi_ |
double | minEta_ |
double | minPhi_ |
std::unordered_map< unsigned, std::vector< unsigned > > | modules_to_trigger_towers_ |
unsigned int | nBinsEta_ |
unsigned int | nBinsPhi_ |
int | reverseX_ |
int | rotate120Deg_ |
int | rotate180Deg_ |
int | splitDivisorScint_ |
int | splitDivisorSilic_ |
bool | splitModuleSum_ |
std::vector< l1t::HGCalTowerCoord > | tower_coords_ |
HGCalTriggerTools | triggerTools_ |
Static Private Attributes | |
static const int | sign1Shift = 21 |
static const int | sign2Shift = 22 |
static const int | signMask = 0x1 |
static const int | towerShareMask = 0x7F |
static const int | towerShareShift = 14 |
Handles the mapping between TCs and TTs. The mapping can be provided externally (via a mapping file) or can be derived on the fly based on the TC eta-phi coordinates. The bin boundaries need anyhow to be provided to establish the eta-phi coordinates of the towers (assumed as the Tower Center for the moment)
Definition at line 28 of file HGCalTriggerTowerGeometryHelper.h.
HGCalTriggerTowerGeometryHelper::HGCalTriggerTowerGeometryHelper | ( | const edm::ParameterSet & | conf | ) |
Definition at line 13 of file HGCalTriggerTowerGeometryHelper.cc.
References binsEta_, binsPhi_, cells_to_trigger_towers_, edm::errors::Configuration, doNose_, Exception, edm::FileInPath::fullPath(), edm::ParameterSet::getParameter(), mps_fire::i, l1tPhase2CaloJetEmulator_cfi::iEta, createfilelist::int, nano_mu_digi_cff::layer, mps_splice::line, maxEta_, maxPhi_, minEta_, minPhi_, modules_to_trigger_towers_, nBinsEta_, nBinsPhi_, packLayerSubdetWaferId(), packTowerIDandShare(), reverseX_, rotate120Deg_, rotate180Deg_, splitDivisorScint_, splitDivisorSilic_, splitModuleSum_, contentValuesCheck::ss, AlCaHLTBitMon_QueryRunRegistry::string, tower_coords_, ecaldqm::towerId(), HLT_2024v12_cff::towers, triggerTools_, HGCalTriggerTools::zside(), and ecaldqm::zside().
|
inline |
Definition at line 32 of file HGCalTriggerTowerGeometryHelper.h.
const std::vector< l1t::HGCalTowerCoord > & HGCalTriggerTowerGeometryHelper::getTowerCoordinates | ( | ) | const |
Definition at line 208 of file HGCalTriggerTowerGeometryHelper.cc.
References tower_coords_.
Referenced by HGCalTowerMap2DImpl::newTowerMaps().
std::unordered_map< unsigned short, float > HGCalTriggerTowerGeometryHelper::getTriggerTower | ( | const l1t::HGCalTriggerCell & | thecell | ) | const |
Definition at line 247 of file HGCalTriggerTowerGeometryHelper.cc.
References cells_to_trigger_towers_, l1t::HGCalTriggerCell::detId(), PV3DBase< T, PVType, FrameType >::eta(), getTriggerTowerFromEtaPhi(), PV3DBase< T, PVType, FrameType >::phi(), and l1t::HGCalTriggerCell::position().
Referenced by HGCalTowerMap2DImpl::buildTowerMap2D().
std::unordered_map< unsigned short, float > HGCalTriggerTowerGeometryHelper::getTriggerTower | ( | const l1t::HGCalTriggerSums & | thesum | ) | const |
Definition at line 263 of file HGCalTriggerTowerGeometryHelper.cc.
References l1t::HGCalTriggerSums::detId(), doNose_, PV3DBase< T, PVType, FrameType >::eta(), getTriggerTowerFromEtaPhi(), l1tPhase2CaloJetEmulator_cfi::iEta, nano_mu_digi_cff::layer, modules_to_trigger_towers_, HGCalTriggerModuleDetId::moduleU(), moveToCorrectSector(), packLayerSubdetWaferId(), PV3DBase< T, PVType, FrameType >::phi(), l1t::HGCalTriggerSums::position(), l1t::HGCalTowerID::rawId(), reverseXaxis(), nano_mu_digi_cff::sector, splitDivisorScint_, splitDivisorSilic_, splitModuleSum_, unpackTowerIDandShare(), and ecaldqm::zside().
unsigned short HGCalTriggerTowerGeometryHelper::getTriggerTowerFromEtaPhi | ( | const float & | eta, |
const float & | phi | ||
) | const |
Definition at line 212 of file HGCalTriggerTowerGeometryHelper.cc.
References binsEta_, binsPhi_, doNose_, PVValHelper::eta, pfDeepBoostedJetPreprocessParams_cfi::lower_bound, maxEta_, maxPhi_, minEta_, minPhi_, nBinsEta_, nBinsPhi_, phi, l1t::HGCalTowerID::rawId(), and ecaldqm::zside().
Referenced by getTriggerTower().
|
inline |
Definition at line 48 of file HGCalTriggerTowerGeometryHelper.h.
References doNose_.
Referenced by HGCalTowerMap2DImpl::newTowerMaps().
int HGCalTriggerTowerGeometryHelper::moveToCorrectSector | ( | int | towerPhi_raw, |
int | sector | ||
) | const |
Definition at line 198 of file HGCalTriggerTowerGeometryHelper.cc.
References nBinsPhi_, rotate120Deg_, rotate180Deg_, and nano_mu_digi_cff::sector.
Referenced by getTriggerTower().
unsigned HGCalTriggerTowerGeometryHelper::packLayerSubdetWaferId | ( | int | subdet, |
int | layer, | ||
int | moduleU, | ||
int | moduleV | ||
) | const |
Definition at line 156 of file HGCalTriggerTowerGeometryHelper.cc.
References HGCalTriggerModuleDetId::kHGCalLayerMask, HGCalTriggerModuleDetId::kHGCalLayerOffset, HGCalTriggerModuleDetId::kHGCalModuleUMask, HGCalTriggerModuleDetId::kHGCalModuleUOffset, HGCalTriggerModuleDetId::kHGCalModuleVMask, HGCalTriggerModuleDetId::kHGCalModuleVOffset, HGCalTriggerModuleDetId::kHGCalTriggerSubdetMask, HGCalTriggerModuleDetId::kHGCalTriggerSubdetOffset, and nano_mu_digi_cff::layer.
Referenced by getTriggerTower(), and HGCalTriggerTowerGeometryHelper().
unsigned HGCalTriggerTowerGeometryHelper::packTowerIDandShare | ( | int | towerEta, |
int | towerPhi, | ||
int | towerShare | ||
) | const |
Definition at line 168 of file HGCalTriggerTowerGeometryHelper.cc.
References funct::abs(), l1t::HGCalTowerID::coord1Shift, l1t::HGCalTowerID::coord2Shift, l1t::HGCalTowerID::coordMask, sign1Shift, sign2Shift, signMask, towerShareMask, and towerShareShift.
Referenced by HGCalTriggerTowerGeometryHelper().
void HGCalTriggerTowerGeometryHelper::reverseXaxis | ( | int & | towerPhi | ) | const |
Definition at line 203 of file HGCalTriggerTowerGeometryHelper.cc.
References createfilelist::int, nBinsPhi_, and reverseX_.
Referenced by getTriggerTower().
|
inline |
Definition at line 34 of file HGCalTriggerTowerGeometryHelper.h.
References relativeConstraints::geom, HGCalTriggerTools::setGeometry(), and triggerTools_.
Referenced by HGCalTowerMap2DImpl::setGeometry().
void HGCalTriggerTowerGeometryHelper::unpackTowerIDandShare | ( | unsigned | towerIDandShare, |
int & | towerEta_raw, | ||
int & | towerPhi_raw, | ||
int & | towerShare | ||
) | const |
Definition at line 182 of file HGCalTriggerTowerGeometryHelper.cc.
References l1t::HGCalTowerID::coord1Shift, l1t::HGCalTowerID::coord2Shift, l1t::HGCalTowerID::coordMask, sign1Shift, sign2Shift, signMask, towerShareMask, and towerShareShift.
Referenced by getTriggerTower().
|
private |
Definition at line 68 of file HGCalTriggerTowerGeometryHelper.h.
Referenced by getTriggerTowerFromEtaPhi(), and HGCalTriggerTowerGeometryHelper().
|
private |
Definition at line 69 of file HGCalTriggerTowerGeometryHelper.h.
Referenced by getTriggerTowerFromEtaPhi(), and HGCalTriggerTowerGeometryHelper().
|
private |
Definition at line 57 of file HGCalTriggerTowerGeometryHelper.h.
Referenced by getTriggerTower(), and HGCalTriggerTowerGeometryHelper().
|
private |
Definition at line 60 of file HGCalTriggerTowerGeometryHelper.h.
Referenced by getTriggerTower(), getTriggerTowerFromEtaPhi(), HGCalTriggerTowerGeometryHelper(), and isNose().
|
private |
Definition at line 62 of file HGCalTriggerTowerGeometryHelper.h.
Referenced by getTriggerTowerFromEtaPhi(), and HGCalTriggerTowerGeometryHelper().
|
private |
Definition at line 64 of file HGCalTriggerTowerGeometryHelper.h.
Referenced by getTriggerTowerFromEtaPhi(), and HGCalTriggerTowerGeometryHelper().
|
private |
Definition at line 61 of file HGCalTriggerTowerGeometryHelper.h.
Referenced by getTriggerTowerFromEtaPhi(), and HGCalTriggerTowerGeometryHelper().
|
private |
Definition at line 63 of file HGCalTriggerTowerGeometryHelper.h.
Referenced by getTriggerTowerFromEtaPhi(), and HGCalTriggerTowerGeometryHelper().
|
private |
Definition at line 58 of file HGCalTriggerTowerGeometryHelper.h.
Referenced by getTriggerTower(), and HGCalTriggerTowerGeometryHelper().
|
private |
Definition at line 65 of file HGCalTriggerTowerGeometryHelper.h.
Referenced by getTriggerTowerFromEtaPhi(), and HGCalTriggerTowerGeometryHelper().
|
private |
Definition at line 66 of file HGCalTriggerTowerGeometryHelper.h.
Referenced by getTriggerTowerFromEtaPhi(), HGCalTriggerTowerGeometryHelper(), moveToCorrectSector(), and reverseXaxis().
|
private |
Definition at line 76 of file HGCalTriggerTowerGeometryHelper.h.
Referenced by HGCalTriggerTowerGeometryHelper(), and reverseXaxis().
|
private |
Definition at line 75 of file HGCalTriggerTowerGeometryHelper.h.
Referenced by HGCalTriggerTowerGeometryHelper(), and moveToCorrectSector().
|
private |
Definition at line 74 of file HGCalTriggerTowerGeometryHelper.h.
Referenced by HGCalTriggerTowerGeometryHelper(), and moveToCorrectSector().
|
staticprivate |
Definition at line 54 of file HGCalTriggerTowerGeometryHelper.h.
Referenced by packTowerIDandShare(), and unpackTowerIDandShare().
|
staticprivate |
Definition at line 55 of file HGCalTriggerTowerGeometryHelper.h.
Referenced by packTowerIDandShare(), and unpackTowerIDandShare().
|
staticprivate |
Definition at line 53 of file HGCalTriggerTowerGeometryHelper.h.
Referenced by packTowerIDandShare(), and unpackTowerIDandShare().
|
private |
Definition at line 73 of file HGCalTriggerTowerGeometryHelper.h.
Referenced by getTriggerTower(), and HGCalTriggerTowerGeometryHelper().
|
private |
Definition at line 72 of file HGCalTriggerTowerGeometryHelper.h.
Referenced by getTriggerTower(), and HGCalTriggerTowerGeometryHelper().
|
private |
Definition at line 71 of file HGCalTriggerTowerGeometryHelper.h.
Referenced by getTriggerTower(), and HGCalTriggerTowerGeometryHelper().
|
private |
Definition at line 56 of file HGCalTriggerTowerGeometryHelper.h.
Referenced by getTowerCoordinates(), and HGCalTriggerTowerGeometryHelper().
|
staticprivate |
Definition at line 51 of file HGCalTriggerTowerGeometryHelper.h.
Referenced by packTowerIDandShare(), and unpackTowerIDandShare().
|
staticprivate |
Definition at line 52 of file HGCalTriggerTowerGeometryHelper.h.
Referenced by packTowerIDandShare(), and unpackTowerIDandShare().
|
private |
Definition at line 78 of file HGCalTriggerTowerGeometryHelper.h.
Referenced by HGCalTriggerTowerGeometryHelper(), and setGeometry().