#include <CSCMotherboard.h>
Public Member Functions | |
void | clear () |
CSCMotherboard (unsigned endcap, unsigned station, unsigned sector, unsigned subsector, unsigned chamber, const edm::ParameterSet &conf) | |
virtual std::vector< CSCCorrelatedLCTDigi > | readoutLCTs () const |
std::vector< CSCShowerDigi > | readoutShower () const |
void | run (const CSCWireDigiCollection *wiredc, const CSCComparatorDigiCollection *compdc) |
void | selectLCTs () |
void | setConfigParameters (const CSCDBL1TPParameters *conf) |
void | setESLookupTables (const CSCL1TPLookupTableCCLUT *conf) |
void | setESLookupTables (const CSCL1TPLookupTableME11ILT *conf) |
void | setESLookupTables (const CSCL1TPLookupTableME21ILT *conf) |
~CSCMotherboard () override=default | |
Public Member Functions inherited from CSCBaseboard | |
CSCBaseboard (unsigned endcap, unsigned station, unsigned sector, unsigned subsector, unsigned chamber, const edm::ParameterSet &conf) | |
CSCBaseboard () | |
std::string | getCSCName () const |
CSCDetId | id () const |
void | setCSCGeometry (const CSCGeometry *g) |
virtual | ~CSCBaseboard ()=default |
Public Attributes | |
std::unique_ptr< CSCAnodeLCTProcessor > | alctProc |
std::unique_ptr< CSCCathodeLCTProcessor > | clctProc |
Protected Member Functions | |
void | checkConfigParameters () |
void | constructLCTs (const CSCALCTDigi &aLCT, const CSCCLCTDigi &cLCT, int type, int trknmb, CSCCorrelatedLCTDigi &lct) const |
void | copyValidToInValidALCT (CSCALCTDigi &, CSCALCTDigi &) const |
void | copyValidToInValidCLCT (CSCCLCTDigi &, CSCCLCTDigi &) const |
void | correlateLCTs (const CSCALCTDigi &bestALCT, const CSCALCTDigi &secondALCT, const CSCCLCTDigi &bestCLCT, const CSCCLCTDigi &secondCLCT, CSCCorrelatedLCTDigi &bLCT, CSCCorrelatedLCTDigi &sLCT, int type) const |
bool | doesALCTCrossCLCT (const CSCALCTDigi &, const CSCCLCTDigi &) const |
void | dumpConfigParams () const |
void | encodeHighMultiplicityBits () |
unsigned int | encodePattern (const int clctPattern) const |
CSCALCTDigi | getBXShiftedALCT (const CSCALCTDigi &) const |
CSCCLCTDigi | getBXShiftedCLCT (const CSCCLCTDigi &) const |
void | matchALCTCLCT () |
void | matchShowers (CSCShowerDigi *anode_showers, CSCShowerDigi *cathode_showers, bool andlogic) |
Protected Member Functions inherited from CSCBaseboard | |
void | checkConfigParameters (unsigned int &var, const unsigned int var_max, const unsigned int var_def, const std::string &var_str) |
Static Protected Attributes | |
static const unsigned int | def_alct_trig_enable = 0 |
static const unsigned int | def_clct_trig_enable = 0 |
static const unsigned int | def_match_trig_enable = 1 |
static const unsigned int | def_match_trig_window_size = 7 |
static const unsigned int | def_mpc_block_me1a = 1 |
static const unsigned int | def_tmb_l1a_window_size = 7 |
Correlates anode and cathode LCTs from the same chamber.
When the Trigger MotherBoard (TMB) is instantiated it instantiates an ALCT and CLCT board. The MotherBoard takes up to two LCTs from each anode and cathode LCT card and combines them into a single Correlated LCT. The output is up to two Correlated LCTs.
It can be run in either a test mode, where the arguments are a collection of wire times and arrays of halfstrip times, or for general use, with wire digi and comparator digi collections as arguments. In the latter mode, the wire & strip info is passed on the LCTProcessors, where it is decoded and converted into a convenient form. After running the anode and cathode LCTProcessors, TMB correlates the anode and cathode LCTs. At present, it simply matches the best CLCT with the best ALCT; perhaps a better algorithm will be determined in the future. The MotherBoard then determines a few more numbers (such as quality and pattern) from the ALCT and CLCT information, and constructs two correlated LCT "digis".
Based on code by Nick Wisniewski (nw@it) and a framework by Darin Acosta ( s.ca ltech .eduacost). a@ph ys.uf l.ed u
Numerous later improvements by Jason Mumford and Slava Valuev (see cvs in ORCA). Porting from ORCA by S. Valuev (Slava), May 2006. .Val uev@c ern. ch
Extended for Run-3 and Phase-2 by Vadim Khotilovich, Tao Huang, Sven Dildick and Giovanni Mocellin
Definition at line 50 of file CSCMotherboard.h.
CSCMotherboard::CSCMotherboard | ( | unsigned | endcap, |
unsigned | station, | ||
unsigned | sector, | ||
unsigned | subsector, | ||
unsigned | chamber, | ||
const edm::ParameterSet & | conf | ||
) |
Normal constructor.
Definition at line 13 of file CSCMotherboard.cc.
References alct_trig_enable, alctProc, allLCTs_, cms::cuda::assert(), relativeConstraints::chamber, checkConfigParameters(), clct_trig_enable, clctProc, cscOverlap_, drop_used_clcts, dumpConfigParams(), early_tbins, CSCBaseboard::enableAlctPhase2_, makeMuonMisalignmentScenario::endcap, edm::ParameterSet::getParameter(), CSCDetId::iChamberType(), ignoreAlctCrossClct_, CSCBaseboard::infoV, CSCConstants::LCT_CENTRAL_BX, match_earliest_clct_only_, match_trig_enable, match_trig_window_size, maxbx_readout_, minbx_readout_, mpc_block_me1a, preferred_bx_match_, qualityAssignment_, qualityControl_, readout_earliest_2, CSCBaseboard::runPhase2_, LCTContainer::setMatchTrigWindowSize(), CSCBaseboard::showerParams_, showerSource_, relativeConstraints::station, CSCBaseboard::theRing, CSCBaseboard::theStation, thisShowerSource_, tmb_l1a_window_size, and CSCBaseboard::tmbParams_.
|
overridedefault |
Default destructor.
|
protected |
Make sure that the parameter values are within the allowed range.
Definition at line 558 of file CSCMotherboard.cc.
References alct_trig_enable, cms::cuda::assert(), CSCBaseboard::checkConfigParameters(), clct_trig_enable, def_alct_trig_enable, def_clct_trig_enable, def_match_trig_enable, def_match_trig_window_size, def_mpc_block_me1a, def_tmb_l1a_window_size, CSCConstants::LCT_CENTRAL_BX, match_trig_enable, match_trig_window_size, mpc_block_me1a, and tmb_l1a_window_size.
Referenced by CSCMotherboard(), and setConfigParameters().
void CSCMotherboard::clear | ( | void | ) |
Clears correlated LCT and passes clear signal on to cathode and anode LCT processors.
Definition at line 92 of file CSCMotherboard.cc.
References alctProc, alctV, allLCTs_, simKBmtfDigis_cfi::bx, clctProc, clctV, CSCShowerDigi::clear(), LCTContainer::clear(), lctV, CSCConstants::MAX_LCT_TBINS, and showers_.
Referenced by CSCGEMMotherboard::clear(), and run().
|
protected |
Definition at line 488 of file CSCMotherboard.cc.
References simKBmtfDigis_cfi::bx, encodePattern(), CSCCLCTDigi::getBend(), CSCALCTDigi::getBX(), CSCCLCTDigi::getBX(), getBXShiftedALCT(), getBXShiftedCLCT(), CSCCLCTDigi::getEighthStripBit(), CSCCLCTDigi::getKeyStrip(), CSCALCTDigi::getKeyWG(), CSCCLCTDigi::getPattern(), CSCCLCTDigi::getQuartStripBit(), CSCCLCTDigi::getRun3Pattern(), CSCCLCTDigi::getSlope(), CSCALCTDigi::isValid(), qualityAssignment_, CSCBaseboard::runCCLUT_, CSCCorrelatedLCTDigi::setALCT(), CSCCorrelatedLCTDigi::setBend(), CSCCorrelatedLCTDigi::setBX(), CSCCorrelatedLCTDigi::setBX0(), CSCCorrelatedLCTDigi::setCLCT(), CSCCorrelatedLCTDigi::setCSCID(), CSCCorrelatedLCTDigi::setEighthStripBit(), CSCCorrelatedLCTDigi::setMPCLink(), CSCCorrelatedLCTDigi::setPattern(), CSCCorrelatedLCTDigi::setQuality(), CSCCorrelatedLCTDigi::setQuartStripBit(), CSCCorrelatedLCTDigi::setRun3(), CSCCorrelatedLCTDigi::setRun3Pattern(), CSCCorrelatedLCTDigi::setSlope(), CSCCorrelatedLCTDigi::setStrip(), CSCCorrelatedLCTDigi::setSyncErr(), CSCCorrelatedLCTDigi::setTrknmb(), CSCCorrelatedLCTDigi::setType(), CSCCorrelatedLCTDigi::setValid(), CSCCorrelatedLCTDigi::setWireGroup(), and CSCBaseboard::theTrigChamber.
Referenced by correlateLCTs().
|
protected |
Definition at line 468 of file CSCMotherboard.cc.
References CSCALCTDigi::isValid().
Referenced by correlateLCTs().
|
protected |
Definition at line 474 of file CSCMotherboard.cc.
References CSCCLCTDigi::isValid().
Referenced by correlateLCTs().
|
protected |
Definition at line 398 of file CSCMotherboard.cc.
References alct_trig_enable, clct_trig_enable, CSCCLCTDigi::clear(), constructLCTs(), copyValidToInValidALCT(), copyValidToInValidCLCT(), doesALCTCrossCLCT(), CSCCLCTDigi::getQuality(), CSCALCTDigi::isValid(), CSCCLCTDigi::isValid(), match_trig_enable, and or.
Referenced by matchALCTCLCT().
|
protected |
Definition at line 479 of file CSCMotherboard.cc.
References cscOverlap_, and ignoreAlctCrossClct_.
Referenced by correlateLCTs(), and CSCGEMMotherboard::correlateLCTsGEM().
|
protected |
Dump TMB/MPC configuration parameters.
Definition at line 582 of file CSCMotherboard.cc.
References alct_trig_enable, clct_trig_enable, LogDebug, match_trig_enable, match_trig_window_size, mpc_block_me1a, and tmb_l1a_window_size.
Referenced by CSCMotherboard(), and setConfigParameters().
|
protected |
Definition at line 659 of file CSCMotherboard.cc.
References alctProc, clctProc, filterCSVwithJSON::copy, matchShowers(), CSCConstants::MAX_ALCT_TBINS, CSCConstants::MAX_CLCT_TBINS, showers_, and thisShowerSource_.
Referenced by CSCGEMMotherboard::run(), and run().
|
protected |
Definition at line 519 of file CSCMotherboard.cc.
References funct::abs(), and topSingleLeptonDQM_PU_cfi::pattern.
Referenced by constructLCTs(), and CSCGEMMotherboard::constructLCTsGEM().
|
protected |
Definition at line 598 of file CSCMotherboard.cc.
References CSCConstants::ALCT_CENTRAL_BX, CSCALCTDigi::getBX(), CSCConstants::LCT_CENTRAL_BX, and CSCALCTDigi::setBX().
Referenced by constructLCTs(), and CSCGEMMotherboard::constructLCTsGEM().
|
protected |
Definition at line 604 of file CSCMotherboard.cc.
References CSCConstants::ALCT_CLCT_OFFSET, CSCCLCTDigi::getBX(), and CSCCLCTDigi::setBX().
Referenced by constructLCTs(), and CSCGEMMotherboard::constructLCTsGEM().
|
protected |
Definition at line 180 of file CSCMotherboard.cc.
References CSCConstants::ALCT_CLCT_OFFSET, alct_trig_enable, CSCCorrelatedLCTDigi::ALCTCLCT, CSCCorrelatedLCTDigi::ALCTONLY, alctProc, allLCTs_, clct_trig_enable, CSCCorrelatedLCTDigi::CLCTONLY, clctProc, correlateLCTs(), drop_used_clcts, CSCBaseboard::infoV, LogTrace, match_earliest_clct_only_, match_trig_window_size, CSCConstants::MAX_ALCT_TBINS, CSCConstants::MAX_CLCT_TBINS, or, and preferred_bx_match_.
Referenced by run().
|
protected |
Definition at line 610 of file CSCMotherboard.cc.
References CSCConstants::ALCT_CLCT_OFFSET, simKBmtfDigis_cfi::bx, CSCShowerDigi::getComparatorNHits(), CSCShowerDigi::getCSCID(), CSCShowerDigi::getWireNHits(), CSCShowerDigi::isLooseInTime(), CSCShowerDigi::isNominalInTime(), CSCShowerDigi::isTightInTime(), CSCShowerDigi::isValid(), sistrip::SpyUtilities::isValid(), match_trig_window_size, CSCConstants::MAX_ALCT_TBINS, CSCConstants::MAX_CLCT_TBINS, or, preferred_bx_match_, and showers_.
Referenced by encodeHighMultiplicityBits().
|
virtual |
Definition at line 283 of file CSCMotherboard.cc.
References simKBmtfDigis_cfi::bx, CSCBaseboard::infoV, CSCBaseboard::isME11_, CSCConstants::LCT_CENTRAL_BX, lctV, LogDebug, CSCConstants::MAX_HALF_STRIP_ME1B, CSCConstants::MAX_LCT_TBINS, mpc_block_me1a, qualityControl_, readout_earliest_2, and tmb_l1a_window_size.
Referenced by CSCTriggerPrimitivesBuilder::build().
std::vector< CSCShowerDigi > CSCMotherboard::readoutShower | ( | ) | const |
Returns shower bits
Definition at line 379 of file CSCMotherboard.cc.
References simKBmtfDigis_cfi::bx, sistrip::SpyUtilities::isValid(), CSCConstants::LCT_CENTRAL_BX, maxbx_readout_, hltL1TEGammaFilteredCollectionProducer_cfi::minBX, minbx_readout_, showers_, and tmb_l1a_window_size.
Referenced by CSCTriggerPrimitivesBuilder::build().
void CSCMotherboard::run | ( | const CSCWireDigiCollection * | wiredc, |
const CSCComparatorDigiCollection * | compdc | ||
) |
Run function for normal usage. Runs cathode and anode LCT processors, takes results and correlates into CorrelatedLCT.
Definition at line 143 of file CSCMotherboard.cc.
References alctProc, alctV, clctProc, clctV, clear(), CSCBaseboard::cscGeometry_, encodeHighMultiplicityBits(), lookupTableCCLUT_, matchALCTCLCT(), CSCBaseboard::runCCLUT_, and selectLCTs().
Referenced by CSCTriggerPrimitivesBuilder::build().
void CSCMotherboard::selectLCTs | ( | ) |
Definition at line 528 of file CSCMotherboard.cc.
References allLCTs_, simKBmtfDigis_cfi::bx, mps_fire::i, CSCBaseboard::infoV, sistrip::SpyUtilities::isValid(), lctV, LogDebug, match_trig_window_size, CSCConstants::MAX_LCT_TBINS, and CSCConstants::MAX_LCTS_PER_CSC.
Referenced by CSCGEMMotherboard::run(), and run().
void CSCMotherboard::setConfigParameters | ( | const CSCDBL1TPParameters * | conf | ) |
Set configuration parameters obtained via EventSetup mechanism.
Definition at line 112 of file CSCMotherboard.cc.
References alct_trig_enable, alctProc, checkConfigParameters(), clct_trig_enable, clctProc, dumpConfigParams(), CSCConstants::LCT_CENTRAL_BX, match_trig_enable, match_trig_window_size, maxbx_readout_, minbx_readout_, mpc_block_me1a, tmb_l1a_window_size, CSCDBL1TPParameters::tmbAlctTrigEnable(), CSCDBL1TPParameters::tmbClctTrigEnable(), CSCDBL1TPParameters::tmbMatchTrigEnable(), CSCDBL1TPParameters::tmbMatchTrigWindowSize(), CSCDBL1TPParameters::tmbMpcBlockMe1a(), and CSCDBL1TPParameters::tmbTmbL1aWindowSize().
void CSCMotherboard::setESLookupTables | ( | const CSCL1TPLookupTableCCLUT * | conf | ) |
Definition at line 137 of file CSCMotherboard.cc.
References lookupTableCCLUT_.
void CSCMotherboard::setESLookupTables | ( | const CSCL1TPLookupTableME11ILT * | conf | ) |
Definition at line 139 of file CSCMotherboard.cc.
References lookupTableME11ILT_.
void CSCMotherboard::setESLookupTables | ( | const CSCL1TPLookupTableME21ILT * | conf | ) |
Definition at line 141 of file CSCMotherboard.cc.
References lookupTableME21ILT_.
|
protected |
Definition at line 134 of file CSCMotherboard.h.
Referenced by checkConfigParameters(), correlateLCTs(), CSCMotherboard(), dumpConfigParams(), matchALCTCLCT(), and setConfigParameters().
std::unique_ptr<CSCAnodeLCTProcessor> CSCMotherboard::alctProc |
Anode LCT processor.
Definition at line 104 of file CSCMotherboard.h.
Referenced by CSCTriggerPrimitivesBuilder::build(), clear(), CSCMotherboard(), encodeHighMultiplicityBits(), matchALCTCLCT(), CSCGEMMotherboard::matchALCTCLCTGEM(), CSCGEMMotherboard::run(), run(), and setConfigParameters().
|
protected |
Definition at line 117 of file CSCMotherboard.h.
Referenced by clear(), CSCGEMMotherboard::run(), and run().
|
protected |
Container with all LCTs prior to sorting and selecting.
Definition at line 121 of file CSCMotherboard.h.
Referenced by clear(), CSCMotherboard(), matchALCTCLCT(), CSCGEMMotherboard::matchALCTCLCTGEM(), and selectLCTs().
|
protected |
Definition at line 134 of file CSCMotherboard.h.
Referenced by checkConfigParameters(), correlateLCTs(), CSCMotherboard(), dumpConfigParams(), matchALCTCLCT(), and setConfigParameters().
std::unique_ptr<CSCCathodeLCTProcessor> CSCMotherboard::clctProc |
Cathode LCT processor.
Definition at line 107 of file CSCMotherboard.h.
Referenced by CSCTriggerPrimitivesBuilder::build(), clear(), CSCMotherboard(), encodeHighMultiplicityBits(), matchALCTCLCT(), CSCGEMMotherboard::matchALCTCLCTGEM(), CSCGEMMotherboard::run(), run(), and setConfigParameters().
|
protected |
Definition at line 118 of file CSCMotherboard.h.
Referenced by clear(), CSCGEMMotherboard::run(), and run().
|
protected |
Definition at line 182 of file CSCMotherboard.h.
Referenced by CSCMotherboard(), and doesALCTCrossCLCT().
|
staticprotected |
Definition at line 166 of file CSCMotherboard.h.
Referenced by checkConfigParameters().
|
staticprotected |
Definition at line 166 of file CSCMotherboard.h.
Referenced by checkConfigParameters().
|
staticprotected |
Definition at line 167 of file CSCMotherboard.h.
Referenced by checkConfigParameters().
|
staticprotected |
Definition at line 167 of file CSCMotherboard.h.
Referenced by checkConfigParameters().
|
staticprotected |
Default values of configuration parameters.
Definition at line 165 of file CSCMotherboard.h.
Referenced by checkConfigParameters().
|
staticprotected |
Definition at line 168 of file CSCMotherboard.h.
Referenced by checkConfigParameters().
|
protected |
Phase2: whether to not reuse CLCTs that were used by previous matching ALCTs
Definition at line 138 of file CSCMotherboard.h.
Referenced by CSCMotherboard(), and matchALCTCLCT().
|
protected |
Phase2: separate handle for early time bins
Definition at line 141 of file CSCMotherboard.h.
Referenced by CSCMotherboard().
|
protected |
Definition at line 155 of file CSCMotherboard.h.
Referenced by CSCMotherboard(), and doesALCTCrossCLCT().
|
protected |
Definition at line 124 of file CSCMotherboard.h.
Referenced by clear(), readoutLCTs(), and selectLCTs().
|
protected |
Definition at line 112 of file CSCMotherboard.h.
Referenced by CSCGEMMotherboard::run(), run(), and setESLookupTables().
|
protected |
Definition at line 113 of file CSCMotherboard.h.
Referenced by CSCGEMMotherboard::run(), and setESLookupTables().
|
protected |
Definition at line 114 of file CSCMotherboard.h.
Referenced by CSCGEMMotherboard::run(), and setESLookupTables().
|
protected |
Definition at line 147 of file CSCMotherboard.h.
Referenced by CSCMotherboard(), and matchALCTCLCT().
|
protected |
Definition at line 134 of file CSCMotherboard.h.
Referenced by checkConfigParameters(), correlateLCTs(), CSCGEMMotherboard::correlateLCTsGEM(), CSCMotherboard(), dumpConfigParams(), and setConfigParameters().
|
protected |
Definition at line 135 of file CSCMotherboard.h.
Referenced by checkConfigParameters(), CSCMotherboard(), dumpConfigParams(), matchALCTCLCT(), CSCGEMMotherboard::matchALCTCLCTGEM(), matchShowers(), selectLCTs(), and setConfigParameters().
|
protected |
Definition at line 153 of file CSCMotherboard.h.
Referenced by CSCMotherboard(), readoutShower(), and setConfigParameters().
|
protected |
Definition at line 152 of file CSCMotherboard.h.
Referenced by CSCMotherboard(), readoutShower(), and setConfigParameters().
|
protected |
Configuration parameters.
Definition at line 133 of file CSCMotherboard.h.
Referenced by checkConfigParameters(), CSCMotherboard(), dumpConfigParams(), readoutLCTs(), and setConfigParameters().
|
protected |
Definition at line 162 of file CSCMotherboard.h.
Referenced by CSCMotherboard(), matchALCTCLCT(), CSCGEMMotherboard::matchALCTCLCTGEM(), and matchShowers().
|
protected |
Definition at line 171 of file CSCMotherboard.h.
Referenced by constructLCTs(), CSCGEMMotherboard::constructLCTsGEM(), CSCGEMMotherboard::CSCGEMMotherboard(), and CSCMotherboard().
|
protected |
Definition at line 174 of file CSCMotherboard.h.
Referenced by CSCMotherboard(), and readoutLCTs().
|
protected |
Phase2: whether to readout only the earliest two LCTs in readout window
Definition at line 144 of file CSCMotherboard.h.
Referenced by CSCMotherboard(), and readoutLCTs().
|
protected |
Definition at line 126 of file CSCMotherboard.h.
Referenced by clear(), encodeHighMultiplicityBits(), matchShowers(), and readoutShower().
|
protected |
Definition at line 150 of file CSCMotherboard.h.
Referenced by CSCMotherboard().
|
protected |
Definition at line 151 of file CSCMotherboard.h.
Referenced by CSCMotherboard(), and encodeHighMultiplicityBits().
|
protected |
Definition at line 135 of file CSCMotherboard.h.
Referenced by checkConfigParameters(), CSCMotherboard(), dumpConfigParams(), readoutLCTs(), readoutShower(), and setConfigParameters().