CMS 3D CMS Logo

L1GctWheelJetFpga.h
Go to the documentation of this file.
1 #ifndef L1GCTWHEELJETFPGA_H_
2 #define L1GCTWHEELJETFPGA_H_
3 
19 
22 
24 
25 class L1GctJetSorter;
26 
27 #include <vector>
28 
30 public:
31  typedef std::vector<L1GctJetCand> JetVector;
34 
36  static const int MAX_JETS_OUT;
37 
39  static const unsigned int MAX_LEAF_CARDS;
40 
42  static const unsigned int MAX_JETS_PER_LEAF;
43 
45  L1GctWheelJetFpga(int id, const std::vector<L1GctJetLeafCard*>& inputLeafCards);
46 
48  ~L1GctWheelJetFpga() override;
49 
51  friend std::ostream& operator<<(std::ostream& os, const L1GctWheelJetFpga& fpga);
52 
54  void fetchInput() override;
55 
57  void process() override;
58 
60  void setInputJet(int i, const L1GctJetCand& jet);
61 
63  JetVector getInputJets() const { return m_inputJets; }
64 
66  htComponentType inputHx(unsigned leafnum) const { return m_inputHx.at(leafnum); }
67  htComponentType inputHy(unsigned leafnum) const { return m_inputHy.at(leafnum); }
68 
70  hfTowerSumsType inputHfSums(unsigned leafnum) const { return m_inputHfSums.at(leafnum); }
71 
74 
77 
79  JetVector getTauJets() const { return m_tauJets; }
80 
84 
87 
89  bool setupOk() const { return checkSetup(); }
90 
92  std::vector<L1GctInternHtMiss> getInternalHtMiss() const;
93 
94 protected:
96  void resetProcessor() override;
97  void resetPipelines() override;
98 
100  void setupObjects() override;
101 
102 private:
103  static const int MAX_JETS_IN;
104 
106  int m_id;
107 
109  std::vector<L1GctJetLeafCard*> m_inputLeafCards;
110 
115 
118 
119  // Holds the all the various inputted jets, re-addressed using proper GCT->GT jet addressing
123 
124  // input Ht component sums from each leaf card
125  std::vector<htComponentType> m_inputHx;
126  std::vector<htComponentType> m_inputHy;
127 
128  // input Hf Et sums from each leaf card
129  std::vector<hfTowerSumsType> m_inputHfSums;
130 
131  // output data
135 
136  // data sent to GlobalEnergyAlgos
140 
141  Pipeline<htComponentType> m_outputHxPipe;
142  Pipeline<htComponentType> m_outputHyPipe;
143 
144  //PRIVATE METHODS
146  bool checkSetup() const;
148  void storeJets(const JetVector& jets, unsigned short iLeaf, unsigned short offset);
150  void classifyJets();
152  void setupJetsVectors(const int16_t bx);
153 };
154 
155 std::ostream& operator<<(std::ostream& os, const L1GctWheelJetFpga& fpga);
156 
157 #endif /*L1GCTWHEELJETFPGA_H_*/
L1GctWheelJetFpga::m_rawTauJets
JetVector m_rawTauJets
Definition: L1GctWheelJetFpga.h:122
L1GctWheelJetFpga::m_outputHfSums
hfTowerSumsType m_outputHfSums
Definition: L1GctWheelJetFpga.h:139
L1GctWheelJetFpga::getCentralJets
JetVector getCentralJets() const
get the output jets
Definition: L1GctWheelJetFpga.h:73
L1GctWheelJetFpga::inputHx
htComponentType inputHx(unsigned leafnum) const
get the input Ht components
Definition: L1GctWheelJetFpga.h:66
L1GctWheelJetFpga::m_forwardJetSorter
L1GctJetSorter * m_forwardJetSorter
Definition: L1GctWheelJetFpga.h:113
mps_fire.i
i
Definition: mps_fire.py:428
L1GctJetCand
Level-1 Trigger jet candidate.
Definition: L1GctJetCand.h:17
L1GctWheelJetFpga::m_tauJets
JetVector m_tauJets
Definition: L1GctWheelJetFpga.h:134
L1GctWheelJetFpga::m_outputHxPipe
Pipeline< htComponentType > m_outputHxPipe
Definition: L1GctWheelJetFpga.h:141
L1GctWheelJetFpga::hfTowerSumsType
L1GctJetLeafCard::hfTowerSumsType hfTowerSumsType
Definition: L1GctWheelJetFpga.h:33
L1GctUnsignedInt.h
L1GctWheelJetFpga::getForwardJets
JetVector getForwardJets() const
get the output jets
Definition: L1GctWheelJetFpga.h:76
L1GctWheelJetFpga::m_inputHy
std::vector< htComponentType > m_inputHy
Definition: L1GctWheelJetFpga.h:126
L1GctWheelJetFpga::classifyJets
void classifyJets()
Classifies jets into central, forward or tau.
Definition: L1GctWheelJetFpga.cc:242
L1GctWheelJetFpga::process
void process() override
process the data, fill output buffers
Definition: L1GctWheelJetFpga.cc:180
L1GctWheelJetFpga::resetPipelines
void resetPipelines() override
Definition: L1GctWheelJetFpga.cc:154
l1GtPatternGenerator_cfi.bx
bx
Definition: l1GtPatternGenerator_cfi.py:18
L1GctWheelJetFpga::m_forwardJets
JetVector m_forwardJets
Definition: L1GctWheelJetFpga.h:133
L1GctWheelJetFpga::m_outputHy
htComponentType m_outputHy
Definition: L1GctWheelJetFpga.h:138
L1GctWheelJetFpga::setupObjects
void setupObjects() override
Initialise inputs with null objects for the correct bunch crossing if required.
Definition: L1GctWheelJetFpga.cc:152
L1GctWheelJetFpga::getTauJets
JetVector getTauJets() const
get the output jets
Definition: L1GctWheelJetFpga.h:79
singleTopDQM_cfi.jets
jets
Definition: singleTopDQM_cfi.py:42
L1GctWheelJetFpga::getInternalHtMiss
std::vector< L1GctInternHtMiss > getInternalHtMiss() const
get the Et sums in internal component format
Definition: L1GctWheelJetFpga.cc:223
L1GctWheelJetFpga::MAX_LEAF_CARDS
static const unsigned int MAX_LEAF_CARDS
Max number of leaf card pointers.
Definition: L1GctWheelJetFpga.h:39
L1GctWheelJetFpga::resetProcessor
void resetProcessor() override
Separate reset methods for the processor itself and any data stored in pipelines.
Definition: L1GctWheelJetFpga.cc:141
L1GctWheelJetFpga::m_centralJetSorter
L1GctJetSorter * m_centralJetSorter
Jet sorters.
Definition: L1GctWheelJetFpga.h:112
L1GctWheelJetFpga::m_inputHx
std::vector< htComponentType > m_inputHx
Definition: L1GctWheelJetFpga.h:125
L1GctWheelJetFpga::getInputJets
JetVector getInputJets() const
get the input jets. Jets 0-5 from leaf card 0, jetfinderA. Jets 6-11 from leaf card 0,...
Definition: L1GctWheelJetFpga.h:63
L1GctWheelJetFpga::inputHy
htComponentType inputHy(unsigned leafnum) const
Definition: L1GctWheelJetFpga.h:67
L1GctJetCand.h
L1GctWheelJetFpga::m_inputJets
JetVector m_inputJets
input data. Jets 0-5 from leaf card 0, jetfinderA. Jets 6-11 from leaf card 0, jetfinder B....
Definition: L1GctWheelJetFpga.h:117
L1GctWheelJetFpga::htComponentType
L1GctTwosComplement< L1GctInternHtMiss::kMissHxOrHyNBits > htComponentType
Definition: L1GctWheelJetFpga.h:32
L1GctWheelJetFpga::storeJets
void storeJets(const JetVector &jets, unsigned short iLeaf, unsigned short offset)
Puts the output from a jetfinder into the correct index range of the m_inputJets array.
Definition: L1GctWheelJetFpga.cc:236
L1GctWheelJetFpga::fetchInput
void fetchInput() override
get input data from sources
Definition: L1GctWheelJetFpga.cc:159
L1GctWheelJetFpga::m_inputHfSums
std::vector< hfTowerSumsType > m_inputHfSums
Definition: L1GctWheelJetFpga.h:129
L1GctTwosComplement< L1GctInternHtMiss::kMissHxOrHyNBits >
L1GctWheelJetFpga::JetVector
std::vector< L1GctJetCand > JetVector
Definition: L1GctWheelJetFpga.h:31
L1GctWheelJetFpga::inputHfSums
hfTowerSumsType inputHfSums(unsigned leafnum) const
get the input Hf Sums
Definition: L1GctWheelJetFpga.h:70
L1GctWheelJetFpga::checkSetup
bool checkSetup() const
Check the setup, independently of how we have been constructed.
Definition: L1GctWheelJetFpga.cc:48
L1GctWheelJetFpga::m_outputHyPipe
Pipeline< htComponentType > m_outputHyPipe
Definition: L1GctWheelJetFpga.h:142
L1GctWheelJetFpga::getOutputHfSums
hfTowerSumsType getOutputHfSums() const
get the output Hf Sums
Definition: L1GctWheelJetFpga.h:86
L1GctWheelJetFpga::setupOk
bool setupOk() const
Public access to setup check.
Definition: L1GctWheelJetFpga.h:89
L1GctWheelJetFpga::m_id
int m_id
algo ID
Definition: L1GctWheelJetFpga.h:106
L1GctWheelJetFpga::MAX_JETS_IN
static const int MAX_JETS_IN
Maximum number of jets we can have as input.
Definition: L1GctWheelJetFpga.h:103
L1GctJetSorter
Definition: L1GctJetSorter.h:8
L1GctEtHad.h
L1GctWheelJetFpga::MAX_JETS_OUT
static const int MAX_JETS_OUT
Max number of jets of each type we output.
Definition: L1GctWheelJetFpga.h:36
L1GctWheelJetFpga::m_rawForwardJets
JetVector m_rawForwardJets
Definition: L1GctWheelJetFpga.h:121
L1GctWheelJetFpga::operator<<
friend std::ostream & operator<<(std::ostream &os, const L1GctWheelJetFpga &fpga)
Overload << operator.
Definition: L1GctWheelJetFpga.cc:94
L1GctWheelJetFpga
Represents a GCT Wheel Jet FPGA.
Definition: L1GctWheelJetFpga.h:29
L1GctWheelJetFpga::setInputJet
void setInputJet(int i, const L1GctJetCand &jet)
set input data
Definition: L1GctWheelJetFpga.cc:210
L1GctWheelJetFpga::m_outputHx
htComponentType m_outputHx
Definition: L1GctWheelJetFpga.h:137
L1GctWheelJetFpga::m_inputLeafCards
std::vector< L1GctJetLeafCard * > m_inputLeafCards
the jet leaf cards
Definition: L1GctWheelJetFpga.h:109
metsig::jet
Definition: SignAlgoResolutions.h:47
L1GctWheelJetFpga::getOutputHx
htComponentType getOutputHx() const
get the output Ht components
Definition: L1GctWheelJetFpga.h:82
L1GctWheelJetFpga::getOutputHy
htComponentType getOutputHy() const
Definition: L1GctWheelJetFpga.h:83
L1GctJetFinderBase::hfTowerSumsType
Definition: L1GctJetFinderBase.h:73
L1GctWheelJetFpga::m_rawCentralJets
JetVector m_rawCentralJets
Definition: L1GctWheelJetFpga.h:120
L1GctJetLeafCard.h
L1GctWheelJetFpga::~L1GctWheelJetFpga
~L1GctWheelJetFpga() override
destructor
Definition: L1GctWheelJetFpga.cc:85
L1GctWheelJetFpga::L1GctWheelJetFpga
L1GctWheelJetFpga(int id, const std::vector< L1GctJetLeafCard * > &inputLeafCards)
id must be 0 / 1 for -ve/+ve eta halves of CMS
Definition: L1GctWheelJetFpga.cc:16
L1GctProcessor.h
L1GctWheelJetFpga::m_centralJets
JetVector m_centralJets
Definition: L1GctWheelJetFpga.h:132
L1GctWheelJetFpga::m_tauJetSorter
L1GctJetSorter * m_tauJetSorter
Definition: L1GctWheelJetFpga.h:114
L1GctProcessor
ABC for a GCT trigger data processing unit.
Definition: L1GctProcessor.h:22
L1GctWheelJetFpga::setupJetsVectors
void setupJetsVectors(const int16_t bx)
Initialises all the jet vectors with jets of the correct type.
Definition: L1GctWheelJetFpga.cc:275
hltrates_dqm_sourceclient-live_cfg.offset
offset
Definition: hltrates_dqm_sourceclient-live_cfg.py:82
L1GctWheelJetFpga::MAX_JETS_PER_LEAF
static const unsigned int MAX_JETS_PER_LEAF
Max number of jets input from each leaf card.
Definition: L1GctWheelJetFpga.h:42
operator<<
std::ostream & operator<<(std::ostream &os, const L1GctWheelJetFpga &fpga)
Definition: L1GctWheelJetFpga.cc:94