Class that sorts electron candidates. More...
#include <L1GctElectronSorter.h>
Classes | |
struct | prioritisedEmCand |
Public Member Functions | |
void | fetchInput () override |
get input data from sources More... | |
std::vector< L1CaloEmCand > | getInputCands () |
get input candidates More... | |
std::vector< L1GctEmCand > | getOutputCands () |
get output candidates More... | |
L1GctElectronSorter (int nInputs, bool iso) | |
constructor; set type (isolated or non-isolated) More... | |
void | process () override |
process the data, fill output buffers More... | |
void | setInputEmCand (const L1CaloEmCand &cand) |
set input candidate More... | |
~L1GctElectronSorter () override | |
Public Member Functions inherited from L1GctProcessor | |
L1GctProcessor () | |
void | reset () |
complete reset of processor More... | |
void | setBxRange (const int firstBx, const int numberOfBx) |
define the bunch crossing range to process More... | |
void | setNextBx (const int bxnum) |
clear input data buffers and process a new bunch crossing More... | |
void | setTerse () |
bool | setupOk () const |
Method to check the setup for this processor. Returns true by default. More... | |
void | setVerbose () |
control output messages More... | |
virtual | ~L1GctProcessor () |
Static Public Member Functions | |
static bool | rankByGt (const prioritisedEmCand &x, const prioritisedEmCand &y) |
Protected Member Functions | |
void | resetPipelines () override |
void | resetProcessor () override |
Separate reset methods for the processor itself and any data stored in pipelines. More... | |
void | setupObjects () override |
Initialise inputs with null objects for the correct bunch crossing if required. More... | |
Protected Member Functions inherited from L1GctProcessor | |
int | bxAbs () const |
int | bxMax () const |
int | bxMin () const |
Support for multiple beam crossing operation. More... | |
int | bxRel () const |
int | numOfBx () const |
Private Attributes | |
int | m_id |
algo ID (is it FPGA 1 or 2 processing) More... | |
std::vector< L1CaloEmCand > | m_inputCands |
input data More... | |
bool | m_isolation |
type of electron to sort (isolated = 0 or non isolated = 1) More... | |
std::vector< L1GctEmCand > | m_outputCands |
output data More... | |
Friends | |
std::ostream & | operator<< (std::ostream &s, const L1GctElectronSorter &card) |
overload of cout operator More... | |
Additional Inherited Members | |
Protected Attributes inherited from L1GctProcessor | |
bool | m_verbose |
Flag to control output messages. More... | |
Class that sorts electron candidates.
L1GctElectronSorter This class can be constructed to sort iso or non-iso electron candidates. The electrons are sorted in ascending order and the 4 highest in rank will be returned. It represents the 1st stage sorter FPGA's on the electron leaf cards.
Definition at line 26 of file L1GctElectronSorter.h.
L1GctElectronSorter::L1GctElectronSorter | ( | int | nInputs, |
bool | iso | ||
) |
constructor; set type (isolated or non-isolated)
Definition at line 4 of file L1GctElectronSorter.cc.
|
override |
Definition at line 7 of file L1GctElectronSorter.cc.
|
overridevirtual |
get input data from sources
Implements L1GctProcessor.
Definition at line 30 of file L1GctElectronSorter.cc.
|
inline |
get input candidates
Definition at line 67 of file L1GctElectronSorter.h.
References m_inputCands.
|
inline |
get output candidates
Definition at line 70 of file L1GctElectronSorter.h.
References m_outputCands.
Referenced by L1GctElectronFinalSort::fetchInput().
|
overridevirtual |
process the data, fill output buffers
Implements L1GctProcessor.
Definition at line 35 of file L1GctElectronSorter.cc.
References HltBtagPostValidation_cff::c, data, mps_fire::i, m_inputCands, m_outputCands, rankByGt(), and jetUpdater_cfi::sort.
|
inlinestatic |
comparison operator for sort, used here and in the ElectronFinalSort Candidates of equal rank are sorted by priority, with the lower value given precedence
Definition at line 48 of file L1GctElectronSorter.h.
Referenced by L1GctElectronFinalSort::process(), and process().
|
inlineoverrideprotectedvirtual |
|
overrideprotectedvirtual |
Separate reset methods for the processor itself and any data stored in pipelines.
Implements L1GctProcessor.
Definition at line 10 of file L1GctElectronSorter.cc.
References m_id, m_inputCands, and m_outputCands.
void L1GctElectronSorter::setInputEmCand | ( | const L1CaloEmCand & | cand | ) |
set input candidate
Definition at line 54 of file L1GctElectronSorter.cc.
References FCDTask_cfi::crate, mps_fire::i, input, m_id, and m_inputCands.
|
overrideprotectedvirtual |
Initialise inputs with null objects for the correct bunch crossing if required.
Initialise inputs with null objects for the correct bunch crossing If no other input candidates "arrive", we have the correct bunch crossing to propagate through the processing.
Create a null input electron with the right bunch crossing, and fill the input candidates with copies of this.
Implements L1GctProcessor.
Definition at line 21 of file L1GctElectronSorter.cc.
References L1GctProcessor::bxAbs(), m_id, m_inputCands, and groupFilesInBlocks::temp.
|
friend |
|
private |
algo ID (is it FPGA 1 or 2 processing)
Definition at line 86 of file L1GctElectronSorter.h.
Referenced by resetProcessor(), setInputEmCand(), and setupObjects().
|
private |
input data
Definition at line 92 of file L1GctElectronSorter.h.
Referenced by getInputCands(), operator<<(), process(), resetProcessor(), setInputEmCand(), and setupObjects().
|
private |
type of electron to sort (isolated = 0 or non isolated = 1)
Definition at line 89 of file L1GctElectronSorter.h.
Referenced by operator<<().
|
private |
output data
Definition at line 95 of file L1GctElectronSorter.h.
Referenced by getOutputCands(), operator<<(), process(), and resetProcessor().