41 std::vector<double> vTimingRangeHB =
42 ps.
getUntrackedParameter<std::vector<double>>(
"thresh_timingreflm_HB", std::vector<double>({-70, -10.}));
43 std::vector<double> vTimingRangeHE =
44 ps.
getUntrackedParameter<std::vector<double>>(
"thresh_timingreflm_HE", std::vector<double>({-60., 0.}));
45 std::vector<double> vTimingRangeHO =
46 ps.
getUntrackedParameter<std::vector<double>>(
"thresh_timingreflm_HO", std::vector<double>({-50., 20.}));
47 std::vector<double> vTimingRangeHF =
48 ps.
getUntrackedParameter<std::vector<double>>(
"thresh_timingreflm_HF", std::vector<double>({-50., 20.}));
66 std::vector<uint32_t> vhashVME;
67 std::vector<uint32_t> vhashuTCA;
68 std::vector<uint32_t> vhashC36;
294 "TimingDiff_DigiMinusLaserMon",
303 "LaserMonSumQ_Event",
307 "LaserMonTiming_Event",
311 "TimingDiff_DigiMinusLaserMon",
321 "Timing_DigivsLaserMon",
339 for (std::vector<int>::const_iterator it = vFEDsVME.begin(); it != vFEDsVME.end(); ++it)
342 for (std::vector<int>::const_iterator it = vFEDsuTCA.begin(); it != vFEDsuTCA.end(); ++it) {
457 for (std::vector<HcalGenericDetId>::const_iterator it = dids.begin(); it != dids.end(); ++it) {
458 if (!it->isHcalDetId())
515 for (std::vector<uint32_t>::const_iterator it =
_vhashFEDs.begin(); it !=
_vhashFEDs.end(); ++it) {
521 for (uint32_t iflag = 0; iflag <
_vflags.size(); iflag++)
548 for (std::vector<hcaldqm::flag::Flag>::iterator ft =
_vflags.begin(); ft !=
_vflags.end(); ++ft) {
581 _logger.
dqmthrow(
"QIE10DigiCollection for laserMonDigis isn't available.");
583 std::vector<int> laserMonADC;
589 double peakLaserMonADC = -1;
590 for (
unsigned int iTS = 0; iTS < laserMonADC.size(); ++iTS) {
591 if (laserMonADC[iTS] > peakLaserMonADC) {
592 peakLaserMonADC = laserMonADC[iTS];
597 double laserMonSumQ = 0;
598 double laserMonTiming = 0.;
601 int minTS =
std::max(0, peakTS - 3);
602 int maxTS =
std::min(
int(laserMonADC.size() - 1), peakTS + 3);
603 for (
int iTS = minTS; iTS <=
maxTS; ++iTS) {
605 laserMonSumQ += this_fC;
609 if (laserMonSumQ > 0.) {
610 laserMonTiming = laserMonTiming / laserMonSumQ;
639 double sumQ = hcaldqm::utilities::sumQDB<QIE11DataFrame>(
_dbService, digi_fC, did, digi, 0, digi.
samples() - 1);
644 double aveTS = hcaldqm::utilities::aveTSDB<QIE11DataFrame>(
_dbService, digi_fC, did, digi, 0, digi.samples() - 1);
651 for (
int i = 0;
i < digi.samples();
i++) {
654 eid,
i, hcaldqm::utilities::adc2fCDBMinusPedestal<QIE11DataFrame>(_dbService, digi_fC, did, digi,
i));
660 double digiTimingSOI = (aveTS - digi.presamples()) * 25.;
661 double deltaTiming = digiTimingSOI - laserMonTiming;
680 double sumQ = hcaldqm::utilities::sumQ<HODataFrame>(digi, 8.5, 0, digi.
size() - 1);
686 double aveTS = hcaldqm::utilities::aveTS<HODataFrame>(digi, 8.5, 0, digi.size() - 1);
693 for (
int i = 0;
i < digi.size();
i++) {
701 double digiTimingSOI = (aveTS - digi.presamples()) * 25.;
702 double deltaTiming = digiTimingSOI - laserMonTiming;
728 double sumQ = hcaldqm::utilities::sumQDB<QIE10DataFrame>(
_dbService, digi_fC, did, digi, 0, digi.
samples() - 1);
734 double aveTS = hcaldqm::utilities::aveTSDB<QIE10DataFrame>(
_dbService, digi_fC, did, digi, 0, digi.samples() - 1);
742 for (
int i = 0;
i < digi.samples();
i++) {
745 eid, (
int)
i, hcaldqm::utilities::adc2fCDBMinusPedestal<QIE10DataFrame>(_dbService, digi_fC, did, digi, i));
751 double digiTimingSOI = (aveTS - digi.presamples()) * 25.;
752 double deltaTiming = digiTimingSOI - laserMonTiming;
780 unsigned int digiIndex =
787 if (iLaserMonADC.empty()) {
789 for (
int i = 0;
i < totalNSamples; ++
i) {
790 iLaserMonADC.push_back(-1);
796 iLaserMonADC[totalIndex] = (digi[subindex].ok() ? digi[subindex].adc() : -1);
806 DQTask::endLuminosityBlock(lb, es);
int samples() const
total number of samples in the digi
void initialize(std::string const &folder, hashfunctions::HashType, quantity::Quantity *, quantity::Quantity *, int debug=0) override
DetId detid() const
Get the detector id.
constexpr uint32_t rawId() const
EventNumber_t event() const
hcaldqm::ContainerProf1D _cShapeCut_FEDSlot
T getUntrackedParameter(std::string const &, T const &) const
double aveTS(DIGI const &digi, double ped=0, int i=0, int j=3)
hcaldqm::ContainerProf1D _cSignalvsEvent_SubdetPM
bool _isApplicable(edm::Event const &) override
hcaldqm::ContainerSingle1D _cLaserMonTiming
virtual void initialize(std::string const &folder, hashfunctions::HashType, quantity::Quantity *, quantity::Quantity *qy=new quantity::ValueQuantity(quantity::fN), int debug=0)
EventAuxiliary const & eventAuxiliary() const override
std::vector< hcaldqm::flag::Flag > _vflags
int maxTS(DIGI const &digi, double ped=0)
hcaldqm::ContainerProf2D _cTimingMean_FEDuTCA
boost::transform_iterator< IterHelp, boost::counting_iterator< int > > const_iterator
hcaldqm::ContainerXXX< int > _xNBadTimingRefLM
HcalSubdetector subdet() const
get the subdetector
virtual void book(DQMStore::IBooker &, std::string subsystem="Hcal", std::string aux="")
hcaldqm::ContainerXXX< double > _xSignalSum2
void fill(HcalDetId const &) override
std::pair< uint16_t, uint16_t > fed2crate(int fed)
std::vector< uint32_t > _vhashFEDs
hcaldqm::ContainerXXX< double > _xTimingRefLMSum
bool getByToken(EDGetToken token, Handle< PROD > &result) const
void initialize(HcalElectronicsMap const *, ElectronicsMapType etype=fHcalElectronicsMap)
hcaldqm::ContainerXXX< int > _xEntries
hcaldqm::Container1D _cTimingRMS_Subdet
double _laserMonThreshold
std::vector< T >::const_iterator const_iterator
hcaldqm::ContainerProf1D _cTimingvsEvent_SubdetPM
hcaldqm::ContainerProf2D _cSignalRMS_FEDVME
double _thresh_frac_timingreflm
int bunchCrossing() const
edm::DataFrame::id_type id() const
virtual void initialize(std::string const &folder, quantity::Quantity *, quantity::Quantity *, quantity::Quantity *qz=new quantity::ValueQuantity(quantity::fN), int debug=0)
void book(DQMStore::IBooker &, HcalElectronicsMap const *, std::string subsystem="Hcal", std::string aux="") override
const_iterator begin() const
void _resetMonitors(hcaldqm::UpdateFreq) override
void find(edm::Handle< EcalRecHitCollection > &hits, DetId thisDet, std::vector< EcalRecHitCollection::const_iterator > &hit, bool debug=false)
hcaldqm::ContainerXXX< double > _xSignalSum
hcaldqm::ContainerXXX< double > _xTimingSum
hcaldqm::Container2D _cMissing_depth
void initialize(std::string const &folder, quantity::Quantity *, quantity::Quantity *qy=new quantity::ValueQuantity(quantity::fN), int debug=0) override
hcaldqm::Container2D _cMissing_FEDVME
hcaldqm::ContainerProf2D _cSignalMean_depth
hcaldqm::ContainerSingleProf1D _cLaserMonTiming_LS
hcaldqm::Container1D _cADC_SubdetPM
virtual void book(DQMStore::IBooker &, std::string subsystem="Hcal", std::string aux="")
std::vector< int > getFEDVMEList(HcalElectronicsMap const *)
hcaldqm::Container2D _cSummaryvsLS_FED
uint32_t lookup(DetId const &)
hcaldqm::ContainerProf2D _cTimingRMS_FEDVME
hcaldqm::ContainerProf2D _cTimingDiffLS_SubdetPM
hcaldqm::ContainerProf2D _cSignalMean_FEDVME
hcaldqm::Container1D _cTimingMean_Subdet
void bookHistograms(DQMStore::IBooker &, edm::Run const &, edm::EventSetup const &) override
virtual void fill(uint32_t)
#define DEFINE_FWK_MODULE(type)
hcaldqm::ContainerProf2D _cTimingRMS_FEDuTCA
hcaldqm::ContainerProf2D _cSignalRMS_FEDuTCA
edm::EDGetTokenT< QIE10DigiCollection > _tokLaserMon
std::map< HcalSubdetector, std::pair< double, double > > _thresh_timingreflm
virtual void initialize(std::string const &folder, quantity::Quantity *, quantity::Quantity *qy=new quantity::ValueQuantity(quantity::fN), int debug=0)
void processLaserMon(edm::Handle< QIE10DigiCollection > &col, std::vector< int > &iLaserMonADC)
virtual void setBinContent(int, int, int)
hcaldqm::ContainerProf2D _cTimingDiffEvent_SubdetPM
hcaldqm::ContainerSingleProf1D _cLaserMonSumQ_LS
void dqmthrow(std::string const &msg) const
uint32_t valueUserWord(int iword) const
hcaldqm::filter::HashFilter _filter_uTCA
hcaldqm::ContainerXXX< int > _xNChs
edm::EDGetTokenT< QIE11DigiCollection > _tokQIE11
hcaldqm::ContainerSingleProf1D _cLaserMonTiming_Event
hcaldqm::ContainerProf2D _cTimingMean_FEDVME
virtual void showOverflowX(bool showOverflow)
int size() const
total number of samples in the digi
hcaldqm::ContainerSingle1D _cLaserMonSumQ
uint8_t eventType() const
int const FIBER_uTCA_MIN1
edm::EDGetTokenT< HODigiCollection > _tokHO
DetId detid() const
Get the detector id.
std::vector< HcalGenericDetId > allPrecisionId() const
void endLuminosityBlock(edm::LuminosityBlock const &, edm::EventSetup const &) override
double _thresh_min_lmsumq
virtual void showOverflowY(bool showOverflow)
constexpr int adc(sample_type sample)
get the ADC sample (12 bits)
RunAuxiliary const & runAuxiliary() const override
hcaldqm::ContainerXXX< double > _xTimingRefLMSum2
virtual void showOverflowX(bool showOverflow)
HcalElectronicsMap const * _emap
hcaldqm::ContainerProf1D _cSignalvsBX_SubdetPM
hcaldqm::ContainerSingle2D _cSummaryvsLS
edm::EDGetTokenT< QIE10DigiCollection > _tokQIE10
hcaldqm::Container2D _cMissing_FEDuTCA
void _process(edm::Event const &, edm::EventSetup const &) override
const_iterator end() const
hcaldqm::Container1D _cSignalMean_Subdet
int iphi() const
get the cell iphi
hcaldqm::ContainerProf1D _cSignalvsLS_SubdetPM
hcaldqm::ContainerProf1D _cTimingvsLS_SubdetPM
bool isFEDHBHE(HcalElectronicsId const &)
virtual void book(HcalElectronicsMap const *)
hcaldqm::ContainerProf2D _cSignalMean_FEDuTCA
hcaldqm::Container2D _cTiming_DigivsLaserMon_SubdetPM
virtual void book(DQMStore::IBooker &, HcalElectronicsMap const *, std::string subsystem="Hcal", std::string aux="")
uint8_t const EVENTTYPE_LASER
virtual void initialize(std::string const &folder, hashfunctions::HashType, quantity::Quantity *, quantity::Quantity *, quantity::Quantity *qz=new quantity::ValueQuantity(quantity::fN), int debug=0)
hcaldqm::ContainerProf2D _cTimingMean_depth
void book(DQMStore::IBooker &, std::string subsystem="Hcal", std::string aux="") override
hcaldqm::electronicsmap::ElectronicsMap _ehashmap
edm::InputTag _tagLaserMon
void book(DQMStore::IBooker &, HcalElectronicsMap const *, std::string subsystem="Hcal", std::string aux="") override
example_stream void bookHistograms(DQMStore::IBooker &,@example_stream edm::Run const &,@example_stream edm::EventSetup const &) override
void initialize(std::string const &folder, hashfunctions::HashType, quantity::Quantity *, quantity::Quantity *, quantity::Quantity *qz=new quantity::ValueQuantity(quantity::fEnergy), int debug=0) override
void setBinContent(HcalDetId const &, int) override
const_iterator end() const
std::vector< int > _vLaserMonIPhi
EventID const & id() const
virtual STDTYPE & get(HcalDetId const &)
edm::ESHandle< HcalDbService > _dbService
std::vector< int > getFEDList(HcalElectronicsMap const *)
edm::EDGetTokenT< HcalUMNioDigi > _tokuMN
std::vector< int > getFEDuTCAList(HcalElectronicsMap const *)
hcaldqm::Container1D _cSignalRMS_Subdet
void fill(HcalDetId const &) override
const HcalElectronicsMap * getHcalMapping() const
virtual void initialize(FilterType ftype, hashfunctions::HashType htype, std::vector< uint32_t > const &)
int getRBX(uint32_t iphi)
bool isFEDHO(HcalElectronicsId const &)
std::vector< uint32_t > _vcdaqEids
hcaldqm::ContainerSingleProf1D _cLaserMonSumQ_Event
hcaldqm::ContainerXXX< double > _xTimingSum2
virtual void initialize(hashfunctions::HashType, int debug=0)
void book(DQMStore::IBooker &, HcalElectronicsMap const *, std::string subsystem="Hcal", std::string aux="") override
int samples() const
total number of samples in the digi
hcaldqm::ContainerProf2D _cSignalRMS_depth
hcaldqm::filter::HashFilter _filter_VME
Readout chain identification for Hcal.
hcaldqm::ContainerProf1D _cTimingvsBX_SubdetPM
bool isFEDHF(HcalElectronicsId const &)
LaserTask(edm::ParameterSet const &)
const_iterator begin() const
hcaldqm::ContainerProf2D _cTimingRMS_depth
double sumQ(DIGI const &digi, double ped, int i=0, int j=3)