#include <L1GtEtaPhiConversions.h>
Public Member Functions | |
const bool | convertEtaIndex (const L1GtObject &, const unsigned int initialIndex, unsigned int &convertedIndex) const |
void | convertL1Scales (const L1CaloGeometry *, const L1MuTriggerScales *, const int, const int) |
perform all scale conversions More... | |
const bool | convertPhiIndex (const unsigned int pairIndex, const unsigned int positionPair, const unsigned int initialIndex, unsigned int &convertedIndex) const |
const unsigned int | gtObjectNrBinsPhi (const L1GtObject &) const |
return the number of phi bins for a GT object More... | |
const unsigned int | gtObjectNrBinsPhi (const L1GtObject &, const L1GtObject &) const |
return the number of phi bins for a pair of GT objects, according to conversion rules More... | |
const unsigned int | gtObjectNrBinsPhi (const unsigned int) const |
const unsigned int | gtObjectPairIndex (const L1GtObject &, const L1GtObject &) const |
L1GtEtaPhiConversions () | |
constructor More... | |
virtual void | print (std::ostream &myCout) const |
print all the performed conversions More... | |
void | setVerbosity (const int verbosity) |
virtual | ~L1GtEtaPhiConversions () |
destructor More... | |
Private Member Functions | |
const double | rad2deg (const double &) const |
convert phi from rad (-pi, pi] to deg (0, 360) More... | |
Private Attributes | |
std::vector< std::pair < L1GtObject, L1GtObject > > | m_gtObjectPairVec |
vector of all L1GtObject pairs More... | |
bool | m_isDebugEnabled |
cached edm::isDebugEnabled() More... | |
const L1CaloGeometry * | m_l1CaloGeometry |
pointer to calorimetry scales - updated in convertl1Scales method More... | |
const L1MuTriggerScales * | m_l1MuTriggerScales |
pointer to muon scales - updated in convertl1Scales method More... | |
std::vector< unsigned int > | m_lutEtaCentralToCommonCalo |
std::vector< unsigned int > | m_lutEtaForJetToCommonCalo |
eta conversion of ForJet to the common calorimeter eta scale defined before More... | |
std::vector< unsigned int > | m_lutEtaMuToCommonCalo |
eta conversion of Mu to the common calorimeter eta scale defined before More... | |
std::vector< unsigned int > | m_lutPhiEtmToHtm |
phi conversion for ETM to HTM More... | |
std::vector< unsigned int > | m_lutPhiEtmToJetEg |
phi conversion for ETM to (*Jet, EG) More... | |
std::vector< unsigned int > | m_lutPhiHtmToJetEg |
phi conversion for HTM to (*Jet, EG) More... | |
std::vector< unsigned int > | m_lutPhiJetEgToJetEg |
std::vector< unsigned int > | m_lutPhiMuToEtm |
phi conversion for Mu to ETM More... | |
std::vector< unsigned int > | m_lutPhiMuToHtm |
phi conversion for Mu to HTM More... | |
std::vector< unsigned int > | m_lutPhiMuToJetEg |
phi conversion for Mu to (*Jet, EG) More... | |
unsigned int | m_nrBinsEtaCommon |
number of eta bins for common scale More... | |
unsigned int | m_nrBinsPhiEtm |
number of phi bins for ETM More... | |
unsigned int | m_nrBinsPhiHtm |
number of phi bins for HTM More... | |
unsigned int | m_nrBinsPhiJetEg |
number of phi bins for calorimeter objects (*Jet, *EG) More... | |
unsigned int | m_nrBinsPhiMu |
number of phi bins for muons More... | |
std::vector< bool > | m_pairConvertPhiFirstGtObject |
std::vector< const unsigned int * > | m_pairNrPhiBinsVec |
std::vector< const std::vector < unsigned int > * > | m_pairPhiConvVec |
int | m_verbosity |
verbosity level More... | |
Static Private Attributes | |
static const unsigned int | badIndex = 999999 |
static const double | PiConversion = 180. / acos(-1.) |
Description: convert eta and phi between various L1 trigger objects.
Implementation: <TODO: enter implementation details>
Definition at line 36 of file L1GtEtaPhiConversions.h.
L1GtEtaPhiConversions::L1GtEtaPhiConversions | ( | ) |
constructor
Definition at line 38 of file L1GtEtaPhiConversions.cc.
References CenJet, ETM, ForJet, HTM, IsoEG, l1GtObjectEnumToString(), LogTrace, m_gtObjectPairVec, m_isDebugEnabled, m_lutPhiEtmToHtm, m_lutPhiEtmToJetEg, m_lutPhiHtmToJetEg, m_lutPhiJetEgToJetEg, m_lutPhiMuToEtm, m_lutPhiMuToHtm, m_lutPhiMuToJetEg, m_nrBinsPhiEtm, m_nrBinsPhiHtm, m_nrBinsPhiJetEg, m_pairConvertPhiFirstGtObject, m_pairNrPhiBinsVec, m_pairPhiConvVec, Mu, NoIsoEG, and TauJet.
|
virtual |
destructor
Definition at line 450 of file L1GtEtaPhiConversions.cc.
const bool L1GtEtaPhiConversions::convertEtaIndex | ( | const L1GtObject & | gtObject, |
const unsigned int | initialIndex, | ||
unsigned int & | convertedIndex | ||
) | const |
convert the eta index initialIndex for a L1GtObject object to common scale converted index returned by reference method return true, if initial index within scale size otherwise (hardware error), return false
Definition at line 638 of file L1GtEtaPhiConversions.cc.
References badIndex, BPTX, CenJet, ETM, ETT, ForJet, GtExternal, HfBitCounts, HfRingEtSums, HTM, HTT, IsoEG, JetCounts, l1GtObjectEnumToString(), LogTrace, m_isDebugEnabled, m_lutEtaCentralToCommonCalo, m_lutEtaForJetToCommonCalo, m_lutEtaMuToCommonCalo, m_verbosity, Mu, NoIsoEG, ObjNull, TauJet, and TechTrig.
Referenced by L1GtCorrelationCondition::evaluateCondition().
void L1GtEtaPhiConversions::convertL1Scales | ( | const L1CaloGeometry * | l1CaloGeometry, |
const L1MuTriggerScales * | l1MuTriggerScales, | ||
const int | ifCaloEtaNumberBits, | ||
const int | ifMuEtaNumberBits | ||
) |
perform all scale conversions
Definition at line 948 of file L1GtEtaPhiConversions.cc.
References badIndex, TauDecayModes::dec, L1CaloGeometry::emJetPhiBinHighEdge(), L1CaloGeometry::emJetPhiBinLowEdge(), L1CaloGeometry::etaBinCenter(), L1CaloGeometry::etSumPhiBinHighEdge(), L1CaloGeometry::etSumPhiBinLowEdge(), L1MuTriggerScales::getGMTEtaScale(), L1MuScale::getHighEdge(), L1MuScale::getLowEdge(), L1MuScale::getNBins(), L1MuTriggerScales::getPhiScale(), L1MuScale::getValue(), L1CaloGeometry::globalEtaBinLowEdge(), L1CaloGeometry::globalEtaIndex(), L1CaloGeometry::htSumPhiBinHighEdge(), L1CaloGeometry::htSumPhiBinLowEdge(), l1CaloGeometry_cfi::l1CaloGeometry, LogDebug, LogTrace, m_isDebugEnabled, m_l1CaloGeometry, m_l1MuTriggerScales, m_lutEtaCentralToCommonCalo, m_lutEtaForJetToCommonCalo, m_lutEtaMuToCommonCalo, m_lutPhiEtmToHtm, m_lutPhiEtmToJetEg, m_lutPhiHtmToJetEg, m_lutPhiJetEgToJetEg, m_lutPhiMuToEtm, m_lutPhiMuToHtm, m_lutPhiMuToJetEg, m_nrBinsEtaCommon, m_nrBinsPhiEtm, m_nrBinsPhiHtm, m_nrBinsPhiJetEg, m_nrBinsPhiMu, m_verbosity, L1CaloGeometry::numberGctCentralEtaBinsPerHalf(), L1CaloGeometry::numberGctEmJetPhiBins(), L1CaloGeometry::numberGctEtSumPhiBins(), L1CaloGeometry::numberGctForwardEtaBinsPerHalf(), and L1CaloGeometry::numberGctHtSumPhiBins().
Referenced by L1GlobalTriggerGTL::run().
const bool L1GtEtaPhiConversions::convertPhiIndex | ( | const unsigned int | pairIndex, |
const unsigned int | positionPair, | ||
const unsigned int | initialIndex, | ||
unsigned int & | convertedIndex | ||
) | const |
convert the phi index initialIndex for an object from pair pairIndex, with position of object in pair positionPair to common scale for the L1GtObject pair converted index returned by reference method return true, if initial index within scale size otherwise (hardware error), return false
Definition at line 491 of file L1GtEtaPhiConversions.cc.
References badIndex, Exception, LogTrace, m_isDebugEnabled, m_pairConvertPhiFirstGtObject, m_pairPhiConvVec, and m_verbosity.
Referenced by L1GtCorrelationCondition::evaluateCondition().
const unsigned int L1GtEtaPhiConversions::gtObjectNrBinsPhi | ( | const L1GtObject & | gtObject | ) | const |
return the number of phi bins for a GT object
Definition at line 844 of file L1GtEtaPhiConversions.cc.
References BPTX, CenJet, ETM, ETT, ForJet, GtExternal, HfBitCounts, HfRingEtSums, HTM, HTT, IsoEG, JetCounts, l1GtObjectEnumToString(), m_nrBinsPhiEtm, m_nrBinsPhiHtm, m_nrBinsPhiJetEg, m_nrBinsPhiMu, Mu, NoIsoEG, ObjNull, TauJet, and TechTrig.
Referenced by L1GtCorrelationCondition::evaluateCondition(), and L1GlobalTriggerGTL::run().
const unsigned int L1GtEtaPhiConversions::gtObjectNrBinsPhi | ( | const L1GtObject & | obj0, |
const L1GtObject & | obj1 | ||
) | const |
return the number of phi bins for a pair of GT objects, according to conversion rules
Definition at line 903 of file L1GtEtaPhiConversions.cc.
References l1GtObjectEnumToString(), LogTrace, m_gtObjectPairVec, and m_pairNrPhiBinsVec.
const unsigned int L1GtEtaPhiConversions::gtObjectNrBinsPhi | ( | const unsigned int | pairIndex | ) | const |
return the number of phi bins for a pair of GT objects, according to conversion rules, when the index of the pair is used
Definition at line 932 of file L1GtEtaPhiConversions.cc.
References LogTrace, m_isDebugEnabled, m_pairNrPhiBinsVec, and m_verbosity.
const unsigned int L1GtEtaPhiConversions::gtObjectPairIndex | ( | const L1GtObject & | obj0, |
const L1GtObject & | obj1 | ||
) | const |
return the index of a pair in the vector m_gtObjectPairVec, to be used to extract the number of phi bins, the conversion of the indices, etc
Definition at line 458 of file L1GtEtaPhiConversions.cc.
References l1GtObjectEnumToString(), LogTrace, and m_gtObjectPairVec.
Referenced by L1GtCorrelationCondition::evaluateCondition().
|
virtual |
print all the performed conversions
Definition at line 1380 of file L1GtEtaPhiConversions.cc.
References badIndex, TauDecayModes::dec, L1CaloGeometry::emJetPhiBinHighEdge(), L1CaloGeometry::emJetPhiBinLowEdge(), L1CaloGeometry::etaBinCenter(), L1CaloGeometry::etSumPhiBinHighEdge(), L1CaloGeometry::etSumPhiBinLowEdge(), L1MuTriggerScales::getGMTEtaScale(), L1MuScale::getHighEdge(), L1MuScale::getLowEdge(), L1MuScale::getNBins(), L1MuTriggerScales::getPhiScale(), L1MuScale::getValue(), L1CaloGeometry::globalEtaBinLowEdge(), L1CaloGeometry::globalEtaIndex(), L1CaloGeometry::htSumPhiBinHighEdge(), L1CaloGeometry::htSumPhiBinLowEdge(), m_l1CaloGeometry, m_l1MuTriggerScales, m_lutEtaCentralToCommonCalo, m_lutEtaForJetToCommonCalo, m_lutEtaMuToCommonCalo, m_lutPhiEtmToHtm, m_lutPhiEtmToJetEg, m_lutPhiHtmToJetEg, m_lutPhiMuToEtm, m_lutPhiMuToHtm, m_lutPhiMuToJetEg, and rad2deg().
Referenced by L1GlobalTriggerGTL::run().
|
private |
convert phi from rad (-pi, pi] to deg (0, 360)
Definition at line 1908 of file L1GtEtaPhiConversions.cc.
References PiConversion.
Referenced by print().
|
inline |
Definition at line 84 of file L1GtEtaPhiConversions.h.
References m_verbosity, and HLT_25ns10e33_v2_cff::verbosity.
Referenced by L1GlobalTriggerGTL::L1GlobalTriggerGTL(), and L1GlobalTriggerGTL::run().
|
staticprivate |
a bad index value, treated specially when performing the conversions or printing the conversion vectors
Definition at line 98 of file L1GtEtaPhiConversions.h.
Referenced by convertEtaIndex(), convertL1Scales(), convertPhiIndex(), and print().
|
private |
vector of all L1GtObject pairs
Definition at line 110 of file L1GtEtaPhiConversions.h.
Referenced by gtObjectNrBinsPhi(), gtObjectPairIndex(), and L1GtEtaPhiConversions().
|
private |
cached edm::isDebugEnabled()
Definition at line 197 of file L1GtEtaPhiConversions.h.
Referenced by convertEtaIndex(), convertL1Scales(), convertPhiIndex(), gtObjectNrBinsPhi(), and L1GtEtaPhiConversions().
|
private |
pointer to calorimetry scales - updated in convertl1Scales method
Definition at line 132 of file L1GtEtaPhiConversions.h.
Referenced by convertL1Scales(), and print().
|
private |
pointer to muon scales - updated in convertl1Scales method
Definition at line 135 of file L1GtEtaPhiConversions.h.
Referenced by convertL1Scales(), and print().
|
private |
eta conversion of CenJet/TauJet & IsoEG/NoIsoEG to a common calorimeter eta scale
Definition at line 183 of file L1GtEtaPhiConversions.h.
Referenced by convertEtaIndex(), convertL1Scales(), and print().
|
private |
eta conversion of ForJet to the common calorimeter eta scale defined before
Definition at line 186 of file L1GtEtaPhiConversions.h.
Referenced by convertEtaIndex(), convertL1Scales(), and print().
|
private |
eta conversion of Mu to the common calorimeter eta scale defined before
Definition at line 189 of file L1GtEtaPhiConversions.h.
Referenced by convertEtaIndex(), convertL1Scales(), and print().
|
private |
phi conversion for ETM to HTM
Definition at line 169 of file L1GtEtaPhiConversions.h.
Referenced by convertL1Scales(), L1GtEtaPhiConversions(), and print().
|
private |
phi conversion for ETM to (*Jet, EG)
Definition at line 166 of file L1GtEtaPhiConversions.h.
Referenced by convertL1Scales(), L1GtEtaPhiConversions(), and print().
|
private |
phi conversion for HTM to (*Jet, EG)
Definition at line 172 of file L1GtEtaPhiConversions.h.
Referenced by convertL1Scales(), L1GtEtaPhiConversions(), and print().
|
private |
phi conversion for (*Jet, EG) to (*Jet, EG) return the same index as the input index, introduced only to simplify convertPhiIndex
Definition at line 177 of file L1GtEtaPhiConversions.h.
Referenced by convertL1Scales(), and L1GtEtaPhiConversions().
|
private |
phi conversion for Mu to ETM
Definition at line 160 of file L1GtEtaPhiConversions.h.
Referenced by convertL1Scales(), L1GtEtaPhiConversions(), and print().
|
private |
phi conversion for Mu to HTM
Definition at line 163 of file L1GtEtaPhiConversions.h.
Referenced by convertL1Scales(), L1GtEtaPhiConversions(), and print().
|
private |
phi conversion for Mu to (*Jet, EG)
Definition at line 157 of file L1GtEtaPhiConversions.h.
Referenced by convertL1Scales(), L1GtEtaPhiConversions(), and print().
|
private |
number of eta bins for common scale
Definition at line 152 of file L1GtEtaPhiConversions.h.
Referenced by convertL1Scales().
|
private |
number of phi bins for ETM
Definition at line 146 of file L1GtEtaPhiConversions.h.
Referenced by convertL1Scales(), gtObjectNrBinsPhi(), and L1GtEtaPhiConversions().
|
private |
number of phi bins for HTM
Definition at line 149 of file L1GtEtaPhiConversions.h.
Referenced by convertL1Scales(), gtObjectNrBinsPhi(), and L1GtEtaPhiConversions().
|
private |
number of phi bins for calorimeter objects (*Jet, *EG)
Definition at line 143 of file L1GtEtaPhiConversions.h.
Referenced by convertL1Scales(), gtObjectNrBinsPhi(), and L1GtEtaPhiConversions().
|
private |
number of phi bins for muons
Definition at line 140 of file L1GtEtaPhiConversions.h.
Referenced by convertL1Scales(), and gtObjectNrBinsPhi().
|
private |
decide which object to convert: if m_pairConvertPhiFirstGtObject true, convert pair.first and do not convert pair.second if m_pairConvertPhiFirstGtObject false, do not convert pair.first and convert pair.second
Definition at line 115 of file L1GtEtaPhiConversions.h.
Referenced by convertPhiIndex(), and L1GtEtaPhiConversions().
|
private |
number of phi bins for each L1GtObject pair in the scale used for that pair it is filled correlated with m_gtObjectPairVec, so the index of the pair in m_gtObjectPairVec is the index of the m_pairNrPhiBinsVec element containing the number of phi bins
Definition at line 121 of file L1GtEtaPhiConversions.h.
Referenced by gtObjectNrBinsPhi(), and L1GtEtaPhiConversions().
|
private |
constant references to conversion LUT for a given L1GtObject pair it is filled correlated with m_gtObjectPairVec, so the index of the pair in m_gtObjectPairVec is the index of the m_pairPhiConvVec element containing the reference
Definition at line 127 of file L1GtEtaPhiConversions.h.
Referenced by convertPhiIndex(), and L1GtEtaPhiConversions().
|
private |
verbosity level
Definition at line 194 of file L1GtEtaPhiConversions.h.
Referenced by convertEtaIndex(), convertL1Scales(), convertPhiIndex(), gtObjectNrBinsPhi(), and setVerbosity().
|
staticprivate |
Definition at line 101 of file L1GtEtaPhiConversions.h.
Referenced by rad2deg().