|
|
#include <L1RCT.h>
|
void | digiInput (const EcalTrigPrimDigiCollection &ecalCollection, const HcalTrigPrimDigiCollection &hcalCollection) |
|
unsigned short | ecalCompressedET (int crate, int card, int tower) |
|
unsigned short | ecalFineGrainBit (int crate, int card, int tower) |
|
void | fileInput (const char *filename) |
|
L1CaloEmCollection | getIsolatedEGObjects (unsigned crate) |
|
std::vector< unsigned short > | getJetRegions (unsigned crate) |
|
L1CaloEmCollection | getNonisolatedEGObjects (unsigned crate) |
|
std::vector< L1CaloRegion > | getRegions (unsigned crate) |
|
unsigned short | hcalCompressedET (int crate, int card, int tower) |
|
unsigned short | hcalFineGrainBit (int crate, int card, int tower) |
|
unsigned short | hfCompressedET (int crate, int tower) |
|
unsigned short | hfFineGrainBit (int crate, int tower) |
|
void | input () |
|
void | input (const std::vector< std::vector< std::vector< unsigned short >>> &barrelIn, const std::vector< std::vector< unsigned short >> &hfIn) |
|
| L1RCT (const L1RCTLookupTables *rctLookupTables) |
|
void | print () |
|
void | printCrate (int i) |
|
void | printEIC (int i, int j) |
|
void | printEICEdges (int i, int j) |
|
void | printJSC () |
|
void | printJSC (int i) |
|
void | printRC (int i, int j) |
|
void | processEvent () |
|
void | randomInput () |
|
Definition at line 20 of file L1RCT.h.
◆ L1RCT() [1/2]
◆ L1RCT() [2/2]
◆ configureCards()
void L1RCT::configureCards |
( |
| ) |
|
|
private |
◆ digiInput()
Definition at line 109 of file L1RCT.cc.
112 for (
int i = 0;
i < 18;
i++) {
113 for (
int j = 0;
j < 7;
j++) {
114 for (
int k = 0;
k < 64;
k++) {
118 for (
int j = 0;
j < 8;
j++) {
123 int nEcalDigi = ecalCollection.
size();
124 if (nEcalDigi > 4032) {
127 for (
int i = 0;
i < nEcalDigi;
i++) {
128 short ieta = (short)ecalCollection[
i].
id().ieta();
130 unsigned short absIeta = (
unsigned short)
abs(
ieta);
131 unsigned short cal_iphi = (
unsigned short)ecalCollection[
i].
id().iphi();
132 unsigned short iphi = (72 + 18 - cal_iphi) % 72;
136 unsigned short crate = 999, card = 999,
tower = 999;
141 unsigned short energy = ecalCollection[
i].compressedEt();
142 unsigned short fineGrain = (
unsigned short)ecalCollection[
i].fineGrain();
143 unsigned short ecalInput =
energy * 2 + fineGrain;
146 if ((crate < 18) && (card < 7) && (
tower < 32)) {
149 std::cerr <<
"L1RCT: ecal out of range! tower = " <<
tower <<
" iphi is " <<
iphi <<
" absieta is " << absIeta
156 int nHcalDigi = hcalCollection.
size();
160 for (
int i = 0;
i < nHcalDigi;
i++) {
161 if (hcalCollection[
i].
id().
version() != 0) {
164 short ieta = (short)hcalCollection[
i].
id().ieta();
165 unsigned short absIeta = (
unsigned short)
abs(
ieta);
166 unsigned short cal_iphi = (
unsigned short)hcalCollection[
i].
id().iphi();
169 unsigned short iphi = (72 + 18 - cal_iphi) % 72;
178 unsigned short crate = 999, card = 999,
tower = 999;
185 unsigned short energy = hcalCollection[
i].SOI_compressedEt();
186 unsigned short fineGrain = (
unsigned short)hcalCollection[
i].SOI_fineGrain();
187 unsigned short hcalInput =
energy * 2 + fineGrain;
190 if ((crate < 18) && (card < 7) && (
tower < 32)) {
191 barrel.at(crate).at(card).at(
tower + 32) = hcalInput;
193 std::cout <<
"L1RCT: hcal out of range! tower = " <<
tower << std::endl;
195 }
else if ((absIeta >= 29) && (absIeta <= 32)) {
197 if ((crate < 18) && (
tower < 8)) {
198 hf.at(crate).at(
tower) = hcalInput;
200 std::cout <<
"L1RCT: hf out of range! region = " <<
tower << std::endl;
References funct::abs(), barrel, L1RCTParameters::calcCard(), L1RCTParameters::calcCrate(), L1RCTParameters::calcTower(), EcnaPython_AdcPeg12_S1_10_R170298_1_0_150_Dee0::cerr, gather_cfg::cout, HCALHighEnergyHPDFilter_cfi::energy, hf, mps_fire::i, LEDCalibrationChannels::ieta, input(), LEDCalibrationChannels::iphi, dqmiolumiharvest::j, dqmdumpme::k, rctLookupTables_, L1RCTLookupTables::rctParameters(), edm::SortedCollection< T, SORT >::size(), hgcalTowerProducer_cfi::tower, and BeamSplash_cfg::version.
Referenced by L1RCTSaveInput::analyze(), and L1RCTInputProducer::produce().
◆ ecalCompressedET()
unsigned short L1RCT::ecalCompressedET |
( |
int |
crate, |
|
|
int |
card, |
|
|
int |
tower |
|
) |
| |
|
inline |
◆ ecalFineGrainBit()
unsigned short L1RCT::ecalFineGrainBit |
( |
int |
crate, |
|
|
int |
card, |
|
|
int |
tower |
|
) |
| |
|
inline |
◆ fileInput()
void L1RCT::fileInput |
( |
const char * |
filename | ) |
|
◆ getIsolatedEGObjects()
◆ getJetRegions()
std::vector<unsigned short> L1RCT::getJetRegions |
( |
unsigned |
crate | ) |
|
|
inline |
Definition at line 59 of file L1RCT.h.
59 {
return crates.at(crate).getJetRegions(); }
References crates.
◆ getNonisolatedEGObjects()
◆ getRegions()
Definition at line 359 of file L1RCT.cc.
361 std::bitset<14>
taus((
long)
crates.at(crate).getTauBits());
362 std::bitset<14> mips((
long)
crates.at(crate).getMIPBits());
363 std::bitset<14> quiets((
long)
crates.at(crate).getQuietBits());
364 std::bitset<14> overflows((
long)
crates.at(crate).getOverFlowBits());
365 std::vector<unsigned short> barrelEnergies =
crates.at(crate).getBarrelRegions();
366 std::vector<L1CaloRegion> regionCollection;
367 for (
unsigned card = 0; card < 7; card++) {
368 for (
unsigned rgn = 0; rgn < 2; rgn++) {
369 bool tau =
taus[card * 2 + rgn];
370 bool mip = mips[card * 2 + rgn];
371 bool quiet = quiets[card * 2 + rgn];
372 bool overflow = overflows[card * 2 + rgn];
373 unsigned barrelEnergy = barrelEnergies.at(card * 2 + rgn);
375 regionCollection.push_back(
region);
380 std::vector<unsigned short> hfEnergies =
crates.at(crate).getHFRegions();
382 std::vector<unsigned short> hfFineGrainBits =
crates.at(crate).getHFFineGrainBits();
383 for (
unsigned hfRgn = 0; hfRgn < 8; hfRgn++) {
385 unsigned energy = hfEnergies.at(hfRgn);
386 bool fineGrain = hfFineGrainBits.at(hfRgn);
388 regionCollection.push_back(hfRegion);
390 return regionCollection;
References crates, HCALHighEnergyHPDFilter_cfi::energy, HLT_FULL_cff::region, metsig::tau, and Tau3MuMonitor_cff::taus.
◆ hcalCompressedET()
unsigned short L1RCT::hcalCompressedET |
( |
int |
crate, |
|
|
int |
card, |
|
|
int |
tower |
|
) |
| |
|
inline |
◆ hcalFineGrainBit()
unsigned short L1RCT::hcalFineGrainBit |
( |
int |
crate, |
|
|
int |
card, |
|
|
int |
tower |
|
) |
| |
|
inline |
◆ hfCompressedET()
unsigned short L1RCT::hfCompressedET |
( |
int |
crate, |
|
|
int |
tower |
|
) |
| |
|
inline |
◆ hfFineGrainBit()
unsigned short L1RCT::hfFineGrainBit |
( |
int |
crate, |
|
|
int |
tower |
|
) |
| |
|
inline |
◆ input() [1/2]
◆ input() [2/2]
void L1RCT::input |
( |
const std::vector< std::vector< std::vector< unsigned short >>> & |
barrelIn, |
|
|
const std::vector< std::vector< unsigned short >> & |
hfIn |
|
) |
| |
◆ makeCrates()
void L1RCT::makeCrates |
( |
| ) |
|
|
private |
◆ print()
void L1RCT::print |
( |
void |
| ) |
|
◆ printCrate()
void L1RCT::printCrate |
( |
int |
i | ) |
|
|
inline |
◆ printEIC()
void L1RCT::printEIC |
( |
int |
i, |
|
|
int |
j |
|
) |
| |
|
inline |
◆ printEICEdges()
void L1RCT::printEICEdges |
( |
int |
i, |
|
|
int |
j |
|
) |
| |
|
inline |
◆ printJSC() [1/2]
◆ printJSC() [2/2]
void L1RCT::printJSC |
( |
int |
i | ) |
|
|
inline |
◆ printRC()
void L1RCT::printRC |
( |
int |
i, |
|
|
int |
j |
|
) |
| |
|
inline |
◆ processEvent()
void L1RCT::processEvent |
( |
| ) |
|
◆ randomInput()
void L1RCT::randomInput |
( |
| ) |
|
◆ shareNeighbors()
void L1RCT::shareNeighbors |
( |
| ) |
|
|
private |
Definition at line 233 of file L1RCT.cc.
244 for (
int i = 0;
i < 18;
i++) {
245 for (
int j = 0;
j < 7;
j++) {
246 for (
int k = 0;
k < 2;
k++) {
247 primary =
crates.at(
i).getReceiverCard(
j)->getRegion(
k);
250 if (northIndices.at(0) != -1)
251 north =
crates.at(northIndices.at(0)).getReceiverCard(northIndices.at(1))->getRegion(northIndices.at(2));
256 if (southIndices.at(0) != -1)
257 south =
crates.at(southIndices.at(0)).getReceiverCard(southIndices.at(1))->getRegion(southIndices.at(2));
262 if (westIndices.at(0) != -1)
263 west =
crates.at(westIndices.at(0)).getReceiverCard(westIndices.at(1))->getRegion(westIndices.at(2));
268 if (eastIndices.at(0) != -1)
269 east =
crates.at(eastIndices.at(0)).getReceiverCard(eastIndices.at(1))->getRegion(eastIndices.at(2));
274 if (seIndices.at(0) != -1)
275 se =
crates.at(seIndices.at(0)).getReceiverCard(seIndices.at(1))->getRegion(seIndices.at(2));
280 if (swIndices.at(0) != -1)
281 sw =
crates.at(swIndices.at(0)).getReceiverCard(swIndices.at(1))->getRegion(swIndices.at(2));
286 if (neIndices.at(0) != -1)
287 ne =
crates.at(neIndices.at(0)).getReceiverCard(neIndices.at(1))->getRegion(neIndices.at(2));
292 if (nwIndices.at(0) != -1)
293 nw =
crates.at(nwIndices.at(0)).getReceiverCard(nwIndices.at(1))->getRegion(nwIndices.at(2));
References crates, L1RCTNeighborMap::east(), east, empty, L1RCTRegion::giveNEEt(), L1RCTRegion::giveNEHE_FG(), L1RCTRegion::giveNWEt(), L1RCTRegion::giveNWHE_FG(), L1RCTRegion::giveSEEt(), L1RCTRegion::giveSEHE_FG(), L1RCTRegion::giveSWEt(), L1RCTRegion::giveSWHE_FG(), mps_fire::i, dqmiolumiharvest::j, dqmdumpme::k, L1RCTNeighborMap::ne(), neighborMap, L1RCTNeighborMap::north(), north, L1RCTNeighborMap::nw(), L1RCTNeighborMap::se(), L1RCTRegion::setEastEt(), L1RCTRegion::setEastHE_FG(), L1RCTRegion::setNEEt(), L1RCTRegion::setNEHE_FG(), L1RCTRegion::setNorthEt(), L1RCTRegion::setNorthHE_FG(), L1RCTRegion::setNWEt(), L1RCTRegion::setNWHE_FG(), L1RCTRegion::setSEEt(), L1RCTRegion::setSEHE_FG(), L1RCTRegion::setSouthEt(), L1RCTRegion::setSouthHE_FG(), L1RCTRegion::setSWEt(), L1RCTRegion::setSWHE_FG(), L1RCTRegion::setWestEt(), L1RCTRegion::setWestHE_FG(), L1RCTNeighborMap::south(), south, L1RCTNeighborMap::sw(), L1RCTNeighborMap::west(), and west.
Referenced by processEvent().
◆ barrel
std::vector<std::vector<std::vector<unsigned short> > > L1RCT::barrel |
|
private |
◆ crates
Definition at line 101 of file L1RCT.h.
Referenced by getIsolatedEGObjects(), getJetRegions(), getNonisolatedEGObjects(), getRegions(), input(), makeCrates(), print(), printCrate(), printEIC(), printEICEdges(), printJSC(), printRC(), processEvent(), and shareNeighbors().
◆ empty
◆ hf
std::vector<std::vector<unsigned short> > L1RCT::hf |
|
private |
◆ neighborMap
◆ rctLookupTables_
const L1RCTLookupTables * rctLookupTables_
std::vector< std::vector< unsigned short > > hf
std::vector< int > sw(int crate, int card, int region)
A calorimeter trigger region (sum of 4x4 trigger towers)
unsigned short giveSWEt() const
std::vector< std::vector< std::vector< unsigned short > > > barrel
void setNWHE_FG(unsigned short nw)
unsigned short giveNEHE_FG() const
void setWestHE_FG(const std::vector< unsigned short > &west)
void setSEEt(unsigned short se)
void setNorthHE_FG(const std::vector< unsigned short > &north)
std::vector< int > nw(int crate, int card, int region)
unsigned short giveSEHE_FG() const
std::vector< int > west(int crate, int card, int region)
std::vector< L1CaloEmCand > L1CaloEmCollection
std::vector< int > north(int crate, int card, int region)
std::vector< L1RCTCrate > crates
std::vector< int > ne(int crate, int card, int region)
unsigned short calcCrate(unsigned short rct_iphi, short ieta) const
std::vector< int > east(int crate, int card, int region)
unsigned short giveNWHE_FG() const
unsigned short calcCard(unsigned short rct_iphi, unsigned short absIeta) const
void setSouthHE_FG(const std::vector< unsigned short > &south)
void setWestEt(const std::vector< unsigned short > &west)
std::vector< int > se(int crate, int card, int region)
unsigned short giveNEEt() const
L1RCTNeighborMap neighborMap
const L1RCTParameters * rctParameters() const
unsigned short giveSWHE_FG() const
void setSWEt(unsigned short sw)
void setNorthEt(const std::vector< unsigned short > &north)
unsigned short calcTower(unsigned short rct_iphi, unsigned short absIeta) const
std::vector< int > south(int crate, int card, int region)
unsigned short giveNWEt() const
void setEastHE_FG(const std::vector< unsigned short > &east)
void setSEHE_FG(unsigned short se)
void setNEEt(unsigned short ne)
Abs< T >::type abs(const T &t)
unsigned short giveSEEt() const
void setSouthEt(const std::vector< unsigned short > &south)
Level-1 Region Calorimeter Trigger EM candidate.
void setEastEt(const std::vector< unsigned short > &east)
void setNEHE_FG(unsigned short ne)
void setNWEt(unsigned short nw)
unsigned int emRank(unsigned short energy) const
void setSWHE_FG(unsigned short sw)