28 float expectedPedestal,
29 float binPrevToBinMax,
30 float binNextToBinMax,
34 pedestal_(name +
" pedestal", expectedPedestal, 0.),
56 double pedestal_fC = 0.5 * (digi[0].nominal_fC() + digi[1].nominal_fC());
58 double maxAmplitude = digi[
maxBin_].nominal_fC() - pedestal_fC;
61 double binPrevToBinMax = (digi[
maxBin_ - 1].nominal_fC() - pedestal_fC) / maxAmplitude;
64 double binNextToBinMax = (digi[
maxBin_ + 1].nominal_fC() - pedestal_fC) / maxAmplitude;
67 double amplitude = digi[
maxBin_].nominal_fC() + digi[
maxBin_ + 1].nominal_fC() - 2 * pedestal_fC;
100 : hitReadoutName_(
"HcalHits"),
105 hbheHitAnalyzer_(
"HBHEDigi", 1., &simParameterMap_, &hbheFilter_),
106 hoHitAnalyzer_(
"HODigi", 1., &simParameterMap_, &hoFilter_),
107 hfHitAnalyzer_(
"HFDigi", 1., &simParameterMap_, &hfFilter_),
108 zdcHitAnalyzer_(
"ZDCDigi", 1., &simParameterMap_, &zdcFilter_),
109 hbheDigiStatistics_(
"HBHEDigi", 4, 10., 6., 0.1, 0.5, hbheHitAnalyzer_),
110 hoDigiStatistics_(
"HODigi", 4, 10., 6., 0.1, 0.5, hoHitAnalyzer_),
111 hfDigiStatistics_(
"HFDigi", 3, 10., 6., 0.1, 0.5, hfHitAnalyzer_),
112 zdcDigiStatistics_(
"ZDCDigi", 3, 10., 6., 0.1, 0.5, zdcHitAnalyzer_),
113 hbheDigiCollectionTag_(conf.getParameter<edm::
InputTag>(
"hbheDigiCollectionTag")),
114 hoDigiCollectionTag_(conf.getParameter<edm::
InputTag>(
"hoDigiCollectionTag")),
115 hfDigiCollectionTag_(conf.getParameter<edm::
InputTag>(
"hfDigiCollectionTag")) {}
117 namespace HcalDigiAnalyzerImpl {
118 template <
class Collection>
122 for (
unsigned i = 0;
i < digis->size(); ++
i) {
const edm::EventSetup & c
edm::InputTag hfDigiCollectionTag_
void analyze(int detId, double recEnergy)
to be called for each RecHit
CaloValidationStatistics pedestal_
CaloHitAnalyzer hoHitAnalyzer_
float amplitudeThreshold_
constexpr unsigned int maxBin
#define DEFINE_FWK_MODULE(type)
CaloValidationStatistics binPrevToBinMax_
HcalDigiAnalyzer(edm::ParameterSet const &conf)
HcalDigiStatistics hfDigiStatistics_
HcalDigiStatistics hoDigiStatistics_
edm::InputTag hbheDigiCollectionTag_
CaloHitAnalyzer hfHitAnalyzer_
CaloHitAnalyzer zdcHitAnalyzer_
CaloHitAnalyzer hbheHitAnalyzer_
HcalDigiStatistics zdcDigiStatistics_
edm::InputTag hoDigiCollectionTag_
void fillHits(MixCollection< PCaloHit > &hits)
should be called each event
HBHEHitFilter hbheFilter_
CaloValidationStatistics binNextToBinMax_
bool getByLabel(InputTag const &tag, Handle< PROD > &result) const
void analyze(const Digi &digi)
HcalDigiStatistics hbheDigiStatistics_
T const * product() const
void addEntry(float value, float weight=1.)
void analyze(edm::Event const &e, HcalDigiStatistics &statistics, edm::InputTag &tag)
CaloHitAnalyzer & amplitudeAnalyzer_
HcalSimParameterMap simParameterMap_
void analyze(edm::Event const &e, edm::EventSetup const &c) override
HcalDigiStatistics(std::string name, int maxBin, float amplitudeThreshold, float expectedPedestal, float binPrevToBinMax, float binNextToBinMax, CaloHitAnalyzer &litudeAnalyzer)
std::string hitReadoutName_
uint16_t *__restrict__ uint16_t const *__restrict__ adc