14 monitorDir_(ps.getParameter<
std::
string>(
"monitorDir")),
25 alctNBin_(ps.getParameter<
std::
vector<unsigned>>(
"alctNBin")),
26 clctNBin_(ps.getParameter<
std::
vector<unsigned>>(
"clctNBin")),
27 lctNBin_(ps.getParameter<
std::
vector<unsigned>>(
"lctNBin")),
28 alctMinBin_(ps.getParameter<
std::
vector<double>>(
"alctMinBin")),
29 clctMinBin_(ps.getParameter<
std::
vector<double>>(
"clctMinBin")),
30 lctMinBin_(ps.getParameter<
std::
vector<double>>(
"lctMinBin")),
31 alctMaxBin_(ps.getParameter<
std::
vector<double>>(
"alctMaxBin")),
32 clctMaxBin_(ps.getParameter<
std::
vector<double>>(
"clctMaxBin")),
33 lctMaxBin_(ps.getParameter<
std::
vector<double>>(
"lctMaxBin")),
35 useB904ME11_(ps.getParameter<
bool>(
"useB904ME11")),
36 useB904ME21_(ps.getParameter<
bool>(
"useB904ME21")),
37 useB904ME234s2_(ps.getParameter<
bool>(
"useB904ME234s2")),
38 isRun3_(ps.getParameter<
bool>(
"isRun3")),
39 make1DPlots_(ps.getParameter<
bool>(
"make1DPlots")),
40 preTriggerAnalysis_(ps.getParameter<
bool>(
"preTriggerAnalysis")) {
79 for (
unsigned iType = 0; iType <
chambers_.size(); iType++) {
81 for (
unsigned iData = 0; iData <
dataEmul_.size(); iData++) {
83 for (
unsigned iVar = 0; iVar <
alctVars_.size(); iVar++) {
93 for (
unsigned iVar = 0; iVar <
clctVars_.size(); iVar++) {
103 for (
unsigned iVar = 0; iVar <
lctVars_.size(); iVar++) {
164 const std::array<std::string, 9> suffix_label{{
"4/2",
"4/1",
"3/2",
"3/1",
" 2/2",
"2/1",
"1/3",
"1/2",
"1/1"}};
167 for (
int ybin = 1; ybin <= 9; ++ybin) {
220 for (
auto it = dataALCTs->begin(); it != dataALCTs->end(); it++) {
221 auto range = dataALCTs->get((*it).first);
223 int type = ((*it).first).iChamberType() - 2;
234 for (
auto alct =
range.first; alct !=
range.second; alct++) {
235 if (alct->isValid()) {
243 for (
auto it = emulALCTs->begin(); it != emulALCTs->end(); it++) {
244 auto range = emulALCTs->get((*it).first);
246 int type = ((*it).first).iChamberType() - 2;
257 for (
auto alct =
range.first; alct !=
range.second; alct++) {
258 if (alct->isValid()) {
267 std::vector<CSCCLCTDigi> tempdata;
268 std::vector<CSCCLCTDigi> tempemul;
270 for (
auto it = dataCLCTs->begin(); it != dataCLCTs->end(); it++) {
271 auto range = dataCLCTs->get((*it).first);
273 int type = ((*it).first).iChamberType() - 2;
284 for (
auto clct =
range.first; clct !=
range.second; clct++) {
285 if (clct->isValid()) {
287 tempdata.push_back(*clct);
301 chamberHistos[
type][
"clct_eighthstripbit_data"]->Fill(clct->getEighthStripBit());
308 for (
auto it = emulCLCTs->begin(); it != emulCLCTs->end(); it++) {
309 auto range = emulCLCTs->get((*it).first);
311 int type = ((*it).first).iChamberType() - 2;
322 for (
auto clct =
range.first; clct !=
range.second; clct++) {
323 if (clct->isValid()) {
325 tempemul.push_back(*clct);
339 chamberHistos[
type][
"clct_eighthstripbit_emul"]->Fill(clct->getEighthStripBit());
348 if (tempdata.size() != tempemul.size()) {
349 for (
auto& clct : tempdata) {
352 for (
auto& clct : tempemul) {
355 for (
auto it = emulpreCLCTs->
begin(); it != emulpreCLCTs->
end(); it++) {
356 auto range = emulpreCLCTs->
get((*it).first);
357 for (
auto clct =
range.first; clct !=
range.second; clct++) {
364 for (
auto it = dataLCTs->begin(); it != dataLCTs->end(); it++) {
365 auto range = dataLCTs->get((*it).first);
367 int type = ((*it).first).iChamberType() - 2;
378 for (
auto lct =
range.first; lct !=
range.second; lct++) {
379 if (lct->isValid()) {
399 for (
auto it = emulLCTs->begin(); it != emulLCTs->end(); it++) {
400 auto range = emulLCTs->get((*it).first);
402 int type = ((*it).first).iChamberType() - 2;
413 for (
auto lct =
range.first; lct !=
range.second; lct++) {
414 if (lct->isValid()) {
436 const std::map<std::pair<int, int>,
int> histIndexCSC = {{{1, 1}, 8},
457 for (
int endc = min_endcap; endc <= max_endcap; endc++) {
459 for (
int stat = min_station;
stat <= max_station;
stat++) {
460 int numsubs = ((
stat == 1) ? max_subsector : 1);
462 for (
int sect = min_sector; sect <= max_sector; sect++) {
463 for (
int subs = min_subsector; subs <= numsubs; subs++) {
465 for (
int cham = min_chamber;
cham <= max_chamber;
cham++) {
477 int sr = histIndexCSC.at({
stat,
ring});
482 auto range_dataALCT = dataALCTs->get(detid);
483 auto range_emulALCT = emulALCTs->get(detid);
485 for (
auto dalct = range_dataALCT.first; dalct != range_dataALCT.second; dalct++) {
486 if (dalct->isValid()) {
489 for (
auto ealct = range_emulALCT.first; ealct != range_emulALCT.second; ealct++) {
490 if (ealct->isValid() and *dalct == *ealct) {
497 for (
auto ealct = range_emulALCT.first; ealct != range_emulALCT.second; ealct++) {
499 if (ealct->isValid()) {
502 for (
auto dalct = range_dataALCT.first; dalct != range_dataALCT.second; dalct++) {
503 if (*dalct == *ealct)
515 auto range_dataCLCT = dataCLCTs->get(detid);
516 auto range_emulCLCT = emulCLCTs->get(detid);
518 for (
auto dclct = range_dataCLCT.first; dclct != range_dataCLCT.second; dclct++) {
519 if (dclct->isValid()) {
522 for (
auto eclct = range_emulCLCT.first; eclct != range_emulCLCT.second; eclct++) {
523 if (eclct->isValid() and
areSameCLCTs(*dclct, *eclct)) {
530 for (
auto eclct = range_emulCLCT.first; eclct != range_emulCLCT.second; eclct++) {
532 if (eclct->isValid()) {
535 for (
auto dclct = range_dataCLCT.first; dclct != range_dataCLCT.second; dclct++) {
548 auto range_dataLCT = dataLCTs->get(detid);
549 auto range_emulLCT = emulLCTs->get(detid);
551 for (
auto dlct = range_dataLCT.first; dlct != range_dataLCT.second; dlct++) {
552 if (dlct->isValid()) {
555 for (
auto elct = range_emulLCT.first; elct != range_emulLCT.second; elct++) {
556 if (elct->isValid() and
areSameLCTs(*dlct, *elct)) {
563 for (
auto elct = range_emulLCT.first; elct != range_emulLCT.second; elct++) {
565 if (elct->isValid()) {
568 for (
auto dlct = range_dataLCT.first; dlct != range_dataLCT.second; dlct++) {
590 bool returnValue =
false;
602 bool returnValue =
false;
MonitorElement * lctEmulSummary_denom_
std::vector< double > lctMaxBin_
edm::EDGetTokenT< CSCALCTDigiCollection > dataALCT_token_
MonitorElement * lctEmulSummary_num_
edm::EDGetTokenT< CSCCorrelatedLCTDigiCollection > dataLCT_token_
std::vector< std::string > alctVars_
MonitorElement * clctEmulSummary_num_
virtual void setCurrentFolder(std::string const &fullpath)
std::vector< unsigned > alctNBin_
virtual void setOption(const char *option)
static int maxTriggerCscId()
uint16_t getQuality() const
return quality of a pattern (number of layers hit!)
static int maxTriggerSectorId()
uint16_t getKeyStrip(const uint16_t n=2) const
bool getEighthStripBit() const
get single eighth strip bit
std::vector< double > alctMinBin_
static int maxStationId()
MonitorElement * alctDataSummary_num_
static int minTriggerSectorId()
static int ringFromTriggerLabels(int station, int triggerCSCID)
edm::EDGetTokenT< CSCCorrelatedLCTDigiCollection > emulLCT_token_
bool getQuartStripBit() const
get single quart strip bit
MonitorElement * lctDataSummary_denom_
static int minStationId()
The Signals That Services Can Subscribe To This is based on ActivityRegistry and is current per Services can connect to the signals distributed by the ActivityRegistry in order to monitor the activity of the application Each possible callback has some defined which we here list in angle e< void, edm::EventID const &, edm::Timestamp const & > We also list in braces which AR_WATCH_USING_METHOD_ is used for those or
std::map< uint32_t, std::map< std::string, MonitorElement * > > chamberHistos
Range get(const IndexType &index) const
return the digis for a given DetUnit
MonitorElement * lctDataSummary_num_
std::vector< unsigned > lctNBin_
bool isMatched(TrackingRecHit const &hit)
uint16_t getStripType() const
return striptype
MonitorElement * alctEmulSummary_num_
std::vector< double > alctMaxBin_
bool isValid() const
check CLCT validity (1 - valid CLCT)
virtual void setBinLabel(int bin, const std::string &label, int axis=1)
set bin label for x, y or z axis (axis=1, 2, 3 respectively)
DigiRangeIterator begin() const
MonitorElement * alctDataSummary_denom_
bool areSameLCTs(const CSCCorrelatedLCTDigi &lhs, const CSCCorrelatedLCTDigi &rhs) const
edm::EDGetTokenT< CSCALCTDigiCollection > emulALCT_token_
std::vector< std::string > chambers_
L1TdeCSCTPG(const edm::ParameterSet &ps)
MonitorElement * clctEmulSummary_denom_
std::vector< unsigned > clctNBin_
static int minTriggerSubSectorId()
MonitorElement * book2D(TString const &name, TString const &title, int nchX, double lowX, double highX, int nchY, double lowY, double highY, FUNC onbooking=NOOP())
std::vector< double > clctMaxBin_
uint16_t getPattern() const
return pattern
std::vector< std::string > dataEmul_
edm::EDGetTokenT< CSCCLCTDigiCollection > dataCLCT_token_
std::vector< std::string > lctVars_
std::vector< double > clctMinBin_
std::vector< double > lctMinBin_
uint16_t getRun3Pattern() const
return pattern
edm::EDGetTokenT< CSCCLCTPreTriggerDigiCollection > emulpreCLCT_token_
bool areSameCLCTs(const CSCCLCTDigi &lhs, const CSCCLCTDigi &rhs) const
static int minTriggerCscId()
Log< level::Warning, false > LogWarning
MonitorElement * book1D(TString const &name, TString const &title, int const nchX, double const lowX, double const highX, FUNC onbooking=NOOP())
void bookHistograms(DQMStore::IBooker &, const edm::Run &, const edm::EventSetup &) override
std::vector< std::string > clctVars_
MonitorElement * clctDataSummary_denom_
MonitorElement * alctEmulSummary_denom_
static int chamberFromTriggerLabels(int TriggerSector, int TriggerSubSector, int station, int TriggerCSCID)
static int maxTriggerSubSectorId()
MonitorElement * clctDataSummary_num_
DigiRangeIterator end() const
edm::EDGetTokenT< CSCCLCTDigiCollection > emulCLCT_token_
virtual void setAxisTitle(const std::string &title, int axis=1)
set x-, y- or z-axis title (axis=1, 2, 3 respectively)
void analyze(const edm::Event &, const edm::EventSetup &) override
A container for a generic type of digis indexed by some index, implemented with a map<IndexType...