Emulates a leaf card programmed for electron sorting. More...
#include <L1GctEmLeafCard.h>
Public Member Functions | |
virtual void | fetchInput () |
L1GctElectronSorter * | getIsoElectronSorterU1 () |
L1GctElectronSorter * | getIsoElectronSorterU2 () |
L1GctElectronSorter * | getNonIsoElectronSorterU1 () |
L1GctElectronSorter * | getNonIsoElectronSorterU2 () |
std::vector< L1GctEmCand > | getOutputIsoEmCands (int fpga) |
std::vector< L1GctEmCand > | getOutputNonIsoEmCands (int fpga) |
int | id () |
L1GctEmLeafCard (int id) | |
construct with ID | |
virtual void | process () |
void | reset () |
clear buffers | |
void | setBxRange (const int firstBx, const int numberOfBx) |
partially clear buffers | |
void | setNextBx (const int bxnum) |
partially clear buffers | |
~L1GctEmLeafCard () | |
Static Public Attributes | |
static const unsigned | N_SORTERS = 4 |
Protected Member Functions | |
virtual void | resetPipelines () |
virtual void | resetProcessor () |
Separate reset methods for the processor itself and any data stored in pipelines. | |
virtual void | setupObjects () |
Initialise inputs with null objects for the correct bunch crossing if required. | |
Private Attributes | |
int | m_id |
card ID (0 or 1) | |
std::vector < L1GctElectronSorter * > | m_sorters |
Friends | |
std::ostream & | operator<< (std::ostream &s, const L1GctEmLeafCard &card) |
Emulates a leaf card programmed for electron sorting.
L1GctEmLeafCard This class does the 1st stage sorting of the electron candidates.
Definition at line 20 of file L1GctEmLeafCard.h.
L1GctEmLeafCard::L1GctEmLeafCard | ( | int | id | ) |
construct with ID
Definition at line 10 of file L1GctEmLeafCard.cc.
References m_sorters.
: m_id(id), m_sorters(4) { // sorters 0 and 1 are in FPGA U1 and deal with RCT crates 4-8 (13-17) m_sorters.at(0) = new L1GctElectronSorter(5,true); m_sorters.at(1) = new L1GctElectronSorter(5,false); // sorters 2 and 3 are in FPGA U2 and deal with RCT crates 0-3 (9-12) m_sorters.at(2) = new L1GctElectronSorter(4,true); m_sorters.at(3) = new L1GctElectronSorter(4,false); }
L1GctEmLeafCard::~L1GctEmLeafCard | ( | ) |
void L1GctEmLeafCard::fetchInput | ( | ) | [virtual] |
L1GctElectronSorter* L1GctEmLeafCard::getIsoElectronSorterU1 | ( | ) | [inline] |
Definition at line 58 of file L1GctEmLeafCard.h.
References m_sorters.
Referenced by L1GctElectronFinalSort::fetchInput().
{ return m_sorters.at(0); }
L1GctElectronSorter* L1GctEmLeafCard::getIsoElectronSorterU2 | ( | ) | [inline] |
Definition at line 60 of file L1GctEmLeafCard.h.
References m_sorters.
Referenced by L1GctElectronFinalSort::fetchInput().
{ return m_sorters.at(2); }
L1GctElectronSorter* L1GctEmLeafCard::getNonIsoElectronSorterU1 | ( | ) | [inline] |
Definition at line 59 of file L1GctEmLeafCard.h.
References m_sorters.
Referenced by L1GctElectronFinalSort::fetchInput().
{ return m_sorters.at(1); }
L1GctElectronSorter* L1GctEmLeafCard::getNonIsoElectronSorterU2 | ( | ) | [inline] |
Definition at line 61 of file L1GctEmLeafCard.h.
References m_sorters.
Referenced by L1GctElectronFinalSort::fetchInput().
{ return m_sorters.at(3); }
vector< L1GctEmCand > L1GctEmLeafCard::getOutputIsoEmCands | ( | int | fpga | ) |
get the output candidates
Definition at line 73 of file L1GctEmLeafCard.cc.
References m_sorters.
{ if (fpga<2) { return m_sorters.at(2*fpga)->getOutputCands(); } else { return vector<L1GctEmCand>(0); } }
vector< L1GctEmCand > L1GctEmLeafCard::getOutputNonIsoEmCands | ( | int | fpga | ) |
get the output candidates
Definition at line 83 of file L1GctEmLeafCard.cc.
References m_sorters.
{ if (fpga<2) { return m_sorters.at(2*fpga+1)->getOutputCands(); } else { return vector<L1GctEmCand>(0); } }
int L1GctEmLeafCard::id | ( | void | ) | [inline] |
void L1GctEmLeafCard::process | ( | ) | [virtual] |
void L1GctEmLeafCard::reset | ( | void | ) |
clear buffers
clear internal trigger data buffers
Reimplemented from L1GctProcessor.
Definition at line 35 of file L1GctEmLeafCard.cc.
virtual void L1GctEmLeafCard::resetPipelines | ( | ) | [inline, protected, virtual] |
virtual void L1GctEmLeafCard::resetProcessor | ( | ) | [inline, protected, virtual] |
Separate reset methods for the processor itself and any data stored in pipelines.
Implements L1GctProcessor.
Definition at line 66 of file L1GctEmLeafCard.h.
{}
void L1GctEmLeafCard::setBxRange | ( | const int | firstBx, |
const int | numberOfBx | ||
) |
partially clear buffers
define the bunch crossing range to process
Reimplemented from L1GctProcessor.
Definition at line 43 of file L1GctEmLeafCard.cc.
void L1GctEmLeafCard::setNextBx | ( | const int | bxnum | ) |
partially clear buffers
clear input data buffers and process a new bunch crossing
Reimplemented from L1GctProcessor.
Definition at line 51 of file L1GctEmLeafCard.cc.
virtual void L1GctEmLeafCard::setupObjects | ( | ) | [inline, protected, virtual] |
Initialise inputs with null objects for the correct bunch crossing if required.
Implements L1GctProcessor.
Definition at line 70 of file L1GctEmLeafCard.h.
{}
std::ostream& operator<< | ( | std::ostream & | s, |
const L1GctEmLeafCard & | card | ||
) | [friend] |
overload of cout operator
int L1GctEmLeafCard::m_id [private] |
card ID (0 or 1)
Definition at line 74 of file L1GctEmLeafCard.h.
Referenced by id(), and operator<<().
std::vector<L1GctElectronSorter*> L1GctEmLeafCard::m_sorters [private] |
processing - 0,2 are iso sorters, 1,3 are non-iso
Definition at line 77 of file L1GctEmLeafCard.h.
Referenced by fetchInput(), getIsoElectronSorterU1(), getIsoElectronSorterU2(), getNonIsoElectronSorterU1(), getNonIsoElectronSorterU2(), getOutputIsoEmCands(), getOutputNonIsoEmCands(), L1GctEmLeafCard(), operator<<(), process(), reset(), setBxRange(), setNextBx(), and ~L1GctEmLeafCard().
const unsigned L1GctEmLeafCard::N_SORTERS = 4 [static] |
Definition at line 22 of file L1GctEmLeafCard.h.
Referenced by fetchInput(), process(), reset(), setBxRange(), and setNextBx().