#include <HGCalTriggerTools.h>
Public Types | |
enum | SubDetectorType { hgcal_silicon_CEE, hgcal_silicon_CEH, hgcal_scintillator } |
Public Member Functions | |
template<typename T > | |
std::vector< T > | bxVectorToVector (const BXVector< T > &inputBXVector) |
void | eventSetup (const edm::EventSetup &) |
float | getEta (const GlobalPoint &position, const float &vertex_z=0.) const |
float | getLayerZ (const int &subdet, const unsigned &layer) const |
float | getLayerZ (const unsigned &layerWithOffset) const |
float | getPhi (const GlobalPoint &position) const |
float | getPt (const GlobalPoint &position, const float &hitEnergy, const float &vertex_z=0.) const |
SubDetectorType | getSubDetectorType (const DetId &id) const |
float | getTCEta (const DetId &id, const float &vertex_z=0.) const |
float | getTCPhi (const DetId &id) const |
GlobalPoint | getTCPosition (const DetId &id) const |
float | getTCPt (const DetId &id, const float &hitEnergy, const float &vertex_z=0.) const |
const HGCalTriggerGeometryBase * | getTriggerGeometry () const |
HGCalTriggerTools () | |
bool | isEm (const DetId &) const |
bool | isHad (const DetId &id) const |
bool | isNose (const DetId &) const |
bool | isScintillator (const DetId &id) const |
bool | isSilicon (const DetId &) const |
unsigned | lastLayerBH () const |
unsigned | lastLayerEE () const |
unsigned | lastLayerFH () const |
unsigned | lastLayerNose () const |
unsigned | layer (const DetId &) const |
unsigned | layers (DetId::Detector type) const |
unsigned | layers (ForwardSubdetector type) const |
unsigned | layerWithOffset (const DetId &) const |
DetId | simToReco (const DetId &, const HcalTopology &) const |
DetId | simToReco (const DetId &, const HGCalTopology &) const |
int | thicknessIndex (const DetId &, bool tc=false) const |
unsigned | triggerLayer (const unsigned id) const |
int | zside (const DetId &) const |
~HGCalTriggerTools () | |
Static Public Attributes | |
static constexpr unsigned | kScintillatorPseudoThicknessIndex_ = 3 |
Private Member Functions | |
int | sensorCellThicknessV8 (const DetId &id) const |
Private Attributes | |
unsigned | bhLayers_ |
unsigned | eeLayers_ |
unsigned | fhLayers_ |
const HGCalTriggerGeometryBase * | geom_ |
unsigned | noseLayers_ |
unsigned | totalLayers_ |
Tools for handling HGCal trigger det-ID: in the current version of trhe HGCAL simulation only HGCalDetId for the TriggerCells (TC) are used and not HcalDetId as in the offline! As a consequence the class assumes that only DetIds of the first kind are used in the getTC* methods NOTE: this uses the trigger geometry hence would give wrong results when used for offline reco!!!!
Definition at line 32 of file HGCalTriggerTools.h.
Enumerator | |
---|---|
hgcal_silicon_CEE | |
hgcal_silicon_CEH | |
hgcal_scintillator |
Definition at line 88 of file HGCalTriggerTools.h.
|
inline |
Definition at line 34 of file HGCalTriggerTools.h.
|
inline |
Definition at line 35 of file HGCalTriggerTools.h.
|
inline |
Definition at line 75 of file HGCalTriggerTools.h.
References BXVector< T >::begin(), and BXVector< T >::end().
void HGCalTriggerTools::eventSetup | ( | const edm::EventSetup & | es | ) |
Definition at line 35 of file HGCalTriggerTools.cc.
References bhLayers_, HGCalTriggerGeometryBase::bhTopology(), HGCalTopology::dddConstants(), HcalTopology::dddConstants(), eeLayers_, HGCalTriggerGeometryBase::eeTopology(), fhLayers_, HGCalTriggerGeometryBase::fhTopology(), geom_, edm::EventSetup::get(), get, HcalDDDRecConstants::getMaxDepth(), HGCalTriggerGeometryBase::hscTopology(), HGCalTriggerGeometryBase::isV9Geometry(), HGCalTriggerGeometryBase::isWithNoseGeometry(), HGCalDDDConstants::layers(), noseLayers_, HGCalTriggerGeometryBase::noseTopology(), edm::ESHandle< T >::product(), and totalLayers_.
Referenced by HGCalTriggerValidator::analyze(), HGCalTriggerClusterInterpretationEM::eventSetup(), HGCalTriggerCellCalibration::eventSetup(), HGCalVFESummationImpl::eventSetup(), HGCalConcentratorCoarsenerImpl::eventSetup(), HGCalClusteringDummyImpl::eventSetup(), HGCalConcentratorThresholdImpl::eventSetup(), HGCalCoarseTriggerCellMapping::eventSetup(), HGCalConcentratorTrigSumImpl::eventSetup(), HGCalMulticlusteringImpl::eventSetup(), HGCalHistoClusteringImpl::eventSetup(), HGCalConcentratorBestChoiceImpl::eventSetup(), HGCalConcentratorSuperTriggerCellImpl::eventSetup(), HGCalShowerShape::eventSetup(), HGCalClusteringImpl::eventSetup(), HGCalTriggerTowerGeometryHelper::eventSetup(), HGCalTowerMap2DImpl::eventSetup(), HGCalHistoSeedingImpl::eventSetup(), HGCalTriggerNtupleHGCClusters::fill(), HGCalTriggerNtupleHGCTriggerSums::fill(), HGCalTriggerNtupleHGCDigis::fill(), HGCalTriggerNtupleHGCTriggerCells::fill(), HGCalTriggerNtupleGen::fill(), CaloTruthCellsProducer::produce(), HGCalVFEProcessorSums::run(), and HGCalConcentratorProcessorSelection::run().
float HGCalTriggerTools::getEta | ( | const GlobalPoint & | position, |
const float & | vertex_z = 0. |
||
) | const |
Definition at line 281 of file HGCalTriggerTools.cc.
References PV3DBase< T, PVType, FrameType >::eta(), and position.
Referenced by getPt(), and getTCEta().
float HGCalTriggerTools::getLayerZ | ( | const int & | subdet, |
const unsigned & | layer | ||
) | const |
Definition at line 326 of file HGCalTriggerTools.cc.
References HGCalTriggerGeometryBase::bhTopology(), HGCalTopology::dddConstants(), HcalTopology::dddConstants(), HGCalTriggerGeometryBase::eeTopology(), HGCalTriggerGeometryBase::fhTopology(), geom_, HcalDDDRecConstants::getEtaRange(), HcalDDDRecConstants::getRZ(), HcalEndcap, HFNose, DetId::HGCalEE, DetId::HGCalHSc, DetId::HGCalHSi, HGCEE, HGCHEB, HGCHEF, HGCalTriggerGeometryBase::hscTopology(), HGCalTriggerGeometryBase::isV9Geometry(), layer(), HGCalTriggerGeometryBase::noseTopology(), and HGCalDDDConstants::waferZ().
float HGCalTriggerTools::getLayerZ | ( | const unsigned & | layerWithOffset | ) | const |
Definition at line 312 of file HGCalTriggerTools.cc.
References HcalEndcap, HGCEE, HGCHEF, lastLayerEE(), lastLayerFH(), layerWithOffset(), and hltrates_dqm_sourceclient-live_cfg::offset.
Referenced by HGCalTriggerNtupleGen::fill().
float HGCalTriggerTools::getPhi | ( | const GlobalPoint & | position | ) | const |
Definition at line 291 of file HGCalTriggerTools.cc.
Referenced by getTCPhi().
float HGCalTriggerTools::getPt | ( | const GlobalPoint & | position, |
const float & | hitEnergy, | ||
const float & | vertex_z = 0. |
||
) | const |
Definition at line 301 of file HGCalTriggerTools.cc.
References PVValHelper::eta, getEta(), position, and DiDispStaMuonMonitor_cfi::pt.
Referenced by getTCPt().
HGCalTriggerTools::SubDetectorType HGCalTriggerTools::getSubDetectorType | ( | const DetId & | id | ) | const |
Definition at line 198 of file HGCalTriggerTools.cc.
References hgcal_scintillator, hgcal_silicon_CEE, hgcal_silicon_CEH, isEm(), and isScintillator().
Referenced by HGCalConcentratorSuperTriggerCellImpl::assignSuperTriggerCellEnergyAndPosition(), HGCalConcentratorSuperTriggerCellImpl::createAllTriggerCells(), and HGCalConcentratorProcessorSelection::run().
float HGCalTriggerTools::getTCEta | ( | const DetId & | id, |
const float & | vertex_z = 0. |
||
) | const |
Definition at line 286 of file HGCalTriggerTools.cc.
References getEta(), getTCPosition(), and position.
float HGCalTriggerTools::getTCPhi | ( | const DetId & | id | ) | const |
Definition at line 296 of file HGCalTriggerTools.cc.
References getPhi(), getTCPosition(), and position.
GlobalPoint HGCalTriggerTools::getTCPosition | ( | const DetId & | id | ) | const |
Definition at line 54 of file HGCalTriggerTools.cc.
References Exception, geom_, HGCalTriggerGeometryBase::getTriggerCellPosition(), DetId::Hcal, DetId::HGCalEE, and position.
Referenced by HGCalConcentratorSuperTriggerCellImpl::assignSuperTriggerCellEnergyAndPosition(), HGCalCoarseTriggerCellMapping::getCoarseTriggerCellPosition(), getTCEta(), getTCPhi(), and getTCPt().
float HGCalTriggerTools::getTCPt | ( | const DetId & | id, |
const float & | hitEnergy, | ||
const float & | vertex_z = 0. |
||
) | const |
Definition at line 307 of file HGCalTriggerTools.cc.
References getPt(), getTCPosition(), and position.
|
inline |
Definition at line 69 of file HGCalTriggerTools.h.
References geom_.
Referenced by HGCalConcentratorSuperTriggerCellImpl::createAllTriggerCells(), HGCalConcentratorTrigSumImpl::doSum(), HGCalCoarseTriggerCellMapping::getConstituentTriggerCells(), HGCalCoarseTriggerCellMapping::getRepresentativeDetId(), and HGCalVFESummationImpl::triggerCellSums().
bool HGCalTriggerTools::isEm | ( | const DetId & | id | ) | const |
Definition at line 151 of file HGCalTriggerTools.cc.
References DetId::Forward, HFNose, HFNoseTrigger, DetId::HGCalEE, HGCalEETrigger, DetId::HGCalTrigger, HGCEE, HFNoseTriggerDetId::isEE(), and HFNoseDetId::isEE().
Referenced by HGCalConcentratorSuperTriggerCellImpl::assignSuperTriggerCellEnergyAndPosition(), HGCalTriggerNtupleHGCTriggerCells::fill(), HGCalHistoSeedingImpl::fillHistoClusters(), getSubDetectorType(), isHad(), HGCalVFEProcessorSums::run(), and HGCalConcentratorProcessorSelection::run().
|
inline |
Definition at line 44 of file HGCalTriggerTools.h.
References isEm().
Referenced by layerWithOffset().
bool HGCalTriggerTools::isNose | ( | const DetId & | id | ) | const |
Definition at line 170 of file HGCalTriggerTools.cc.
References DetId::Forward, HFNose, HFNoseTrigger, and DetId::HGCalTrigger.
Referenced by HGCalConcentratorSuperTriggerCellImpl::assignSuperTriggerCellEnergyAndPosition(), HGCalTowerMap2DImpl::buildTowerMap2D(), HGCalClusteringDummyImpl::calibratePt(), HGCalShowerShape::coreShowerLength(), layerWithOffset(), HGCalShowerShape::percentileLayer(), and HGCalVFEProcessorSums::run().
|
inline |
Definition at line 46 of file HGCalTriggerTools.h.
References isSilicon().
Referenced by HGCalCoarseTriggerCellMapping::getCoarseTriggerCellId(), HGCalCoarseTriggerCellMapping::getConstituentTriggerCells(), getSubDetectorType(), layerWithOffset(), HGCalConcentratorThresholdImpl::select(), thicknessIndex(), and HGCalVFESummationImpl::triggerCellSums().
bool HGCalTriggerTools::isSilicon | ( | const DetId & | id | ) | const |
Definition at line 181 of file HGCalTriggerTools.cc.
References DetId::Forward, HFNoseTrigger, DetId::HGCalEE, HGCalEETrigger, DetId::HGCalHSi, HGCalHSiTrigger, DetId::HGCalTrigger, HGCHEB, and HGCalTriggerDetId::subdet().
Referenced by HGCalConcentratorSuperTriggerCellImpl::assignSuperTriggerCellEnergyAndPosition(), HGCalTriggerCellCalibration::calibrateInMipT(), HGCalTriggerCellCalibration::calibrateMipTinGeV(), HGCalTriggerNtupleHGCTriggerCells::fill(), isScintillator(), layerWithOffset(), HGCalVFEProcessorSums::run(), and HGCalVFESummationImpl::triggerCellSums().
|
inline |
Definition at line 56 of file HGCalTriggerTools.h.
References totalLayers_.
Referenced by HGCalHistoClusteringImpl::eventSetup(), HGCalTriggerNtupleGen::fill(), and HGCalTowerMap2DImpl::newTowerMaps().
|
inline |
Definition at line 54 of file HGCalTriggerTools.h.
References eeLayers_.
Referenced by HGCalTowerMap2DImpl::buildTowerMap2D(), getLayerZ(), and HGCalTowerMap2DImpl::newTowerMaps().
|
inline |
Definition at line 55 of file HGCalTriggerTools.h.
References eeLayers_, and fhLayers_.
Referenced by getLayerZ().
|
inline |
unsigned HGCalTriggerTools::layer | ( | const DetId & | id | ) | const |
Definition at line 111 of file HGCalTriggerTools.cc.
References HcalDetId::depth(), DetId::Forward, DetId::Hcal, HcalEndcap, HFNose, HFNoseTrigger, DetId::HGCalEE, HGCalEETrigger, DetId::HGCalHSc, DetId::HGCalHSi, HGCalHSiTrigger, DetId::HGCalTrigger, HGCalDetId::layer(), HGCScintillatorDetId::layer(), HFNoseTriggerDetId::layer(), HGCalTriggerDetId::layer(), HFNoseDetId::layer(), HGCSiliconDetId::layer(), and SiStripPI::max.
Referenced by getLayerZ(), geometryXMLparser.DTAlignable::index(), geometryXMLparser.CSCAlignable::index(), HGCalClusteringImpl::isPertinent(), layerWithOffset(), and simToReco().
unsigned HGCalTriggerTools::layers | ( | DetId::Detector | type | ) | const |
Definition at line 89 of file HGCalTriggerTools.cc.
References bhLayers_, eeLayers_, fhLayers_, DetId::Forward, DetId::HGCalEE, DetId::HGCalHSc, DetId::HGCalHSi, layers(), and totalLayers_.
unsigned HGCalTriggerTools::layers | ( | ForwardSubdetector | type | ) | const |
Definition at line 65 of file HGCalTriggerTools.cc.
References bhLayers_, eeLayers_, fhLayers_, ForwardEmpty, HFNose, HGCEE, HGCHEB, HGCHEF, noseLayers_, and totalLayers_.
Referenced by HGCalClusteringImpl::clusterizeNN(), HGCalShowerShape::coreShowerLength(), layers(), and HGCalShowerShape::percentileLayer().
unsigned HGCalTriggerTools::layerWithOffset | ( | const DetId & | id | ) | const |
Definition at line 134 of file HGCalTriggerTools.cc.
References eeLayers_, fhLayers_, geom_, isHad(), isNose(), isScintillator(), isSilicon(), HGCalTriggerGeometryBase::isV9Geometry(), cmsLHEtoEOSManager::l, and layer().
Referenced by HGCalTriggerValidator::analyze(), HGCalTowerMap2DImpl::buildTowerMap2D(), HGCalTriggerCellCalibration::calibrateMipTinGeV(), HGCalClusteringDummyImpl::calibratePt(), HGCalClusteringImpl::calibratePt(), HGCalHistoClusteringImpl::clusterSeedMulticluster(), HGCalShowerShape::eMax(), HGCalTriggerNtupleHGCClusters::fill(), HGCalTriggerNtupleHGCTriggerSums::fill(), HGCalTriggerNtupleHGCDigis::fill(), HGCalTriggerNtupleHGCTriggerCells::fill(), HGCalShowerShape::firstLayer(), HGCalCoarseTriggerCellMapping::getCoarseTriggerCellId(), HGCalCoarseTriggerCellMapping::getConstituentTriggerCells(), getLayerZ(), HGCalShowerShape::lastLayer(), HGCalShowerShape::maxLayer(), HGCalShowerShape::sigmaEtaEtaMax(), HGCalShowerShape::sigmaPhiPhiMax(), HGCalShowerShape::sigmaRRMax(), HGCalShowerShape::sigmaRRMean(), and HGCalClusteringImpl::triggerCellReshuffling().
|
private |
Definition at line 379 of file HGCalTriggerTools.cc.
References HGCalTopology::dddConstants(), HGCalTriggerGeometryBase::eeTopology(), HGCalTriggerGeometryBase::fhTopology(), geom_, HGCEE, HGCHEF, Calorimetry_cff::thickness, and HGCalDDDConstants::waferTypeL().
Referenced by thicknessIndex().
DetId HGCalTriggerTools::simToReco | ( | const DetId & | simid, |
const HcalTopology & | topo | ||
) | const |
Definition at line 370 of file HGCalTriggerTools.cc.
References HcalTopology::dddConstants(), HcalEndcap, triggerObjects_cff::id, and HcalHitRelabeller::relabel().
DetId HGCalTriggerTools::simToReco | ( | const DetId & | simid, |
const HGCalTopology & | topo | ||
) | const |
Definition at line 346 of file HGCalTriggerTools.cc.
References HGCalTopology::dddConstants(), HGCalTopology::detectorType(), layer(), fileinputsource_cfi::sec, DetId::subdetId(), and HGCalTestNumbering::unpackHexagonIndex().
Referenced by CaloTruthCellsProducer::makeHitMap(), HGCalTriggerNtupleHGCDigis::simhits(), and HGCalTriggerNtupleHGCTriggerCells::simhits().
int HGCalTriggerTools::thicknessIndex | ( | const DetId & | id, |
bool | tc = false |
||
) | const |
Definition at line 233 of file HGCalTriggerTools.cc.
References DetId::det(), Exception, DetId::Forward, geom_, HGCalTriggerGeometryBase::getCellsFromTriggerCell(), HFNose, HFNoseTrigger, DetId::HGCalEE, HGCalEETrigger, DetId::HGCalHSi, HGCalHSiTrigger, DetId::HGCalTrigger, isScintillator(), kScintillatorPseudoThicknessIndex_, mps_monitormerge::occurences, sensorCellThicknessV8(), Calorimetry_cff::thickness, HGCalTriggerDetId::type(), HFNoseTriggerDetId::type(), HFNoseDetId::type(), and HGCSiliconDetId::type().
Referenced by HGCalConcentratorSuperTriggerCellImpl::assignSuperTriggerCellEnergyAndPosition(), HGCalTriggerCellCalibration::calibrateInMipT(), HGCalTriggerCellCalibration::calibrateMipTinGeV(), HGCalConcentratorCoarsenerImpl::coarsen(), HGCalConcentratorSuperTriggerCellImpl::createAllTriggerCells(), HGCalTriggerNtupleHGCTriggerCells::fill(), HGCalCoarseTriggerCellMapping::getCoarseTriggerCellId(), HGCalCoarseTriggerCellMapping::getConstituentTriggerCells(), HGCalVFEProcessorSums::run(), HGCalConcentratorProcessorSelection::run(), and HGCalVFESummationImpl::triggerCellSums().
|
inline |
Definition at line 84 of file HGCalTriggerTools.h.
References geom_, and HGCalTriggerGeometryBase::triggerLayer().
Referenced by HGCalTriggerClusterInterpretationEM::interpret().
int HGCalTriggerTools::zside | ( | const DetId & | id | ) | const |
Definition at line 210 of file HGCalTriggerTools.cc.
References DetId::Forward, DetId::Hcal, HcalEndcap, HFNose, HFNoseTrigger, DetId::HGCalEE, HGCalEETrigger, DetId::HGCalHSc, DetId::HGCalHSi, HGCalHSiTrigger, DetId::HGCalTrigger, HGCScintillatorDetId::zside(), HGCalDetId::zside(), HGCalTriggerDetId::zside(), HFNoseTriggerDetId::zside(), HFNoseDetId::zside(), HGCSiliconDetId::zside(), and HcalDetId::zside().
Referenced by HGCalMulticlusteringImpl::clusterizeDBSCAN(), HGCalHistoClusteringImpl::clusterSeedMulticluster(), HGCalTriggerNtupleHGCTriggerSums::fill(), HGCalTriggerNtupleHGCDigis::fill(), HGCalTriggerNtupleHGCTriggerCells::fill(), HGCalHistoSeedingImpl::fillHistoClusters(), HGCalTriggerTowerGeometryHelper::HGCalTriggerTowerGeometryHelper(), HGCalMulticlusteringImpl::isPertinent(), HGCalClusteringImpl::isPertinent(), and HGCalClusteringImpl::triggerCellReshuffling().
|
private |
Definition at line 99 of file HGCalTriggerTools.h.
Referenced by eventSetup(), and layers().
|
private |
Definition at line 97 of file HGCalTriggerTools.h.
Referenced by eventSetup(), lastLayerEE(), lastLayerFH(), layers(), and layerWithOffset().
|
private |
Definition at line 98 of file HGCalTriggerTools.h.
Referenced by eventSetup(), lastLayerFH(), layers(), and layerWithOffset().
|
private |
Definition at line 96 of file HGCalTriggerTools.h.
Referenced by eventSetup(), getLayerZ(), getTCPosition(), getTriggerGeometry(), layerWithOffset(), sensorCellThicknessV8(), thicknessIndex(), and triggerLayer().
|
staticconstexpr |
Definition at line 86 of file HGCalTriggerTools.h.
Referenced by thicknessIndex().
|
private |
Definition at line 100 of file HGCalTriggerTools.h.
Referenced by eventSetup(), lastLayerNose(), and layers().
|
private |
Definition at line 101 of file HGCalTriggerTools.h.
Referenced by eventSetup(), lastLayerBH(), and layers().