9 #include "boost/container/flat_set.hpp" 12 { 0,2.441},{ 1,2.435},{ 2,2.425},{ 3,2.414},{ 4,2.404},{ 5,2.394},{ 6,2.384},{ 7,2.374},
13 { 8,2.365},{ 9,2.355},{10,2.346},{11,2.336},{12,2.327},{13,2.317},{14,2.308},{15,2.299},
14 {16,2.290},{17,2.281},{18,2.273},{19,2.264},{20,2.255},{21,2.247},{22,2.238},{23,2.230},
15 {24,2.221},{25,2.213},{26,2.205},{27,2.197},{28,2.189},{29,2.181},{30,2.173},{31,2.165},
16 {32,2.157},{33,2.149},{34,2.142},{35,2.134},{36,2.127},{37,2.119},{38,2.112},{39,2.104},
17 {40,2.097},{41,2.090},{42,2.083},{43,2.075},{44,2.070},{45,2.059},{46,2.054},{47,2.047},
18 {48,2.041},{49,2.034},{50,2.027},{51,2.020},{52,2.014},{53,2.007},{54,2.000},{55,1.994},
19 {56,1.988},{57,1.981},{58,1.975},{59,1.968},{60,1.962},{61,1.956},{62,1.950},{63,1.944},
20 {64,1.937},{65,1.931},{66,1.924},{67,1.916},{68,1.909},{69,1.902},{70,1.895},{71,1.888},
21 {72,1.881},{73,1.875},{74,1.868},{75,1.861},{76,1.854},{77,1.848},{78,1.841},{79,1.835},
22 {80,1.830},{81,1.820},{82,1.815},{83,1.809},{84,1.803},{85,1.796},{86,1.790},{87,1.784},
23 {88,1.778},{89,1.772},{90,1.766},{91,1.760},{92,1.754},{93,1.748},{94,1.742},{95,1.736},
24 {96,1.731},{97,1.725},{98,1.719},{99,1.714},{100,1.708},{101,1.702},{102,1.697},{103,1.691},
25 {104,1.686},{105,1.680},{106,1.675},{107,1.670},{108,1.664},{109,1.659},{110,1.654},{111,1.648},
29 { 0,2.412},{ 1,2.405},{ 2,2.395},{ 3,2.385},{ 4,2.375},{ 5,2.365},{ 6,2.355},{ 7,2.345},
30 { 8,2.335},{ 9,2.325},{10,2.316},{11,2.306},{12,2.297},{13,2.288},{14,2.279},{15,2.270},
31 {16,2.261},{17,2.252},{18,2.243},{19,2.234},{20,2.226},{21,2.217},{22,2.209},{23,2.200},
32 {24,2.192},{25,2.184},{26,2.175},{27,2.167},{28,2.159},{29,2.151},{30,2.143},{31,2.135},
33 {32,2.128},{33,2.120},{34,2.112},{35,2.105},{36,2.097},{37,2.090},{38,2.082},{39,2.075},
34 {40,2.068},{41,2.060},{42,2.053},{43,2.046},{44,2.041},{45,2.030},{46,2.025},{47,2.018},
35 {48,2.011},{49,2.005},{50,1.998},{51,1.991},{52,1.985},{53,1.978},{54,1.971},{55,1.965},
36 {56,1.958},{57,1.952},{58,1.946},{59,1.939},{60,1.933},{61,1.927},{62,1.921},{63,1.915},
37 {64,1.909},{65,1.902},{66,1.895},{67,1.887},{68,1.880},{69,1.873},{70,1.866},{71,1.859},
38 {72,1.853},{73,1.846},{74,1.839},{75,1.832},{76,1.826},{77,1.819},{78,1.812},{79,1.806},
39 {80,1.801},{81,1.792},{82,1.787},{83,1.780},{84,1.774},{85,1.768},{86,1.762},{87,1.756},
40 {88,1.750},{89,1.744},{90,1.738},{91,1.732},{92,1.726},{93,1.720},{94,1.714},{95,1.708},
41 {96,1.702},{97,1.697},{98,1.691},{99,1.685},{100,1.680},{101,1.674},{102,1.669},{103,1.663},
42 {104,1.658},{105,1.652},{106,1.647},{107,1.642},{108,1.636},{109,1.631},{110,1.626},{111,1.621},
50 {3, 0.01832829, 0.01003643 },
51 {5, 0.01095490, 0.00631625 },
52 {7, 0.00786026, 0.00501017 },
53 {10, 0.00596349, 0.00414560 },
54 {15, 0.00462411, 0.00365550 },
55 {20, 0.00435298, 0.00361550 },
56 {30, 0.00465160, 0.00335700 },
57 {40, 0.00372145, 0.00366262 }
61 unsigned sector,
unsigned subsector,
70 <<
"+++ Upgrade CSCMotherboardME21GEM constructed while isSLHC is not set! +++\n";
90 pref[
m-1] = pref[0] -
m/2;
91 pref[
m] = pref[0] +
m/2;
150 for (
int i=0;
i<2;
i++)
171 <<
"+++ run() called for non-existing ALCT/CLCT processor! +++ \n";
179 bool gemGeometryAvailable(
false);
180 if (
gem_g !=
nullptr) {
182 <<
"+++ run() called for GEM-CSC integrated trigger! +++ \n";
183 gemGeometryAvailable =
true;
189 const CSCDetId csc_id(cscChamber->id());
194 if ((not gemGeometryAvailable)
or (gemGeometryAvailable and (
gem_g->
stations()).
size()==2)) {
196 <<
"+++ run() called for GEM-CSC integrated trigger without valid GE21 geometry! +++ \n";
201 const CSCLayer* keyLayer(cscChamber->layer(3));
205 const int region((
theEndcap == 1) ? 1: -1);
206 const bool isEven(csc_id.chamber()%2==0);
207 const GEMDetId gem_id_long(region, 1, 2, 0, csc_id.chamber(), 0);
214 std::cout<<
"csc id "<< csc_id <<
" "<< csc_id.rawId() << (isEven ?
" even" :
" odd") <<
" chamber" << csc_id.chamber()<<std::endl;
215 if (gemRollToEtaLimits_.size())
216 for(
auto p : gemRollToEtaLimits_) {
217 std::cout <<
"pad "<<
p.first <<
" min eta " << (
p.second).
first <<
" max eta " << (
p.second).second << std::endl;
222 const int numberOfWG(keyLayerGeometry->numberOfWireGroups());
223 for (
int i = 0;
i< numberOfWG; ++
i){
229 std::cout <<
"WG "<<
p.first <<
" GEM roll " <<
p.second << std::endl;
233 auto randRoll(gemChamberLong->chamber(1)->etaPartition(2));
234 auto nStrips(keyLayerGeometry->numberOfStrips());
235 for (
float i = 0;
i< nStrips;
i =
i+0.5){
236 const LocalPoint lpCSC(keyLayerGeometry->topology()->localPosition(
i));
240 const bool edge(HS < 5 or HS > 155);
241 const float pad(edge ? -99 : randRoll->pad(lpGEM));
243 cscHsToGemPad_[HS] = std::make_pair(std::floor(pad),std::ceil(pad));
246 std::cout <<
"detId " << csc_id << std::endl;
248 std::cout <<
"CSC HS "<<
p.first <<
" GEM Pad low " << (
p.second).
first <<
" GEM Pad high " << (
p.second).second << std::endl;
253 const int nGEMPads(randRoll->npads());
254 for (
int i = 0;
i< nGEMPads; ++
i){
258 const float strip(keyLayerGeometry->strip(lpCSC));
263 std::cout <<
"detId " << csc_id << std::endl;
265 std::cout <<
"GEM Pad "<<
p.first <<
" CSC HS : " <<
p.second << std::endl;
279 int used_clct_mask[20];
280 for (
int c=0;
c<20;++
c) used_clct_mask[
c]=0;
282 const bool hasPads(
pads_.size()!=0);
283 const bool hasCoPads(hasPads and
coPads_.size()!=0);
288 if (
alct->bestALCT[bx_alct].isValid())
296 std::cout <<
"========================================================================" << std::endl;
297 std::cout <<
"ALCT-CLCT matching in ME2/1 chamber: " << cscChamber->id() << std::endl;
298 std::cout <<
"------------------------------------------------------------------------" << std::endl;
300 alct->bestALCT[bx_alct].print();
301 std::cout <<
"+++ Second ALCT Details: ";
302 alct->secondALCT[bx_alct].print();
306 std::cout <<
"------------------------------------------------------------------------" << std::endl;
307 std::cout <<
"Attempt ALCT-CLCT matching in ME2/1 in bx range: [" << bx_clct_start <<
"," << bx_clct_stop <<
"]" << std::endl;
311 int nSuccesFulMatches = 0;
312 for (
int bx_clct = bx_clct_start; bx_clct <= bx_clct_stop; bx_clct++)
316 if (
clct->bestCLCT[bx_clct].isValid())
319 const int quality(
clct->bestCLCT[bx_clct].getQuality());
321 const bool lowQualityALCT(
alct->bestALCT[bx_alct].getQuality() == 0);
323 const bool lowQuality(
quality<4
or lowQualityALCT);
330 int nFound(matchingPads.size());
331 const bool clctInEdge(
clct->bestCLCT[bx_clct].getKeyStrip() < 5
or clct->bestCLCT[bx_clct].getKeyStrip() > 155);
348 int nFound(matchingCoPads.size());
349 if (nFound != 0 and bx_alct == 6 and bx_clct != 6){
357 int mbx = bx_clct-bx_clct_start;
360 clct->bestCLCT[bx_clct],
clct->secondCLCT[bx_clct],
361 allLCTs[bx_alct][mbx][0],
allLCTs[bx_alct][mbx][1], matchingPads, matchingCoPads);
364 std::cout <<
"Successful ALCT-CLCT match in ME21: bx_alct = " << bx_alct
365 <<
"; match window: [" << bx_clct_start <<
"; " << bx_clct_stop
366 <<
"]; bx_clct = " << bx_clct << std::endl;
368 clct->bestCLCT[bx_clct].print();
369 std::cout <<
"+++ Second CLCT Details: ";
370 clct->secondCLCT[bx_clct].print();
372 if (
allLCTs[bx_alct][mbx][0].isValid()) {
373 used_clct_mask[bx_clct] += 1;
380 int nSuccesFulGEMMatches = 0;
383 for (
int bx_gem = bx_copad_start; bx_gem <= bx_copad_stop; bx_gem++) {
391 if (copads.size()==0) {
396 copads.at(0).second,
allLCTs[bx_alct][0][0],
allLCTs[bx_alct][0][1]);
397 if (
allLCTs[bx_alct][0][0].isValid()) {
398 ++nSuccesFulGEMMatches;
402 std::cout <<
"Successful ALCT-GEM CoPad match in ME21: bx_alct = " << bx_alct << std::endl << std::endl;
403 std::cout <<
"------------------------------------------------------------------------" << std::endl << std::endl;
409 std::cout <<
"========================================================================" << std::endl;
411 if (nSuccesFulMatches>1)
412 std::cout <<
"Too many successful ALCT-CLCT matches in ME21: " << nSuccesFulMatches
413 <<
", CSCDetId " << cscChamber->id()
414 <<
", bx_alct = " << bx_alct
415 <<
"; match window: [" << bx_clct_start <<
"; " << bx_clct_stop <<
"]" << std::endl;
416 else if (nSuccesFulMatches==1)
417 std::cout <<
"1 successful ALCT-CLCT match in ME21: " 418 <<
" CSCDetId " << cscChamber->id()
419 <<
", bx_alct = " << bx_alct
420 <<
"; match window: [" << bx_clct_start <<
"; " << bx_clct_stop <<
"]" << std::endl;
421 else if (nSuccesFulGEMMatches==1)
422 std::cout <<
"1 successful ALCT-GEM match in ME21: " 423 <<
" CSCDetId " << cscChamber->id()
424 <<
", bx_alct = " << bx_alct
425 <<
"; match window: [" << bx_clct_start <<
"; " << bx_clct_stop <<
"]" << std::endl;
427 std::cout <<
"Unsuccessful ALCT-CLCT match in ME21: " 428 <<
"CSCDetId " << cscChamber->id()
429 <<
", bx_alct = " << bx_alct
430 <<
"; match window: [" << bx_clct_start <<
"; " << bx_clct_stop <<
"]" << std::endl;
441 std::cout <<
"========================================================================" << std::endl;
443 std::cout <<
"GEM-CLCT matching in ME2/1 chamber: "<< cscChamber->id()<<
"in bx:"<<bx_alct<<std::endl;
444 std::cout <<
"------------------------------------------------------------------------" << std::endl;
447 int nSuccesFulMatches = 0;
452 if (
clct->bestCLCT[bx_alct].isValid())
454 const int quality(
clct->bestCLCT[bx_alct].getQuality());
460 int mbx =
std::abs(
clct->bestCLCT[bx_alct].getBX()-bx_alct);
466 std::cout <<
"Successful GEM-CLCT match in ME21: bx_alct = " << bx_alct <<std::endl;
470 clct->bestCLCT[bx_alct].print();
471 std::cout <<
"+++ Second CLCT Details: ";
472 clct->secondCLCT[bx_alct].print();
474 if (
allLCTs[bx_gem][mbx][0].isValid()) {
475 used_clct_mask[bx_alct] += 1;
489 for (
int i=0;
i<2;
i++)
491 int cbx = bx + mbx - match_trig_window_size/2;
496 <<
"LCT"<<
i+1<<
" "<<bx<<
"/"<<cbx<<
": "<<
allLCTs[bx][mbx][
i]<<std::endl;
505 for (
int i=0;
i<2;
i++)
516 for (
int i=0;
i<2;
i++)
518 int cbx = bx + mbx - match_trig_window_size/2;
527 <<
"bx "<<bx<<
" nnLCT:"<<n<<
" "<<n<<std::endl;
535 std::cout <<
"========================================================================" << std::endl;
536 std::cout <<
"Counting the final LCTs" << std::endl;
537 std::cout <<
"========================================================================" << std::endl;
557 std::vector<CSCCorrelatedLCTDigi>
result;
559 std::vector<CSCCorrelatedLCTDigi> tmpV;
562 result.insert(result.end(), tmpV.begin(), tmpV.end());
566 result.insert(result.end(), tmpV.begin(), tmpV.end());
570 for (
int i=0;
i<2;
i++) {
571 if (
allLCTs[bx][mbx][
i].isValid()) {
572 result.push_back(
allLCTs[bx][mbx][
i]);
584 std::vector<CSCCorrelatedLCTDigi> LCTs;
587 for (
int i=0;
i<2;
i++)
589 LCTs.push_back(
allLCTs[bx][mbx][
i]);
606 std::vector<CSCCorrelatedLCTDigi> LCTs;
609 for (
int i=0;
i<2;
i++)
611 LCTs.push_back(
allLCTs[bx][mbx][
i]);
630 const int nPads(pads.size());
631 const int nCoPads(copads.size());
632 const bool hasPads(nPads!=0);
633 const bool hasCoPads(nCoPads!=0);
635 bool anodeBestValid = bestALCT.
isValid();
636 bool anodeSecondValid = secondALCT.
isValid();
637 bool cathodeBestValid = bestCLCT.
isValid();
638 bool cathodeSecondValid = secondCLCT.
isValid();
640 if (anodeBestValid and !anodeSecondValid) secondALCT = bestALCT;
641 if (!anodeBestValid and anodeSecondValid) bestALCT = secondALCT;
642 if (cathodeBestValid and !cathodeSecondValid) secondCLCT = bestCLCT;
643 if (!cathodeBestValid and cathodeSecondValid) bestCLCT = secondCLCT;
655 if (((secondALCT != bestALCT)
or (secondCLCT != bestCLCT)) and
672 bool anodeBestValid = bestALCT.
isValid();
673 bool anodeSecondValid = secondALCT.
isValid();
675 if (anodeBestValid and !anodeSecondValid) secondALCT = bestALCT;
676 if (!anodeBestValid and anodeSecondValid) bestALCT = secondALCT;
702 bool cathodeBestValid = bestCLCT.
isValid();
703 bool cathodeSecondValid = secondCLCT.
isValid();
705 if (cathodeBestValid and !cathodeSecondValid) secondCLCT = bestCLCT;
706 if (!cathodeBestValid and cathodeSecondValid) bestCLCT = secondCLCT;
738 int bx = alct.
getBX();
747 return CSCCorrelatedLCTDigi(0, 1, quality, wg, keyStrip, pattern, 0, bx, 0, 0, 0,
theTrigChamber);
765 return CSCCorrelatedLCTDigi(0, 1, quality, wg, keyStrip, pattern, 0, bx, 0, 0, 0,
theTrigChamber);
787 return CSCCorrelatedLCTDigi(0, 1, quality, wg, clct.
getKeyStrip(),
pattern, clct.
getBend(), bx, 0, 0, 0,
theTrigChamber);
803 return CSCCorrelatedLCTDigi(0, 1, quality, wg, 0, pattern, 0, bx, 0, 0, 0,
theTrigChamber);
809 bool hasPad,
bool hasCoPad)
830 bool hasPad,
bool hasCoPad)
848 if (isDistrip) {quality = 4;}
857 if (sumQual < 1 || sumQual > 6) {
859 <<
"+++ findQuality: sumQual = " << sumQual <<
"+++ \n";
862 if (sumQual == 2) {quality = 6;}
863 else if (sumQual == 3) {quality = 7;}
864 else if (sumQual == 4) {quality = 8;}
865 else if (sumQual == 5) {quality = 9;}
866 else if (sumQual == 6) {quality = 10;}
869 if (sumQual == 2) {quality = 11;}
870 else if (sumQual == 3) {quality = 12;}
871 else if (sumQual == 4) {quality = 13;}
872 else if (sumQual == 5) {quality = 14;}
873 else if (sumQual == 6) {quality = 15;}
894 if (sumQual < 1 || sumQual > 6) {
896 <<
"+++ findQuality: Unexpected sumQual = " << sumQual <<
"+++\n";
905 quality = offset + sumQual;
923 if (hasPad) n_gem = 1;
924 if (hasCoPad) n_gem = 2;
928 if (!a4 && !c4) quality = 5;
929 else if ( a4 && !c4) quality = 6;
930 else if (!a4 && c4) quality = 7;
931 else if ( a4 && c4) {
940 else if (
pattern == 10) quality = 15;
943 <<
"+++ findQuality: Unexpected CLCT pattern id = " 955 std::map<int,std::pair<double,double> >
958 std::map<int,std::pair<double,double> >
result;
963 for(
int i = 1;
i<=
chamber->nEtaPartitions(); ++
i){
964 auto roll(
chamber->etaPartition(
i));
965 if (roll==
nullptr)
continue;
966 const float half_striplength(roll->specs()->specificTopology().stripLength()/2.);
967 const LocalPoint lp_top(0., half_striplength, 0.);
968 const LocalPoint lp_bottom(0., -half_striplength, 0.);
970 const GlobalPoint gp_bottom(roll->toGlobal(lp_bottom));
972 result[
i] = std::make_pair(gp_top.eta(), gp_bottom.eta());
980 for (
const auto& ch : superChamber->chambers()) {
981 for (
const auto& roll : ch->etaPartitions()) {
983 auto pads_in_det = gemPads->get(roll_id);
984 for (
auto pad = pads_in_det.first; pad != pads_in_det.second; ++pad) {
985 auto id_pad = std::make_pair(roll_id, *pad);
988 pads_[bx].push_back(id_pad);
999 coPads_[copad.bx(1)].push_back(std::make_pair(copad.roll(), copad.first()));
1000 coPads_[copad.bx(1)].push_back(std::make_pair(copad.roll(), copad.second()));
1008 const bool hasPads(thePads.size()!=0);
1010 std::cout <<
"------------------------------------------------------------------------" << std::endl;
1012 for (
int bx = bx_start; bx <= bx_stop; bx++) {
1015 std::vector<std::pair<unsigned int, const GEMPadDigi> > in_pads = thePads[bx];
1017 if (!iscopad)
std::cout <<
"* GEM trigger pads: " << std::endl;
1018 else std::cout <<
"* GEM trigger coincidence pads: " << std::endl;
1021 if (!iscopad)
std::cout <<
"N(pads) BX " << bx <<
" : " << in_pads.size() << std::endl;
1022 else std::cout <<
"N(copads) BX " << bx <<
" : " << in_pads.size() << std::endl;
1024 for (
const auto& pad : in_pads){
1029 std::cout <<
"\tdetId " << pad.first <<
" " << roll_id <<
", pad = " << pad.second.pad() <<
", BX = " << pad.second.bx() + 6 << std::endl;
1046 int clct_bx = clct.
getBX();
1049 const bool debug(
false);
1050 if (debug)
std::cout <<
"lowpad " << lowPad <<
" highpad " << highPad <<
" delta pad " << deltaPad <<std::endl;
1051 for (
const auto&
p: pads){
1055 auto padRoll((
p.second).pad());
1057 if (debug)
std::cout <<
"padRoll " << padRoll << std::endl;
1058 if (
std::abs(clct_bx-pad_bx)>deltaBX)
continue;
1060 if (debug)
std::cout <<
"++Matches! " << std::endl;
1061 result.push_back(
p);
1062 if (first)
return result;
1074 int alct_bx = alct.
getBX();
1076 std::vector<int> Rolls;
1083 const bool debug(
false);
1085 for (
const auto& alctRoll : Rolls)
1087 if (debug)
std::cout <<
"roll " << alctRoll << std::endl;
1088 for (
const auto&
p: pads){
1095 if (debug)
std::cout <<
"Candidate ALCT: " << padRoll << std::endl;
1096 if (
std::abs(alct_bx-pad_bx)>deltaBX)
continue;
1097 if (alctRoll != padRoll)
continue;
1098 if (debug)
std::cout <<
"++Matches! " << std::endl;
1099 result.push_back(
p);
1100 if (first)
return result;
1109 bool isCoPad,
bool first)
1117 const bool debug(
false);
1118 if (debug)
std::cout <<
"-----------------------------------------------------------------------"<<std::endl;
1120 for (
const auto&
p : padsAlct){
1121 if (debug)
std::cout<<
"Candidate ALCT: " <<
p.first <<
" " <<
p.second << std::endl;
1122 for (
const auto&
q: padsClct){
1123 if (debug)
std::cout<<
"++Candidate CLCT: " <<
q.first <<
" " <<
q.second << std::endl;
1125 if ((
p.first !=
q.first)
or p.second !=
q.second)
continue;
1126 if (debug)
std::cout <<
"++Matches! " << std::endl;
1127 result.push_back(
p);
1128 if (first)
return result;
1131 if (debug)
std::cout <<
"-----------------------------------------------------------------------"<<std::endl;
1140 const float minEta((
p.second).first);
1141 const float maxEta((
p.second).second);
1142 if (minEta <= eta and eta <= maxEta) {
int getQuality() const
return quality of a pattern (number of layers hit!)
std::vector< GEMCoPadDigi > readoutCoPads()
T getParameter(std::string const &) const
std::vector< CSCCorrelatedLCTDigi > getLCTs()
GEMPadsBX matchingGEMPads(const CSCCLCTDigi &cLCT, const GEMPadsBX &pads=GEMPadsBX(), bool isCopad=false, bool first=true)
unsigned int clct_trig_enable
CSCChamber * chamber(unsigned endcap, unsigned station, unsigned sector, unsigned subsector, unsigned tcscid) const
Return the CSCChamber for a corresponding endcap/station/sector/subsector/trigger cscid...
unsigned int findQualityGEM(const CSCALCTDigi &aLCT, const CSCCLCTDigi &cLCT, bool hasPad, bool hasCoPad)
std::unique_ptr< GEMCoPadProcessor > coPadProcessor
static bool sortByGEMDphi(const CSCCorrelatedLCTDigi &, const CSCCorrelatedLCTDigi &)
unsigned int match_trig_window_size
const unsigned theTrigChamber
bool isValid() const
check ALCT validity (1 - valid ALCT)
std::map< int, std::pair< double, double > > gemRollToEtaLimits_
bool promoteALCTGEMquality_
unsigned int tmb_cross_bx_algo
std::vector< CSCCorrelatedLCTDigi > sortLCTsByQuality(int bx)
bool promoteCLCTGEMquality_
int getStripType() const
return striptype
int deltaPad(int hs, int pad)
int getBend() const
return bend
bool dropLowQualityALCTsNoGEMs_
const unsigned theStation
int assignGEMRoll(double eta)
void retrieveGEMPads(const GEMPadDigiCollection *pads, unsigned id)
static CSCTriggerGeomManager * get()
static const double lut_wg_eta_odd[112][2]
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
const unsigned theSubsector
int getBX() const
return BX
unsigned int encodePattern(const int ptn, const int highPt)
Abs< T >::type abs(const T &t)
std::vector< GEMPadBX > GEMPadsBX
bool correctLCTtimingWithGEM_
bool isValid() const
check CLCT validity (1 - valid CLCT)
unsigned int match_trig_enable
unsigned int max_me21_lcts
int subdetId() const
get the contents of the subdetector field (not cast into any detector's numbering enum) ...
std::map< int, std::pair< double, double > > createGEMRollEtaLUT()
const GEMSuperChamber * superChamber(GEMDetId id) const
int getBX() const
return BX - five low bits of BXN counter tagged by the ALCT
int getQuality() const
return quality of a pattern
static const double lut_pt_vs_dphi_gemcsc[8][3]
int getAccelerator() const
void run(const CSCWireDigiCollection *wiredc, const CSCComparatorDigiCollection *compdc, const GEMPadDigiCollection *gemPads)
std::map< int, std::pair< int, int > > cscHsToGemPad_
int getPattern() const
return pattern
const GEMChamber * chamber(GEMDetId id) const
std::map< int, int > gemPadToCscHs_
bool buildLCTfromALCTandGEM_
CSCCorrelatedLCTDigi allLCTs[MAX_LCT_BINS][15][2]
const GEMGeometry * gem_g
unsigned int alct_trig_enable
bool buildLCTfromCLCTandGEM_
std::vector< GEMCoPadDigi > gemCoPadV
std::unique_ptr< CSCAnodeLCTProcessor > alct
void printGEMTriggerPads(int minBX, int maxBx, bool iscopad=false)
CSCCorrelatedLCTDigi constructLCTsGEM(const CSCALCTDigi &alct, const GEMPadDigi &gem, bool oldDataFormat=false)
bool doLCTGhostBustingWithGEMs_
std::vector< CSCCorrelatedLCTDigi > sortLCTsByGEMDPhi(int bx)
bool dropLowQualityCLCTsNoGEMs_
std::unique_ptr< CSCCathodeLCTProcessor > clct
std::vector< CSCCorrelatedLCTDigi > readoutLCTs()
const std::vector< const GEMStation * > & stations() const
Return a vector of all GEM stations.
CSCMotherboardME21GEM(unsigned endcap, unsigned station, unsigned sector, unsigned subsector, unsigned chamber, const edm::ParameterSet &conf)
bool match_earliest_clct_me21_only
bool useOldLCTDataFormat_
Detector det() const
get the detector field from this detid
void correlateLCTsGEM(CSCALCTDigi bestALCT, CSCALCTDigi secondALCT, GEMPadDigi gemPad, CSCCorrelatedLCTDigi &lct1, CSCCorrelatedLCTDigi &lct2)
std::map< int, int > cscWgToGemRoll_
int getKeyWG() const
return key wire group
bool promoteALCTGEMpattern_
static bool sortByQuality(const CSCCorrelatedLCTDigi &, const CSCCorrelatedLCTDigi &)
static const double lut_wg_eta_even[112][2]