|
|
Go to the documentation of this file.
105 collNotFoundWarn_(ps.getUntrackedParameter<
bool>(
"warnIfCollectionNotFound",
true)),
106 ebDigis_(ps.getParameter<
edm::
InputTag>(
"EbDigiCollection"),
false, collNotFoundWarn_),
107 eeDigis_(ps.getParameter<
edm::
InputTag>(
"EeDigiCollection"),
false, collNotFoundWarn_),
110 ebSrFlags_(ps.getParameter<
edm::
InputTag>(
"EbSrFlagCollection"),
false, collNotFoundWarn_),
111 eeSrFlags_(ps.getParameter<
edm::
InputTag>(
"EeSrFlagCollection"),
false, collNotFoundWarn_),
118 tps_(ps.getParameter<
edm::
InputTag>(
"TrigPrimCollection"),
false, collNotFoundWarn_),
123 tmin(numeric_limits<int64_t>::
max()),
126 triggerTowerMap_(nullptr),
127 localReco_(ps.getParameter<
bool>(
"LocalReco")),
128 weights_(ps.getParameter<
vector<double> >(
"weights")),
129 tpInGeV_(ps.getParameter<
bool>(
"tpInGeV")),
130 firstFIRSample_(ps.getParameter<
int>(
"ecalDccZs1stSample")),
131 useEventRate_(ps.getParameter<
bool>(
"useEventRate")),
132 logErrForDccs_(nDccs_,
false),
135 histDir_(ps.getParameter<
string>(
"histDir")),
136 withEeSimHit_(
false),
137 withEbSimHit_(
false) {
149 tps_.setToken(collector);
154 double ebZsThr = ps.
getParameter<
double>(
"ebZsThrADCCount");
155 double eeZsThr = ps.
getParameter<
double>(
"eeZsThrADCCount");
175 LogInfo(
"OutputInfo") <<
" Ecal Digi Task histograms will be saved to '" <<
outputFile_.c_str() <<
"'";
177 LogInfo(
"OutputInfo") <<
" Ecal Digi Task histograms will NOT be saved";
187 for (vector<string>::iterator it =
hists.begin(); it !=
hists.end(); ++it)
194 const int32_t
bx =
event.bunchCrossing();
195 if (bx < 1 || bx > 3564)
198 int64_t
t =
event.bunchCrossing() + (
event.orbitNumber() - 1) * 3564;
212 LogDebug(
"EcalSrValid") << __FILE__ <<
":" << __LINE__ <<
": "
213 <<
"Tmax = " <<
tmax <<
" x 25ns; Tmin = " <<
tmin <<
" x 25ns; L1A(Tmax) = " <<
l1aOfTmax
214 <<
"; L1A(Tmin) = " <<
l1aOfTmin <<
"\n";
228 edm::LogInfo(
"EcalSrValid") <<
"Size of TP collection: " <<
tps_->size() << std::endl
229 <<
"Size of EB SRF collection read from data: " <<
ebSrFlags_->size() << std::endl
230 <<
"Size of EB SRF collection computed from data TTFs: " <<
ebComputedSrFlags_->size()
232 <<
"Size of EE SRF collection read from data: " <<
eeSrFlags_->size() << std::endl
233 <<
"Size of EE SRF collection computed from data TTFs: " <<
eeComputedSrFlags_->size()
290 bool eventError =
false;
294 for (
int iZ0 = 0; iZ0 <
nEndcaps; ++iZ0) {
295 for (
int iX0 = 0; iX0 <
nEeX; ++iX0) {
296 for (
int iY0 = 0; iY0 <
nEeY; ++iY0) {
316 int iZ0 =
frame.id().zside() > 0 ? 1 : 0;
318 if (iX0 < 0 || iX0 >=
nEeX) {
319 edm::LogError(
"EcalSrValid") <<
"iX0 (= " << iX0 <<
") is out of range ("
320 <<
"[0," <<
nEeX - 1 <<
"]\n";
322 if (iY0 < 0 || iY0 >=
nEeY) {
323 edm::LogError(
"EcalSrValid") <<
"iY0 (= " << iY0 <<
") is out of range ("
324 <<
"[0," <<
nEeY - 1 <<
"]\n";
330 for (
int i = 0;
i <
frame.size(); ++
i) {
331 const int gain12Code = 0x1;
348 int iZ0 = static_cast<const EEDetId&>(
hit.
id()).
zside() > 0 ? 1 : 0;
350 if (iX0 < 0 || iX0 >=
nEeX) {
351 LogError(
"EcalSrValid") <<
"iX0 (= " << iX0 <<
") is out of range ("
352 <<
"[0," <<
nEeX - 1 <<
"]\n";
354 if (iY0 < 0 || iY0 >=
nEeY) {
355 LogError(
"EcalSrValid") <<
"iY0 (= " << iY0 <<
") is out of range ("
356 <<
"[0," <<
nEeY - 1 <<
"]\n";
364 for (vector<PCaloHit>::const_iterator it =
eeSimHits_->begin(); it !=
eeSimHits_->end(); ++it) {
371 int iZ0 = detId.zside() > 0 ? 1 : 0;
377 pair<int, int> EExtalCoor[
nEeX][
nEeY][2];
379 for (
int iEeZ = 0; iEeZ < 2; ++iEeZ) {
380 for (
int iEeX = 0; iEeX <
nEeX; ++iEeX) {
381 for (
int iEeY = 0; iEeY <
nEeY; ++iEeY) {
382 EEcrystalShot[iEeX][iEeY][iEeZ] =
false;
383 EExtalCoor[iEeX][iEeY][iEeZ] = make_pair(0, 0);
393 int iZ0 = static_cast<const EEDetId&>(
frame.id()).
zside() > 0 ? 1 : 0;
394 if (iX0 < 0 || iX0 >=
nEeX) {
395 LogError(
"EcalSrValid") <<
"iX0 (= " << iX0 <<
") is out of range ("
396 <<
"[0," <<
nEeX - 1 <<
"]\n";
398 if (iY0 < 0 || iY0 >=
nEeY) {
399 LogError(
"EcalSrValid") <<
"iY0 (= " << iY0 <<
") is out of range ("
400 <<
"[0," <<
nEeY - 1 <<
"]\n";
403 if (!EEcrystalShot[iX0][iY0][iZ0]) {
404 EEcrystalShot[iX0][iY0][iZ0] =
true;
407 cout <<
"Error: several digi for same crystal!";
416 for (
int i = 0;
i <
frame.size(); ++
i) {
417 const int gain12Code = 0x1;
425 bool highInterest =
false;
447 <<
"RU " <<
frame.id() <<
", "
448 <<
"DCC " << ru.first <<
" Ch : " << ru.second <<
": "
449 <<
"LI channel under ZS threshold.\n";
453 <<
"more ZS errors for this event...\n";
459 for (
int iEeZ = 0; iEeZ < 2; ++iEeZ) {
460 for (
int iEeX = 0; iEeX <
nEeX; ++iEeX) {
461 for (
int iEeY = 0; iEeY <
nEeY; ++iEeY) {
463 EExtalCoor[iEeX][iEeY][iEeZ].
first,
464 EExtalCoor[iEeX][iEeY][iEeZ].
second,
465 EEcrystalShot[iEeX][iEeY][iEeZ] ? 1 : 0);
470 for (
int iZ0 = 0; iZ0 <
nEndcaps; ++iZ0) {
471 for (
int iX0 = 0; iX0 <
nEeX; ++iX0) {
472 for (
int iY0 = 0; iY0 <
nEeY; ++iY0) {
494 int EEZs1RuCount[2][20][20];
495 int EEFullRuCount[2][20][20];
496 int EEForcedRuCount[2][20][20];
497 for (
int iZ(0); iZ < 2; iZ++) {
498 for (
int iX(0); iX < 20; iX++) {
499 for (
int iY(0); iY < 20; iY++) {
500 EEZs1RuCount[iZ][iX][iY] = 0;
501 EEFullRuCount[iZ][iX][iY] = 0;
502 EEForcedRuCount[iZ][iX][iY] = 0;
508 char eeSrfMark[2][20][20];
509 bzero(eeSrfMark,
sizeof(eeSrfMark));
514 int iX = srf.
id().
ix();
515 int iY = srf.
id().
iy();
517 if (iX < 1 || iY > 100)
519 <<
"Found an endcap SRF with an invalid det ID: " << srf.
id() <<
".\n";
520 ++eeSrfMark[
zside > 0 ? 1 : 0][iX - 1][iY - 1];
521 if (eeSrfMark[
zside > 0 ? 1 : 0][iX - 1][iY - 1] > 1)
522 throw cms::Exception(
"EcalSelectiveReadoutValidation") <<
"Duplicate SRF for supercrystal " << srf.
id() <<
".\n";
525 EEZs1RuCount[
zside > 0 ? 1 : 0][iX - 1][iY - 1] += 1;
529 EEFullRuCount[
zside > 0 ? 1 : 0][iX - 1][iY - 1] += 1;
534 EEForcedRuCount[
zside > 0 ? 1 : 0][iX - 1][iY - 1] += 1;
537 for (
int iZ(0); iZ < 2; iZ++) {
538 int xOffset(iZ == 0 ? -40 : 20);
539 for (
int iX(0); iX < 20; iX++) {
540 for (
int iY(0); iY < 20; iY++) {
541 int GraphX = (iX + 1) +
xOffset;
542 int GraphY = (iY + 1);
543 fill(
meZs1Ru_, GraphX, GraphY, EEZs1RuCount[iZ][iX][iY]);
552 <<
" ZS-flagged EE channels under "
553 "the ZS threshold, whose "
558 bool eventError =
false;
561 vector<pair<int, int> > xtalEtaPhi;
564 for (
int iEta0 = 0; iEta0 <
nEbEta; ++iEta0) {
565 for (
int iPhi0 = 0; iPhi0 <
nEbPhi; ++iPhi0) {
571 xtalEtaPhi.push_back(pair<int, int>(iEta0, iPhi0));
585 if (iEta0 < 0 || iEta0 >=
nEbEta) {
587 s <<
"EcalSelectiveReadoutValidation: "
588 <<
"iEta0 (= " << iEta0 <<
") is out of range ("
589 <<
"[0," <<
nEbEta - 1 <<
"]\n";
592 if (iPhi0 < 0 || iPhi0 >=
nEbPhi) {
594 s <<
"EcalSelectiveReadoutValidation: "
595 <<
"iPhi0 (= " << iPhi0 <<
") is out of range ("
596 <<
"[0," <<
nEbPhi - 1 <<
"]\n";
602 for (
int i = 0;
i <
frame.size(); ++
i) {
603 const int gain12Code = 0x1;
615 for (vector<PCaloHit>::const_iterator it =
ebSimHits_->begin(); it !=
ebSimHits_->end(); ++it) {
618 int iEta = detId.ieta();
620 int iPhi = detId.iphi();
629 for (
int iEta0 = 0; iEta0 <
nEbEta; ++iEta0) {
630 for (
int iPhi0 = 0; iPhi0 <
nEbPhi; ++iPhi0) {
631 crystalShot[iEta0][iPhi0] =
false;
632 EBxtalCoor[iEta0][iPhi0] = make_pair(0, 0);
642 int iPhi = static_cast<const EBDetId&>(
frame.id()).
iphi();
645 if (iEta0 < 0 || iEta0 >=
nEbEta) {
646 throw(
cms::Exception(
"EcalSelectiveReadoutValidation") <<
"iEta0 (= " << iEta0 <<
") is out of range ("
647 <<
"[0," <<
nEbEta - 1 <<
"]");
649 if (iPhi0 < 0 || iPhi0 >=
nEbPhi) {
650 throw(
cms::Exception(
"EcalSelectiveReadoutValidation") <<
"iPhi0 (= " << iPhi0 <<
") is out of range ("
651 <<
"[0," <<
nEbPhi - 1 <<
"]");
655 if (!crystalShot[iEta0][iPhi0]) {
656 crystalShot[iEta0][iPhi0] =
true;
659 cout <<
"Error: several digi for same crystal!";
667 for (
int i = 0;
i <
frame.size(); ++
i) {
668 const int gain12Code = 0x1;
676 bool highInterest =
false;
700 <<
"RU " <<
frame.id() <<
", "
701 <<
"DCC " << ru.first <<
" Ch : " << ru.second <<
": "
702 <<
"LI channel under ZS threshold.\n";
706 <<
"more ZS errors for this event...\n";
712 for (
int iEta0 = 0; iEta0 <
nEbEta; ++iEta0) {
713 for (
int iPhi0 = 0; iPhi0 <
nEbPhi; ++iPhi0)
715 EBxtalCoor[iEta0][iPhi0].
first,
716 EBxtalCoor[iEta0][iPhi0].
second,
717 crystalShot[iEta0][iPhi0] ? 1. : 0.);
725 int iPhi = static_cast<const EBDetId&>(
hit.
id()).
iphi();
728 if (iEta0 < 0 || iEta0 >=
nEbEta) {
729 LogError(
"EcalSrValid") <<
"iEta0 (= " << iEta0 <<
") is out of range ("
730 <<
"[0," <<
nEbEta - 1 <<
"]\n";
732 if (iPhi0 < 0 || iPhi0 >=
nEbPhi) {
733 LogError(
"EcalSrValid") <<
"iPhi0 (= " << iPhi0 <<
") is out of range ("
734 <<
"[0," <<
nEbPhi - 1 <<
"]\n";
740 for (
unsigned int i = 0;
i < xtalEtaPhi.size(); ++
i) {
741 int iEta0 = xtalEtaPhi[
i].first;
742 int iPhi0 = xtalEtaPhi[
i].second;
745 double recE = energies.
recE;
763 int EBZs1RuCount[2][17][72];
764 int EBFullRuCount[2][17][72];
765 int EBForcedRuCount[2][17][72];
766 std::pair<int, int> EBtowerCoor[2][17][72];
767 for (
int iZ(0); iZ < 2; iZ++) {
769 for (
int iPhi(0); iPhi < 72; iPhi++) {
770 EBZs1RuCount[iZ][
iEta][iPhi] = 0;
771 EBFullRuCount[iZ][
iEta][iPhi] = 0;
772 EBForcedRuCount[iZ][
iEta][iPhi] = 0;
779 char ebSrfMark[2][17][72];
780 bzero(ebSrfMark,
sizeof(ebSrfMark));
785 int iPhi = srf.
id().
iphi();
791 if (iEtaAbs < 1 || iEtaAbs > 17 || iPhi < 1 || iPhi > 72)
793 <<
"Found a barrel SRF with an invalid det ID: " << srf.
id() <<
".\n";
794 ++ebSrfMark[iZ > 0 ? 1 : 0][iEtaAbs - 1][iPhi - 1];
795 if (ebSrfMark[iZ > 0 ? 1 : 0][iEtaAbs - 1][iPhi - 1] > 1)
796 throw cms::Exception(
"EcalSelectiveReadoutValidation") <<
"Duplicate SRF for RU " << srf.
id() <<
".\n";
798 EBtowerCoor[iZ > 0 ? 1 : 0][iEtaAbs - 1][iPhi - 1] = std::pair<int, int>(srf.
id().
ieta(), srf.
id().
iphi());
802 EBZs1RuCount[iZ > 0 ? 1 : 0][iEtaAbs - 1][iPhi - 1] += 1;
805 EBFullRuCount[iZ > 0 ? 1 : 0][iEtaAbs - 1][iPhi - 1] += 1;
809 EBForcedRuCount[iZ > 0 ? 1 : 0][iEtaAbs - 1][iPhi - 1] += 1;
812 for (
int iZ(0); iZ < 2; iZ++) {
814 for (
int iPhi(0); iPhi < 72; iPhi++) {
826 <<
" ZS-flagged EB channels under "
827 "the ZS threshold, whose "
859 "ECAL DCC event fragment size;Dcc id; "
867 "LI channel payload per DCC;Dcc id; "
875 "HI channel payload per DCC;Dcc id; "
883 "ECAL DCC event fragment size;Dcc id; "
891 "ECAL Barrel low interest crystal data payload;"
892 "Event size (kB);Nevts",
899 "Endcap low interest crystal data payload;"
900 "Event size (kB);Nevts",
907 "ECAL low interest crystal data payload;"
908 "Event size (kB);Nevts",
915 "Barrel high interest crystal data payload;"
916 "Event size (kB);Nevts",
923 "Endcap high interest crystal data payload;"
924 "Event size (kB);Nevts",
931 "ECAL high interest crystal data payload;"
932 "Event size (kB);Nevts",
939 "Barrel data volume;Event size (kB);Nevts",
946 "Endcap data volume;Event size (kB);Nevts",
953 "ECAL data volume;Event size (kB);Nevts",
960 "ECAL crystal channel occupancy after zero suppression;"
961 "iX -200 / iEta / iX + 100;"
962 "iY / iPhi (starting from -10^{o}!);"
976 tpUnit =
string(
"TP hw unit");
978 title =
string(
"Trigger primitive TT E_{T};E_{T} ") + tpUnit +
string(
";Event Count");
988 "Trigger primitive TT flag;Flag number;Event count",
993 title =
string(
"Trigger tower flag vs TP;E_{T}(TT) (") + tpUnit +
string(
");Flag number");
998 "Trigger tower flag vs #sumE_{T};"
1008 "Trigger primitive Et (TP) vs #sumE_{T};"
1009 "E_{T} (sum) (GeV);"
1016 "Trigger primitive E_{T};"
1026 "Full Read-out readout unit;"
1027 "iX - 40 / iEta / iX + 20;"
1028 "iY / iPhi (iPhi = 1 at phi = 0 rad);"
1039 "Number of Full-readout-flagged readout units;"
1040 "FRO RU count;Event count",
1047 "Number of EB Full-readout-flagged readout units;"
1048 "FRO RU count;Event count",
1055 "Number of EE Full-readout-flagged readout units;"
1056 "FRO RU count;Event count",
1063 "Readout unit with ZS-thr-1 flag;"
1064 "iX - 40 / iEta / iX + 20;"
1065 "iY0 / iPhi0 (iPhi = 1 at phi = 0 rad);"
1076 "ECAL readout unit with forced bit of SR flag on;"
1077 "iX - 40 / iEta / iX + 20;"
1078 "iY / iPhi (iPhi = 1 at phi = 0 rad);"
1089 "Low interest trigger tower flags;"
1102 "Mid interest trigger tower flags;"
1115 "High interest trigger tower flags;"
1128 "Trigger tower flags with forced bit set;"
1139 const float ebMinNoise = -1.;
1140 const float ebMaxNoise = 1.;
1142 const float eeMinNoise = -1.;
1143 const float eeMaxNoise = 1.;
1145 const float ebMinE = ebMinNoise;
1146 const float ebMaxE = ebMaxNoise;
1148 const float eeMinE = eeMinNoise;
1149 const float eeMaxE = eeMaxNoise;
1151 const int evtMax = 500;
1153 meEbRecE_ =
book1D(ibooker,
"hEbRecE",
"Crystal reconstructed energy;E (GeV);Event count", 100, ebMinE, ebMaxE);
1155 meEbEMean_ =
bookProfile(ibooker,
"hEbEMean",
"EE <E_hit>;event #;<E_hit> (GeV)", evtMax, .5, evtMax + .5);
1160 "(rec E of crystal without deposited energy)"
1161 ";Rec E (GeV);Event count",
1168 "Emulated ouput of ZS FIR filter for EB "
1169 "low interest crystals;"
1178 "Emulated ouput of ZS FIR filter for EB "
1179 "high interest crystals;"
1194 meEbSimE_ =
book1D(ibooker,
"hEbSimE",
"EB hit crystal simulated energy", 100, ebMinE, ebMaxE);
1196 meEbRecEHitXtal_ =
book1D(ibooker,
"hEbRecEHitXtal",
"EB rec energy of hit crystals", 100, ebMinE, ebMaxE);
1200 "Crystal simulated vs reconstructed energy;"
1201 "Esim (GeV);Erec GeV);Event count",
1211 "Crystal no-zs simulated vs reconstructed "
1213 "Esim (GeV);Erec GeV);Event count",
1223 "EE crystal reconstructed energy;E (GeV);"
1229 meEeEMean_ =
bookProfile(ibooker,
"hEeEMean",
"<E_{EE hit}>;event;<E_{hit}> (GeV)", evtMax, .5, evtMax + .5);
1234 "(rec E of crystal without deposited energy);"
1235 "E (GeV);Event count",
1242 "Emulated ouput of ZS FIR filter for EE "
1243 "low interest crystals;"
1252 "Emulated ouput of ZS FIR filter for EE "
1253 "high interest crystals;"
1268 meEeSimE_ =
book1D(ibooker,
"hEeSimE",
"EE hit crystal simulated energy", 100, eeMinE, eeMaxE);
1270 meEeRecEHitXtal_ =
book1D(ibooker,
"hEeRecEHitXtal",
"EE rec energy of hit crystals", 100, eeMinE, eeMaxE);
1274 "EE crystal simulated vs reconstructed energy;"
1275 "Esim (GeV);Erec GeV);Event count",
1285 "EE crystal no-zs simulated vs "
1287 "energy;Esim (GeV);Erec GeV);Event count",
1297 "TTFlags and SR Flags mismatch;"
1298 "iX - 40 / iEta / iX + 20;"
1299 "iY / iPhi (iPhi = 1 at phi = 0 rad);"
1310 "hIncompleteFROMap",
1311 "Incomplete full-readout-flagged readout units;"
1312 "iX - 40 / iEta / iX + 20;"
1313 "iY / iPhi (iPhi = 1 at phi = 0 rad);"
1323 "hIncompleteFROCnt",
1324 "Number of incomplete full-readout-flagged "
1326 "Number of RUs;Event count;",
1332 "hIncompleteFRORateMap",
1333 "Incomplete full-readout-flagged readout units;"
1334 "iX - 40 / iEta / iX + 20;"
1335 "iY / iPhi (iPhi = 1 at phi = 0 rad);"
1336 "Incomplete error rate",
1346 "Dropped full-readout-flagged readout units;"
1347 "iX - 40 / iEta / iX + 20;"
1348 "iY / iPhi (iPhi = 1 at phi = 0 rad);"
1359 "Number of dropped full-readout-flagged "
1360 "RU count;RU count;Event count",
1367 "Number of zero-suppressed-flagged RU fully "
1369 "RU count;Event count",
1375 buf <<
"Number of LI EB channels below the " <<
ebZsThr_ / 4.
1376 <<
" ADC count ZS threshold;"
1377 "Channel count;Event count",
1381 buf <<
"Number of LI EE channels below the " <<
eeZsThr_ / 4.
1382 <<
" ADC count ZS theshold;"
1383 "Channel count;Event count",
1388 "Number of LI channels below the ZS threshold;"
1389 "Channel count;Event count",
1396 "Number of EB channels below the ZS "
1397 "threshold in a LI but fully readout RU;"
1398 "Channel count;Event count;",
1405 "Number EE channels below the ZS threshold"
1406 " in a LI but fully readout RU;"
1407 "Channel count;Event count",
1414 "Number of LI channels below the ZS threshold "
1415 "in a LI but fully readout RU;"
1416 "Channel count;Event count",
1422 "hDroppedFRORateMap",
1423 "Dropped full-readout-flagged readout units"
1424 "iX - 40 / iEta / iX + 20;"
1425 "iY / iPhi (iPhi = 1 at phi = 0 rad);"
1436 "Complete zero-suppressed-flagged readout units;"
1437 "iX - 40 / iEta / iX + 20;"
1438 "iY / iPhi (iPhi = 1 at phi = 0 rad);"
1449 "Complete zero-suppressed-flagged readout units;"
1450 "iX - 40 / iEta / iX + 20;"
1451 "iY / iPhi (iPhi = 1 at phi = 0 rad);"
1452 "Completeness rate",
1468 s << (
s.str().empty() ?
"" :
", ") << *it;
1471 if (!
s.str().empty()) {
1472 LogWarning(
"Configuration") <<
"Parameter 'histList' contains some unknown histogram(s). "
1473 "Check spelling. Following name were not found: "
1483 for (
int iTTFlag(0); iTTFlag < 8; iTTFlag++) {
1484 TTFlagCount[iTTFlag] = 0;
1486 for (
int iTtEta(0); iTtEta <
nTtEta; iTtEta++) {
1487 for (
int iTtPhi(0); iTtPhi <
nTtPhi; iTtPhi++) {
1488 LiTTFlagCount[iTtEta][iTtPhi] = 0;
1489 MiTTFlagCount[iTtEta][iTtPhi] = 0;
1490 HiTTFlagCount[iTtEta][iTtPhi] = 0;
1494 for (
int iEt(0); iEt < 100; iEt++) {
1505 double lsb10bitsEB(ebItr == physMap.end() ? 0. : ebItr->second.EtSat / 1024.);
1507 double lsb10bitsEE(eeItr == physMap.end() ? 0. : eeItr->second.EtSat / 1024.);
1513 unsigned int ADC = it->compressedEt();
1515 double lsb10bits(0.);
1517 lsb10bits = lsb10bitsEB;
1519 lsb10bits = lsb10bitsEE;
1523 uint32_t lutGrp = 999;
1524 if (itgrp != lutGrpMap.end())
1525 lutGrp = itgrp->second;
1528 if (itLut != lutMap.end()) {
1529 const unsigned int* lut = (itLut->second).getLut();
1530 for (
unsigned int i = 0;
i < 1024;
i++)
1531 if (
ADC == (0xff & lut[
i])) {
1537 tpEt = lsb10bits * tpg10bits;
1539 tpEt = it->compressedEt();
1541 int iEta = it->id().ieta();
1543 int iPhi = it->id().iphi();
1545 double etSum =
ttEtSums[iEta0][iPhi0];
1548 if ((iE >= 0) && (iE < 100)) {
1557 ++TTFlagCount[it->ttFlag()];
1558 if ((it->ttFlag() & 0x3) == 0) {
1559 LiTTFlagCount[iEta0][iPhi0] += 1;
1560 }
else if ((it->ttFlag() & 0x3) == 1) {
1561 MiTTFlagCount[iEta0][iPhi0] += 1;
1562 }
else if ((it->ttFlag() & 0x3) == 3) {
1563 HiTTFlagCount[iEta0][iPhi0] += 1;
1565 if ((it->ttFlag() & 0x4)) {
1574 for (
int ittflag(0); ittflag < 8; ittflag++) {
1577 for (
int iTtEta(0); iTtEta <
nTtEta; iTtEta++) {
1578 for (
int iTtPhi(0); iTtPhi <
nTtPhi; iTtPhi++) {
1585 for (
int iE(0); iE < 100; iE++) {
1589 for (
int iE(0); iE < 40; iE++) {
1606 for (
unsigned int digis = 0; digis <
ebDigis_->
size(); ++digis) {
1612 for (
unsigned int digis = 0; digis <
eeDigis_->
size(); ++digis) {
1618 for (
unsigned iDcc0 = 0; iDcc0 <
nDccs_; ++iDcc0) {
1648 template <
class T,
class U>
1651 typedef typename U::key_type RuDetId;
1653 typename U::const_iterator srf = srFlagColl.find(ruId);
1655 bool highInterest =
false;
1658 if (srf != srFlagColl.end()) {
1666 pair<int, int> ch =
dccCh(xtalId);
1696 int iZ0 = static_cast<const EEDetId&>(
frame.id()).
zside() > 0 ? 1 : 0;
1710 if (ch.second < 1 || ch.second > 68) {
1712 <<
"Error in DCC channel retrieval for crystal with detId " << xtalId.
rawId()
1713 <<
"DCC channel out of allowed range [1..68]\n";
1743 static std::atomic<bool> firstCall{
true};
1744 bool expected =
true;
1745 if (firstCall.compare_exchange_strong(expected,
false)) {
1754 double adc2GeV = 0.;
1768 double gainInv[] = {12., 1., 6., 12.};
1770 for (
int i = 0;
i <
n; ++
i) {
1780 throw cms::Exception(
"InvalidParameter") <<
"Wrong type of DetId passed to the "
1781 "EcalSelectiveReadoutValidation::dccCh(const DetId&). "
1782 "An ECAL DetId was expected.\n";
1795 const int oneXtalPhi0 = iTtPhi0 * 5;
1796 const int oneXtalEta0 = (iTtEta0 -
nOneEeTtEta) * 5;
1801 if (detId.
rawId() & 0x8000) {
1812 <<
"Wrong type of DetId passed to the method "
1813 "EcalSelectiveReadoutValidation::dccCh(const DetId&). "
1814 "A valid EcalTriggerTower, EcalBarrel or EcalEndcap DetId was expected. "
1816 << xtalId.
rawId() <<
".\n";
1825 throw cms::Exception(
"OutOfRange") <<
"Got an invalid DCC ID, DCCID = " <<
result.first <<
" for DetId 0x" << hex
1826 << detId.
rawId() <<
" and 0x" << xtalId.
rawId() <<
dec <<
"\n";
1832 throw cms::Exception(
"OutOfRange") <<
"Got an invalid DCC channel ID, DCC_CH = " <<
result.second <<
" for DetId 0x"
1833 << hex << detId.
rawId() <<
" and 0x" << xtalId.
rawId() <<
dec <<
"\n";
1845 int iDCC = EcalElecId.
dccId();
1846 int iDccChan = EcalElecId.
towerId();
1847 const bool ignoreSingle =
true;
1858 if (eeGeometry ==
nullptr || ebGeometry ==
nullptr) {
1866 for (
int iEta0 = 0; iEta0 <
nTtEta; ++iEta0) {
1867 for (
int iPhi0 = 0; iPhi0 <
nTtPhi; ++iPhi0) {
1899 int innerTTEtas[] = {0, 1, 54, 55};
1900 for (
unsigned iRing = 0; iRing <
sizeof(innerTTEtas) /
sizeof(innerTTEtas[0]); ++iRing) {
1901 int iTtEta0 = innerTTEtas[iRing];
1917 for (
unsigned iTtPhi0 = 0; iTtPhi0 <
nTtPhi - 1; iTtPhi0 += 2) {
1932 double weights[] = {0., -1 / 3., -1 / 3., -1 / 3., 0., 1.};
1934 double adc2GeV = 0.;
1941 throw cms::Exception(
"Severe Error") << __FILE__ <<
":" << __LINE__ <<
": "
1942 <<
"this is a bug. Please report it.\n";
1949 double gainInv[] = {12., 1., 6., 12};
1953 if (iframe >= 0 && iframe <
frame.size()) {
2024 MonitorElement*
result = ibook.
bookProfile2D(
name,
title, nbinx,
xmin,
xmax, nbiny,
ymin,
ymax, 0, 0, 0,
option);
2055 log <<
"Avalailable histograms (DQM monitor elements): \n";
2057 log << it->first <<
": " << it->second <<
"\n";
2059 log <<
"\nTo include an histogram add its name in the vstring parameter "
2060 "'histograms' of the EcalSelectiveReadoutValidation module\n";
2064 double ruHeaderPayload = 0.;
2065 const int firstEbDcc0 =
nEeDccs / 2;
2066 for (
int iDcc0 = firstEbDcc0; iDcc0 < firstEbDcc0 +
nEbDccs; ++iDcc0) {
2074 double ruHeaderPayload = 0.;
2075 const unsigned firstEbDcc0 =
nEeDccs / 2;
2076 for (
unsigned iDcc0 = 0; iDcc0 <
nDccs_; ++iDcc0) {
2078 if (iDcc0 == firstEbDcc0)
2088 const std::vector<int>& firWeights,
2091 const int nFIRTaps = 6;
2093 const vector<int>&
w = firWeights;
2097 bool gain12saturated =
false;
2098 const int gain12 = 0x01;
2099 const int lastFIRSample = firstFIRSample + nFIRTaps - 1;
2102 for (
int iSample = firstFIRSample - 1; iSample < lastFIRSample; ++iSample, ++iWeight) {
2103 if (iSample >= 0 && iSample <
frame.size()) {
2105 if (
sample.gainId() != gain12)
2106 gain12saturated =
true;
2107 LogTrace(
"DccFir") << (iSample >= firstFIRSample ?
"+" :
"") <<
sample.adc() <<
"*(" <<
w[iWeight] <<
")";
2108 acc +=
sample.adc() *
w[iWeight];
2111 <<
": Not enough samples in data frame or 'ecalDccZs1stSample' module "
2112 "parameter is not valid...";
2119 acc = (acc >= 0) ? (acc >> 8) : -(-acc >> 8);
2124 LogTrace(
"DccFir") <<
"acc: " << acc <<
"\n"
2125 <<
"saturated: " << (gain12saturated ?
"yes" :
"no") <<
"\n";
2128 *saturated = gain12saturated;
2135 const int nFIRTaps = 6;
2136 vector<int> firWeights(nFIRTaps, 0);
2137 const static int maxWeight = 0xEFF;
2138 for (
unsigned i = 0;
i <
min((
size_t)nFIRTaps, normalizedWeights.size()); ++
i) {
2139 firWeights[
i] = lround(normalizedWeights[
i] * (1 << 10));
2140 if (
abs(firWeights[
i]) > maxWeight) {
2141 firWeights[
i] = firWeights[
i] < 0 ? -maxWeight : maxWeight;
2148 bool notNormalized =
false;
2149 bool notInt =
false;
2150 for (
unsigned i = 0;
i < weightsForZsFIR.size(); ++
i) {
2151 if (weightsForZsFIR[
i] > 1.)
2152 notNormalized =
true;
2153 if ((
int)weightsForZsFIR[
i] != weightsForZsFIR[
i])
2156 if (notInt && notNormalized) {
2157 throw cms::Exception(
"InvalidParameter") <<
"weigtsForZsFIR paramater values are not valid: they "
2158 <<
"must either be integer and uses the hardware representation "
2159 <<
"of the weights or less or equal than 1 and used the normalized "
2160 <<
"representation.";
2163 if (notNormalized) {
2164 firWeights_ = vector<int>(weightsForZsFIR.size());
2165 for (
unsigned i = 0;
i < weightsForZsFIR.size(); ++
i) {
2172 log <<
"Input weights for FIR: ";
2173 for (
unsigned i = 0;
i < weightsForZsFIR.size(); ++
i) {
2174 log << weightsForZsFIR[
i] <<
"\t";
2178 log <<
"\nActual FIR weights: ";
2185 log <<
"\nNormalized FIR weights after hw representation rounding: ";
2198 <<
"' for SRP algorithm result check.\n";
2206 <<
"' for Selective Readout decision application check.\n";
2216 typedef typename T::const_iterator SrFlagCollectionConstIt;
2217 typedef typename T::key_type MyRuDetIdType;
2218 SrFlagCollectionConstIt itSrfFromData = srfFromData.begin();
2219 SrFlagCollectionConstIt itComputedSr = computedSrf.begin();
2221 while (itSrfFromData != srfFromData.end() || itComputedSr != computedSrf.end()) {
2222 MyRuDetIdType inconsistentRu = 0;
2223 bool inconsistent =
false;
2224 if (itComputedSr == computedSrf.end() ||
2225 (itSrfFromData != srfFromData.end() && itSrfFromData->id() < itComputedSr->id())) {
2227 pair<int, int> ch =
dccCh(itSrfFromData->id());
2228 srpAlgoErrorLog_ <<
event.id() <<
": " << itSrfFromData->id() <<
", DCC " << ch.first <<
" ch " << ch.second
2229 <<
" found in data (SRF:" << itSrfFromData->flagName()
2230 <<
") but not in the set of SRFs computed from the data TTF.\n";
2231 inconsistentRu = itSrfFromData->id();
2232 inconsistent =
true;
2234 }
else if (itSrfFromData == srfFromData.end() ||
2235 (itComputedSr != computedSrf.end() && itComputedSr->id() < itSrfFromData->id())) {
2237 pair<int, int> ch =
dccCh(itComputedSr->id());
2239 srpAlgoErrorLog_ <<
event.id() <<
": " << itComputedSr->id() <<
", DCC " << ch.first <<
" ch " << ch.second
2240 <<
" not found in data. Computed SRF: " << itComputedSr->flagName() <<
".\n";
2241 inconsistentRu = itComputedSr->id();
2242 inconsistent =
true;
2247 if (itComputedSr->value() != itSrfFromData->value()) {
2248 pair<int, int> ch =
dccCh(itSrfFromData->id());
2249 srpAlgoErrorLog_ <<
event.id() <<
", " << itSrfFromData->id() <<
", DCC " << ch.first <<
" ch " << ch.second
2250 <<
", SRF inconsistency: "
2251 <<
"from data: " << itSrfFromData->flagName()
2252 <<
", computed from TTF: " << itComputedSr->flagName() <<
"\n";
2253 inconsistentRu = itComputedSr->id();
2254 inconsistent =
true;
2256 if (itComputedSr != computedSrf.end())
2258 if (itSrfFromData != srfFromData.end())
2272 <<
"Argument of EcalSelectiveReadoutValidation::dccId(const EcalTrigTowerDetId&) "
2273 <<
"must be a barrel trigger tower Id\n";
2275 return dccCh(detId).first;
2294 buf <<
"List of DCCs found in the first processed event: ";
2296 for (
unsigned iDcc = 0; iDcc <
nDccs_; ++iDcc) {
2302 buf <<
"\nOnly DCCs from this list will be considered for error logging\n";
2310 typedef typename T::const_iterator SrFlagCollectionConstIt;
2311 typedef typename T::key_type MyRuDetIdType;
2313 for (SrFlagCollectionConstIt itSrf = srfs.begin(); itSrf != srfs.end(); ++itSrf) {
2315 pair<int, int> ru =
dccCh(itSrf->id());
2327 << ru.second <<
") is 'Full readout' "
2328 <<
"while none of its channel was read out\n";
2335 << ru.second <<
") is 'Full readout' "
2337 <<
getCrystalCount(ru.first, ru.second) <<
" channels were read out.\n";
2357 if (iDcc < minDccId_ || iDcc >
maxDccId_) {
2359 }
else if (10 <= iDcc && iDcc <= 45) {
2366 iDccPhi = iDcc - 45;
2367 switch (iDccPhi * 100 + iDccCh) {
edm::ESGetToken< EcalTPGLutIdMap, EcalTPGLutIdMapRcd > lutMapHandle
MonitorElement * meEbRecE_
MonitorElement * meEeRecEHitXtal_
static const double rad2deg
Conversion factor from radian to degree.
MonitorElement * meDccVolFromData_
double getDccSrDependentPayload(int iDcc0, double nReadRus, double nReadXtals) const
int nEeZsErrors_
Counter of EE ZS errors (LI channel below ZS threshold)
void fill(MonitorElement *me, float x)
constexpr int gainId(sample_type sample)
get the gainId (2 bits)
MonitorElement * meL1aRate_
MonitorElement * meTpVsEtSum_
MonitorElement * meEbRecEHitXtal_
void analyzeEE(const edm::Event &event, const edm::EventSetup &es)
MonitorElement * meEeNoise_
int cIndex2iTtEta(int i) const
int iphi() const
get the tower iphi
std::vector< EcalRecHit >::const_iterator const_iterator
int nDroppedFRO_
Counter of FRO-flagged RU dropped from data.
const EcalTrigTowerDetId & id() const override
double getEeEventSize(double nReadXtals) const
double phi
number of sim hits
double getBytesPerCrystal() const
MonitorElement * bookFloat(TString const &name, FUNC onbooking=NOOP())
MonitorElement * meSRFlagsConsistency_
std::map< uint32_t, EcalTPGLut > EcalTPGLutMap
MonitorElement * meDccLiVol_
std::string srpAlgoErrorLogFileName_
void compareSrfColl(const edm::Event &event, T &srfFromData, T &computedSrf)
MonitorElement * meHiTtf_
static const int nEndcaps
number of endcaps
std::map< uint32_t, uint32_t >::const_iterator EcalTPGGroupsMapItr
double getL1aRate() const
MonitorElement * meEbSimE_
boost::transform_iterator< IterHelp, boost::counting_iterator< int > > const_iterator
std::ofstream srpAlgoErrorLog_
Output ascii file for unconsistency on SR flags.
static const int nEeY
EE crystal grid size along Y.
CollHandle< EBDigiCollection > ebDigis_
MonitorElement * meTpMap_
double frame2EnergyForTp(const T &frame, int offset=0) const
MonitorElement * meDccHiVol_
std::set< std::string > histList_
static const int nEeDccs
number of DCCs for EE
int ietaAbs() const
get the absolute value of the tower ieta
MonitorElement * meLiTtf_
const EcalElectronicsMapping * elecMap_
double eta
phi crystal position in degrees
MonitorElement * meTtfVsEtSum_
double ttEtSums[nTtEta][nTtPhi]
unsigned ttId(DetId const &, EcalElectronicsMapping const *)
MonitorElement * bookProfile2D(TString const &name, TString const &title, int nchX, double lowX, double highX, int nchY, double lowY, double highY, double lowZ, double highZ, char const *option="s", FUNC onbooking=NOOP())
std::vector< EcalScDetId > getEcalScDetId(int DCCid, int DCC_Channel, bool ignoreSingleCrystal=true) const
MonitorElement * meEeLiZsFir_
constexpr Detector det() const
get the detector field from this detid
MonitorElement * meDroppedFROCnt_
const EcalTrigTowerConstituentsMap * triggerTowerMap_
void analyzeTP(const edm::Event &event, const edm::EventSetup &es)
MonitorElement * meIncompleteFROMap_
MonitorElement * meEbFullRoCnt_
CollHandle< RecHitCollection > ebRecHits_
virtual void setCurrentFolder(std::string const &fullpath)
MonitorElement * meVolBHI_
int iEta2cIndex(int iEta) const
MonitorElement * meEbRecVsSimE_
MonitorElement * meEbEMean_
MonitorElement * meChOcc_
U second(std::pair< T, U > const &p)
void configFirWeights(const std::vector< double > &weightsForZsFIR)
ConsumesCollector consumesCollector()
Use a ConsumesCollector to gather consumes information from helper functions.
edm::ESGetToken< EcalTrigTowerConstituentsMap, IdealGeometryRecord > hTriggerTowerMap
MonitorElement * meEeEMean_
void checkSrApplication(const edm::Event &event, T &srfs)
bool gain12
eta crystal position
~EcalSelectiveReadoutValidation() override
Destructor.
T getUntrackedParameter(std::string const &, T const &) const
MonitorElement * meDroppedFROMap_
Log< level::Info, false > LogInfo
int dccId() const
get the DCC (Ecal Local DCC value not global one) id
int zside() const
get the z-side of the tower (1/-1)
MonitorElement * meEeHiZsFir_
MonitorElement * meZsErrType1Cnt_
Log< level::Warning, false > LogWarning
CollHandle< EBSrFlagCollection > ebSrFlags_
static const int nEeX
EE crystal grid size along X.
static const double tmax[3]
MonitorElement * bookProfile2D(DQMStore::IBooker &, const std::string &name, const std::string &title, int nbinx, double xmin, double xmax, int nbiny, double ymin, double ymax, const char *option="")
void analyzeDataVolume(const edm::Event &e, const edm::EventSetup &es)
int xtalGraphY(const EEDetId &id) const
unsigned towerId(DetId const &, EcalElectronicsMapping const *)
MonitorElement * meCompleteZSRateMap_
int towerId() const
get the tower id
Sin< T >::type sin(const T &t)
int simHit
energy reconstructed from zero-suppressed digi
edm::ESGetToken< EcalTPGLutGroup, EcalTPGLutGroupRcd > lutGrpHandle
const EcalScDetId & id() const override
MonitorElement * meDroppedFRORateMap_
void anaDigi(const T &frame, const U &srFlagColl)
MonitorElement * meEeZsErrType1Cnt_
void dqmBeginRun(edm::Run const &, edm::EventSetup const &) override
edm::ESGetToken< EcalTPGPhysicsConst, EcalTPGPhysicsConstRcd > physHandle
int iXY2cIndex(int iX) const
double noZsRecE
sim hit energy sum
MonitorElement * meCompleteZSCnt_
std::pair< int, int > dccCh(const DetId &xtalId) const
int iTtPhi2cIndex(int iPhi) const
double getDccOverhead(subdet_t subdet) const
MonitorElement * meEbNoise_
bool gain12
eta crystal position
CollHandle< FEDRawDataCollection > fedRaw_
void dqmEndRun(const edm::Run &r, const edm::EventSetup &c) override
void bookHistograms(DQMStore::IBooker &i, edm::Run const &, edm::EventSetup const &) override
double getEbEventSize(double nReadXtals) const
MonitorElement * meVolELI_
static const int nOneEeTtEta
Number of Trigger Towers in an endcap along Eta.
int getRuCount(int iDcc0) const
int dccId(const EcalScDetId &detId) const
MonitorElement * meMiTtf_
static const int nEbDccs
number of DCCs for EB
MonitorElement * meEbHiZsFir_
EcalElectronicsId getElectronicsId(const DetId &id) const
Get the electronics id for this det id.
int nEbZsErrors_
Counter of EB ZS errors (LI channel below ZS threshold)
MonitorElement * bookProfile(TString const &name, TString const &title, int nchX, double lowX, double highX, int, double lowY, double highY, char const *option="s", FUNC onbooking=NOOP())
MonitorElement * meVolEHI_
void readAllCollections(const edm::Event &e)
Geom::Theta< T > theta() const
MonitorElement * book2D(DQMStore::IBooker &, const std::string &name, const std::string &title, int nxbins, double xmin, double xmax, int nybins, double ymin, double ymax)
double frame2Energy(const EcalDataFrame &frame) const
CollHandle< EESrFlagCollection > eeSrFlags_
EcalSelectiveReadoutValidation(const edm::ParameterSet &ps)
Constructor.
MonitorElement * meEbZsErrCnt_
Ecal readout channel identification [32:20] Unused (so far) [19:13] DCC id [12:6] tower [5:3] strip [...
MonitorElement * meEbLiZsFir_
bool registerHist(const std::string &name, const std::string &title)
int cIndex2iPhi(int i) const
const FEDRawData & FEDData(int fedid) const
retrieve data for fed
void setTtEtSums(const edm::EventSetup &es, const EBDigiCollection &ebDigis, const EEDigiCollection &eeDigis)
constexpr int subdetId() const
get the contents of the subdetector field (not cast into any detector's numbering enum)
double noZsRecE
sim hit energy sum
static const int minDccId_
static const int nEbEta
number of crystals along Eta in EB
std::pair< int, int > getDCCandSC(EcalScDetId id) const
MonitorElement * bookProfile(DQMStore::IBooker &, const std::string &name, const std::string &title, int nbins, double xmin, double xmax)
MonitorElement * meVolLI_
bool isRuComplete_[nDccs_][nDccChs_]
std::vector< int > firWeights_
int iPhi2cIndex(int iPhi) const
MonitorElement * meIncompleteFRORateMap_
CollHandle< RecHitCollection > eeRecHits_
CollHandle< EESrFlagCollection > eeComputedSrFlags_
static const int nTtEta
Number of Trigger Towers along Eta.
int ruGraphX(const EcalScDetId &id) const
static const int maxDccId_
double getDccEventSize(int iDcc0, double nReadXtals) const
static const int nTtPhi
Number of Trigger Towers along Phi.
MonitorElement * meEeNoZsRecVsSimE_
CollHandle< EEDigiCollection > eeDigis_
constexpr int16_t xOffset
const_iterator begin() const
The iterator returned can not safely be used across threads.
ESHandle< T > getHandle(const ESGetToken< T, R > &iToken) const
edm::ESGetToken< CaloGeometry, CaloGeometryRecord > geoToken
std::string outputFile_
Output file for histograms.
virtual TProfile * getTProfile()
MonitorElement * meEbNoZsRecVsSimE_
virtual std::shared_ptr< const CaloCellGeometry > getGeometry(const DetId &id) const
Get the cell geometry of a given detector id. Should return false if not found.
void updateL1aRate(const edm::Event &event)
Log< level::Error, false > LogError
double recE
energy reconstructed from unsuppressed digi
int nCompleteZS_
Counter of ZS-flagged RU fully read out.
MonitorElement * meEbZsErrType1Cnt_
int ieta() const
get the tower ieta
void analyze(edm::Event const &e, edm::EventSetup const &c) override
Analyzes the event.
static int dccZsFIR(const EcalDataFrame &frame, const std::vector< int > &firWeights, int firstFIRSample, bool *saturated=nullptr)
size_t size() const
Lenght of the data buffer in bytes.
bool getData(T &iHolder) const
int nEeFROCnt_
Counter of EE FRO-flagged RUs.
EcalTrigTowerDetId towerOf(const DetId &id) const
Get the tower id for this det id (or null if not known)
MonitorElement * meEeSimE_
bool logSrApplicationErrors_
static const unsigned nDccs_
Total number of DCCs.
MonitorElement * meFullRoRu_
std::map< uint32_t, EcalTPGPhysicsConst::Item > EcalTPGPhysicsConstMap
CollHandle< std::vector< PCaloHit > > eeSimHits_
constexpr uint32_t rawId() const
get the raw id
std::vector< double > weights_
int iTtEta2cIndex(int iEta) const
bool eeRuActive_[nEndcaps][nEeX/scEdge][nEeY/scEdge]
MonitorElement * meZs1Ru_
static const int SRF_FULL
MonitorElement * meEeRecVsSimE_
CollHandle< EBSrFlagCollection > ebComputedSrFlags_
MonitorElement * bookFloat(DQMStore::IBooker &, const std::string &name)
std::vector< bool > logErrForDccs_
energiesEb_t ebEnergies[nEbEta][nEbPhi]
double eta
phi crystal position in degrees
int simHit
energy reconstructed from zero-suppressed digi
MonitorElement * book2D(TString const &name, TString const &title, int nchX, double lowX, double highX, int nchY, double lowY, double highY, FUNC onbooking=NOOP())
static const int scEdge
Number of crystals along a supercrystal edge.
int xtalGraphX(const EEDetId &id) const
void read(const edm::Event &event)
static std::vector< int > getFIRWeights(const std::vector< double > &normalizedWeights)
static const int ebTtEdge
Number of crystals along an EB TT.
void setToken(edm::ConsumesCollector &collector)
MonitorElement * book1D(DQMStore::IBooker &, const std::string &name, const std::string &title, int nbins, double xmin, double xmax)
UseScope< MonitorElementData::Scope::RUN > UseRunScope
static const int nDccRus_[nDccs_]
number of RUs for each DCC
int cIndex2iEta(int i) const
MonitorElement * meIncompleteFROCnt_
std::map< uint32_t, EcalTPGLut >::const_iterator EcalTPGLutMapItr
T getParameter(std::string const &) const
int nEbFROCnt_
Counter of EB FRO-flagged RUs.
static const int kByte_
number of bytes in 1 kByte:
MonitorElement * meZsErrCnt_
CollHandle< std::vector< PCaloHit > > ebSimHits_
int getCrystalCount(int iDcc, int iDccCh)
MonitorElement * meFullRoCnt_
std::ofstream srApplicationErrorLog_
Output ascii file for unconsistency between Xtals and RU Flags.
void printAvailableHists()
std::string srApplicationErrorLogFileName_
int nPerRu_[nDccs_][nDccChs_]
Abs< T >::type abs(const T &t)
MonitorElement * meForcedRu_
MonitorElement * meForcedTtf_
MonitorElement * meDccVol_
int nIncompleteFRO_
Counter of FRO-flagged RU only partial data.
MonitorElement * meVolHI_
CollHandle< EBDigiCollection > ebNoZsDigis_
CollHandle< EEDigiCollection > eeNoZsDigis_
bool ebRuActive_[nEbEta/ebTtEdge][nEbPhi/ebTtEdge]
static const int SRF_FORCED_MASK
MonitorElement * meTtfVsTp_
double phi
number of sim hits
MonitorElement * meEeRecE_
int cIndex2iTtPhi(int i) const
edm::ESGetToken< EcalElectronicsMapping, EcalMappingRcd > ecalmapping
EcalTrigTowerDetId readOutUnitOf(const EBDetId &xtalId) const
std::map< uint32_t, EcalTPGPhysicsConst::Item >::const_iterator EcalTPGPhysicsConstMapIterator
static const int nEbPhi
number of crystals along Phi in EB
MonitorElement * meEeZsErrCnt_
MonitorElement * meCompleteZSMap_
double recE
energy reconstructed from unsuppressed digi
int ruGraphY(const EcalScDetId &id) const
const_iterator end() const
MonitorElement * meEeFullRoCnt_
Geom::Phi< T > phi() const
energiesEe_t eeEnergies[nEndcaps][nEeX][nEeY]
std::map< std::string, std::string > availableHistList_
MonitorElement * book1D(TString const &name, TString const &title, int const nchX, double const lowX, double const highX, FUNC onbooking=NOOP())
std::map< uint32_t, uint32_t > EcalTPGGroupsMap
CollHandle< EcalTrigPrimDigiCollection > tps_
bool verbose_
Verbosity switch.
Namespace of DDCMS conversion namespace.
MonitorElement * meVolBLI_
void analyzeEB(const edm::Event &event, const edm::EventSetup &es)