17 const std::vector<L1GctWheelJetFpga*>& wheelJetFpga)
19 m_plusWheelFpga(wheelFpga.at(1)),
20 m_minusWheelFpga(wheelFpga.at(0)),
21 m_plusWheelJetFpga(wheelJetFpga.at(1)),
22 m_minusWheelJetFpga(wheelJetFpga.at(0)),
23 m_metComponents(0, 0,
L1GctMet::cordicTranslate),
24 m_mhtComponents(0, 0,
L1GctMet::useHtMissLut),
46 if (wheelFpga.size() != 2) {
49 edm::LogWarning(
"L1GctSetupError") <<
"L1GctGlobalEnergyAlgos::L1GctGlobalEnergyAlgos() : Global Energy Algos " 50 "has been incorrectly constructed!\n" 51 <<
"This class needs two wheel card pointers. " 52 <<
"Number of wheel card pointers present is " << wheelFpga.size() <<
".\n";
56 if (wheelJetFpga.size() != 2) {
59 edm::LogWarning(
"L1GctSetupError") <<
"L1GctGlobalEnergyAlgos::L1GctGlobalEnergyAlgos() : Global Energy Algos " 60 "has been incorrectly constructed!\n" 61 <<
"This class needs two wheel jet fpga pointers. " 62 <<
"Number of wheel jet fpga pointers present is " << wheelJetFpga.size()
71 <<
"L1GctGlobalEnergyAlgos::L1GctGlobalEnergyAlgos() has been incorrectly constructed!\n" 72 <<
"Plus Wheel Fpga pointer has not been set!\n";
79 <<
"L1GctGlobalEnergyAlgos::L1GctGlobalEnergyAlgos() has been incorrectly constructed!\n" 80 <<
"Minus Wheel Fpga pointer has not been set!\n";
87 <<
"L1GctGlobalEnergyAlgos::L1GctGlobalEnergyAlgos() has been incorrectly constructed!\n" 88 <<
"Plus Wheel Jet Fpga pointer has not been set!\n";
95 <<
"L1GctGlobalEnergyAlgos::L1GctGlobalEnergyAlgos() has been incorrectly constructed!\n" 96 <<
"Minus Wheel Jet Fpga pointer has not been set!\n";
114 edm::LogError(
"L1GctSetupError") <<
"L1GctGlobalEnergyAlgos has been incorrectly constructed";
125 os <<
"===L1GctGlobalEnergyAlgos===" << endl;
130 os <<
"Inputs from Plus wheel:" << endl;
133 os <<
"Inputs from Minus wheel:" << endl;
136 int bxZero = -fpga.
bxMin();
137 if (bxZero >= 0 && bxZero < fpga.
numOfBx()) {
140 os <<
"Output EtSum " << fpga.
m_outputEtSum.contents.at(bxZero) << endl;
141 os <<
"Output EtHad " << fpga.
m_outputEtHad.contents.at(bxZero) << endl;
283 static const unsigned MAX_HT_VALUE = 0x7f;
284 static const unsigned PHI_HT_MASK = 0x1f;
333 }
else if (
wheel == 1) {
346 }
else if (
wheel == 1) {
359 }
else if (
wheel == 1) {
372 }
else if (
wheel == 1) {
385 }
else if (
wheel == 1) {
398 }
else if (
wheel == 1) {
etTotalType m_etValPlusWheel
void setOverFlow(bool oflow)
set the overflow bit
void reset()
complete reset of processor
etmiss_vec metVector() const
void process() override
process the data, fill output buffers
void fetchInput() override
get input data from sources; this is the standard way to provide input
void resetPipelines() override
void reset()
clear internal buffers
Pipeline< etMissType > m_outputHtMiss
void setOverFlow(bool oflow)
set the overflow bit
etComponentType m_eyValPlusWheel
Emulates the GCT summing and packing of Hf Et sums and tower-over-threshold counts.
etComponentType m_exValPlusWheel
Pipeline< etComponentType > m_eyVlMinusPipe
unsigned value() const
access value as unsigned
Pipeline< etComponentType > m_exValPlusPipe
bool m_verbose
Flag to control output messages.
void fetchInput() override
get input data from sources
double getHtLsbGeV() const
void setInputWheelEx(unsigned wheel, int energy, bool overflow)
set input Ex value per wheel (0 or 1); not used in normal operation
Pipeline< etMissPhiType > m_outputHtMissPhi
etComponentType m_hxValPlusWheel
Pipeline< etComponentType > m_hyVlMinusPipe
Pipeline< etComponentType > m_hxVlMinusPipe
Pipeline< etComponentType > m_hxValPlusPipe
void setInputWheelHy(unsigned wheel, unsigned energy, bool overflow)
void setJetFinderParams(const L1GctJetFinderParams *const jfpars)
etComponentType getOutputEx() const
get output Ex value
L1GctWheelJetFpga * m_plusWheelJetFpga
Log< level::Error, false > LogError
bool setupOk() const
check setup
Stores Level-1 missing Et in (Ex, Ey) form, allowing it to be retrieved as (magnitude, angle)
void setComponents(const unsigned ex, const unsigned ey)
bool overFlow() const
access overflow
etComponentType m_eyVlMinusWheel
void setHtMissScale(const L1CaloEtScale *const scale)
ABC for a GCT trigger data processing unit.
void setEtScale(const L1CaloEtScale *const fn)
etTotalType getOutputEt() const
get output Et value
Pipeline< etHadType > m_outputEtHad
int bxMin() const
Support for multiple beam crossing operation.
L1GctWheelEnergyFpga * m_minusWheelFpga
void setInputWheelHx(unsigned wheel, unsigned energy, bool overflow)
set input Ht component values per wheel (0 or 1); not used in normal operation
Pipeline< etTotalType > m_etValPlusPipe
L1GctGlobalHfSumAlgos * m_hfSumProcessor
ostream & operator<<(ostream &os, const L1GctGlobalEnergyAlgos &fpga)
Emulates the GCT global energy algorithms.
etHadType m_htValPlusWheel
void process() override
process the data, fill output buffers
Pipeline< etComponentType > m_hyValPlusPipe
etComponentType getOutputEy() const
get output Ey value
etTotalType m_etVlMinusWheel
void setBxRange(const int firstBx, const int numberOfBx)
define the bunch crossing range to process
void setBxRange(const int firstBx, const int numberOfBx)
define the bunch crossing range to process
void setValue(int value)
set value from signed int
Pipeline< etHadType > m_htValPlusPipe
void setInputWheelHt(unsigned wheel, unsigned energy, bool overflow)
set input Ht value per wheel (0 or 1); not used in normal operation
L1GctGlobalEnergyAlgos(const std::vector< L1GctWheelEnergyFpga *> &WheelFpga, const std::vector< L1GctWheelJetFpga *> &WheelJetFpga)
Constructor needs the Wheel card Fpgas set up first.
etComponentType m_exVlMinusWheel
L1GctWheelJetFpga * m_minusWheelJetFpga
Pipeline< etComponentType > m_exVlMinusPipe
void setInputWheelEy(unsigned wheel, int energy, bool overflow)
set input Ey value per wheel (0 or 1); not used in normal operation
Pipeline< etMissPhiType > m_outputEtMissPhi
L1GctWheelEnergyFpga * m_plusWheelFpga
Pipeline< etComponentType > m_eyValPlusPipe
etHadType m_htVlMinusWheel
Pipeline< etMissType > m_outputEtMiss
void reset()
reset value and overflow to zero
void setValue(unsigned value)
Set value from unsigned.
bool setupOk() const
check setup
~L1GctGlobalEnergyAlgos() override
Destructor.
etComponentType m_hyVlMinusWheel
Pipeline< etHadType > m_htVlMinusPipe
etComponentType m_hyValPlusWheel
void reset()
reset value and overflow to zero
htComponentType getOutputHy() const
Log< level::Warning, false > LogWarning
etComponentType m_hxVlMinusWheel
void setNextBx(const int bx)
partially clear buffers
void setNextBx(const int bxnum)
clear input data buffers and process a new bunch crossing
Pipeline< etTotalType > m_outputEtSum
Pipeline< etTotalType > m_etVlMinusPipe
void resetProcessor() override
Separate reset methods for the processor itself and any data stored in pipelines. ...
htComponentType getOutputHx() const
get the output Ht components
void setInputWheelEt(unsigned wheel, unsigned energy, bool overflow)
set input Et value per wheel (0 or 1); not used in normal operation
void setBitShift(const unsigned nbits)
etHadType getOutputHt() const
get the output Ht
void setEtComponentLsb(const double lsb)