File indexing completed on 2024-04-06 11:58:39
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016
0017
0018 #include "FWCore/Framework/interface/Frameworkfwd.h"
0019 #include "DQMServices/Core/interface/DQMEDAnalyzer.h"
0020 #include "DQMServices/Core/interface/DQMStore.h"
0021
0022 #include "FWCore/Framework/interface/Event.h"
0023 #include "FWCore/Framework/interface/MakerMacros.h"
0024
0025 #include "FWCore/ParameterSet/interface/ParameterSet.h"
0026 #include "CondFormats/EcalObjects/interface/EcalPedestals.h"
0027 #include "CondFormats/DataRecord/interface/EcalPedestalsRcd.h"
0028 #include "DataFormats/EcalDigi/interface/EcalDigiCollections.h"
0029 #include "DataFormats/TCDS/interface/BSTRecord.h"
0030 #include "DataFormats/TCDS/interface/TCDSRecord.h"
0031
0032
0033
0034
0035 class ECALpedestalPCLworker : public DQMEDAnalyzer {
0036 public:
0037 explicit ECALpedestalPCLworker(const edm::ParameterSet &);
0038
0039 static void fillDescriptions(edm::ConfigurationDescriptions &descriptions);
0040
0041 private:
0042 void bookHistograms(DQMStore::IBooker &, edm::Run const &, edm::EventSetup const &) override;
0043 void analyze(const edm::Event &, const edm::EventSetup &) override;
0044
0045 edm::EDGetTokenT<EBDigiCollection> digiTokenEB_;
0046 edm::EDGetTokenT<EEDigiCollection> digiTokenEE_;
0047 edm::EDGetTokenT<TCDSRecord> tcdsToken_;
0048 const edm::ESGetToken<EcalPedestals, EcalPedestalsRcd> pedestalToken_;
0049
0050 std::vector<MonitorElement *> meEB_;
0051 std::vector<MonitorElement *> meEE_;
0052
0053 uint32_t pedestalSamples_;
0054 bool checkSignal_;
0055 uint32_t sThresholdEB_;
0056
0057
0058 uint32_t sThresholdEE_;
0059
0060 bool dynamicBooking_;
0061 int fixedBookingCenterBin_;
0062 int nBins_;
0063 std::string dqmDir_;
0064
0065 bool requireStableBeam_;
0066
0067
0068 static bool adc_compare(uint16_t a, uint16_t b) { return (a & 0xFFF) < (b & 0xFFF); }
0069 };