CMS 3D CMS Logo

L1RCTCrate.h
Go to the documentation of this file.
1 #ifndef L1RCTCrate_h
2 #define L1RCTCrate_h
3 
7 #include <vector>
8 
10 
11 class L1RCTCrate {
12 public:
13  L1RCTCrate(int crtNo, const L1RCTLookupTables *rctLookupTables);
14 
15  ~L1RCTCrate();
16 
17  int crateNumber() { return crtNo; }
18 
19  // For sharing information between crates.
20  // It passes the pointers to the cards rather than the copies of the cards
21  // because we need to modify the actual regions when setting their
22  // neighbors rather than just copies.
23  // Working in non garbage collected languages can really suck sometimes.
25  // L1RCTJetSummaryCard* getJetSummaryCard { return &jetSummaryCard;}
26 
27  // This method receives the input from the L1RCT class and distributes
28  // the RCInput to the 7 receiver cards and sends the HFInput straight
29  // to the JSC for this crate. The RCs never see the HF data. Instead
30  // the JSC acts like a primitive RC for these regions.
31  void input(const std::vector<std::vector<unsigned short>> &RCInput, const std::vector<unsigned short> &HFInput);
32  // The two following are methods for running the actual data processing
33  // in the RCs and the EICs. They're to be called for each card
34  // from the L1RCT process method
35  void processReceiverCards();
38  // Pulls the information from the RCs and EICs and sends it to the
39  // JSC.
40  void fillJetSummaryCard();
41  void processJetSummaryCard();
42  void print();
44  void printRC(int i) { receiverCards.at(i).print(); }
45  void printEIC(int i) { electronCards.at(i).print(); }
46  void printEICEdges(int i) { electronCards.at(i).printEdges(); }
47 
48  // region sums
49  std::vector<unsigned short> getJetRegions() { return jetSummaryCard.getJetRegions(); }
50  std::vector<unsigned short> getBarrelRegions() { return jetSummaryCard.getBarrelRegions(); }
51  std::vector<unsigned short> getHFRegions() { return jetSummaryCard.getHFRegions(); }
52 
53  // e-gamma objects
54  std::vector<unsigned short> getIsolatedEGObjects() { return jetSummaryCard.getIsolatedEGObjects(); }
55  std::vector<unsigned short> getNonisolatedEGObjects() { return jetSummaryCard.getNonisolatedEGObjects(); }
56 
57  // the bits
58  unsigned short getTauBits() { return jetSummaryCard.getTauBits(); }
59  unsigned short getMIPBits() { return jetSummaryCard.getMIPBits(); }
60  unsigned short getOverFlowBits() { return jetSummaryCard.getOverFlowBits(); }
61  unsigned short getQuietBits() { return jetSummaryCard.getQuietBits(); }
62  // hf bit
63  std::vector<unsigned short> getHFFineGrainBits() { return jetSummaryCard.getHFFineGrainBits(); }
64 
65 private:
66  // The seven RCs and EICs
67  // They are laid out according to CMS IN 2004/008
68  // Increasing number towards higher absolute eta
69  // The seventh card is always sideways with respect to the
70  // other six.
71  std::vector<L1RCTReceiverCard> receiverCards;
72  std::vector<L1RCTElectronIsolationCard> electronCards;
73  // The JSC receives the jet and electron information from the
74  // RCs and EICs. There is only one per crate.
76 
77  int crtNo;
79 
80  L1RCTCrate() = delete;
81 
82  // L1RCTJetCaptureCard jetCaptureCard;
83 };
84 #endif // L1RCTCrate_h
L1RCTCrate::input
void input(const std::vector< std::vector< unsigned short >> &RCInput, const std::vector< unsigned short > &HFInput)
Definition: L1RCTCrate.cc:16
L1RCTCrate::crtNo
int crtNo
Definition: L1RCTCrate.h:77
L1RCTCrate::print
void print()
Definition: L1RCTCrate.cc:79
mps_fire.i
i
Definition: mps_fire.py:428
L1RCTCrate
Definition: L1RCTCrate.h:11
L1RCTCrate::getIsolatedEGObjects
std::vector< unsigned short > getIsolatedEGObjects()
Definition: L1RCTCrate.h:54
L1RCTCrate::~L1RCTCrate
~L1RCTCrate()
Definition: L1RCTCrate.cc:14
L1RCTJetSummaryCard::getMIPBits
unsigned short getMIPBits()
Definition: L1RCTJetSummaryCard.h:64
L1RCTJetSummaryCard::getBarrelRegions
std::vector< unsigned short > getBarrelRegions()
Definition: L1RCTJetSummaryCard.h:52
L1RCTReceiverCard
Definition: L1RCTReceiverCard.h:14
L1RCTCrate::getReceiverCard
L1RCTReceiverCard * getReceiverCard(int i)
Definition: L1RCTCrate.h:24
L1RCTCrate::printRC
void printRC(int i)
Definition: L1RCTCrate.h:44
L1RCTCrate::getJetRegions
std::vector< unsigned short > getJetRegions()
Definition: L1RCTCrate.h:49
L1RCTCrate::electronCards
std::vector< L1RCTElectronIsolationCard > electronCards
Definition: L1RCTCrate.h:72
L1RCTCrate::rctLookupTables_
const L1RCTLookupTables * rctLookupTables_
Definition: L1RCTCrate.h:78
L1RCTCrate::getOverFlowBits
unsigned short getOverFlowBits()
Definition: L1RCTCrate.h:60
L1RCTJetSummaryCard::getHFRegions
std::vector< unsigned short > getHFRegions()
Definition: L1RCTJetSummaryCard.h:53
L1RCTCrate::fillElectronIsolationCards
void fillElectronIsolationCards()
Definition: L1RCTCrate.cc:35
L1RCTCrate::getMIPBits
unsigned short getMIPBits()
Definition: L1RCTCrate.h:59
L1RCTCrate::getHFRegions
std::vector< unsigned short > getHFRegions()
Definition: L1RCTCrate.h:51
L1RCTJetSummaryCard
Definition: L1RCTJetSummaryCard.h:8
L1RCTCrate::printJSC
void printJSC()
Definition: L1RCTCrate.h:43
L1RCTCrate::receiverCards
std::vector< L1RCTReceiverCard > receiverCards
Definition: L1RCTCrate.h:71
L1RCTCrate::crateNumber
int crateNumber()
Definition: L1RCTCrate.h:17
L1RCTCrate::printEIC
void printEIC(int i)
Definition: L1RCTCrate.h:45
L1RCTLookupTables
Definition: L1RCTLookupTables.h:11
L1RCTCrate::getQuietBits
unsigned short getQuietBits()
Definition: L1RCTCrate.h:61
L1RCTCrate::getBarrelRegions
std::vector< unsigned short > getBarrelRegions()
Definition: L1RCTCrate.h:50
L1RCTJetSummaryCard::getJetRegions
std::vector< unsigned short > getJetRegions()
Definition: L1RCTJetSummaryCard.h:51
L1RCTCrate::processJetSummaryCard
void processJetSummaryCard()
Definition: L1RCTCrate.cc:74
trackerHitRTTI::vector
Definition: trackerHitRTTI.h:21
L1RCTJetSummaryCard::getOverFlowBits
unsigned short getOverFlowBits()
Definition: L1RCTJetSummaryCard.h:68
L1RCTCrate::getHFFineGrainBits
std::vector< unsigned short > getHFFineGrainBits()
Definition: L1RCTCrate.h:63
L1RCTJetSummaryCard.h
L1RCTJetSummaryCard::getQuietBits
unsigned short getQuietBits()
Definition: L1RCTJetSummaryCard.h:65
L1RCTJetSummaryCard::print
void print()
Definition: L1RCTJetSummaryCard.cc:273
L1RCTCrate::processElectronIsolationCards
void processElectronIsolationCards()
Definition: L1RCTCrate.cc:42
L1RCTReceiverCard.h
L1RCTJetSummaryCard::getHFFineGrainBits
std::vector< unsigned short > getHFFineGrainBits()
Definition: L1RCTJetSummaryCard.h:70
L1RCTCrate::L1RCTCrate
L1RCTCrate()=delete
L1RCTCrate::processReceiverCards
void processReceiverCards()
Definition: L1RCTCrate.cc:28
L1RCTCrate::jetSummaryCard
L1RCTJetSummaryCard jetSummaryCard
Definition: L1RCTCrate.h:75
L1RCTCrate::getNonisolatedEGObjects
std::vector< unsigned short > getNonisolatedEGObjects()
Definition: L1RCTCrate.h:55
L1RCTElectronIsolationCard.h
L1RCTJetSummaryCard::getIsolatedEGObjects
std::vector< unsigned short > getIsolatedEGObjects()
Definition: L1RCTJetSummaryCard.h:25
L1RCTCrate::fillJetSummaryCard
void fillJetSummaryCard()
Definition: L1RCTCrate.cc:46
L1RCTJetSummaryCard::getNonisolatedEGObjects
std::vector< unsigned short > getNonisolatedEGObjects()
Definition: L1RCTJetSummaryCard.h:26
L1RCTCrate::printEICEdges
void printEICEdges(int i)
Definition: L1RCTCrate.h:46
L1RCTCrate::getTauBits
unsigned short getTauBits()
Definition: L1RCTCrate.h:58
L1RCTJetSummaryCard::getTauBits
unsigned short getTauBits()
Definition: L1RCTJetSummaryCard.h:67