RecoLocalCalo
HcalRecAlgos
src
HBHENegativeFlag.cc
Go to the documentation of this file.
1
#include "
RecoLocalCalo/HcalRecAlgos/interface/HBHENegativeFlag.h
"
2
#include "
CalibFormats/CaloObjects/interface/CaloSamples.h
"
3
#include "
DataFormats/METReco/interface/HcalCaloFlagLabels.h
"
4
5
void
HBHENegativeFlagSetter::setPulseShapeFlags
(
HBHERecHit
&
hbhe
,
6
const
HBHEDataFrame
&digi,
7
const
HcalCoder
&coder,
8
const
HcalCalibrations
&
calib
) {
9
if
(
filter_
) {
10
CaloSamples
cs
;
11
coder.
adc2fC
(digi,
cs
);
12
const
int
nRead =
cs
.size();
13
14
double
ts[
CaloSamples::MAXSAMPLES
];
15
for
(
int
i
= 0;
i
< nRead;
i
++) {
16
const
int
capid = digi[
i
].capid();
17
ts[
i
] =
cs
[
i
] -
calib
.pedestal(capid);
18
}
19
20
const
bool
passes =
filter_
->
checkPassFilter
(
hbhe
.id(), &ts[0], nRead);
21
if
(!passes)
22
hbhe
.setFlagField(1,
HcalCaloFlagLabels::HBHENegativeNoise
);
23
}
24
}
HcalCaloFlagLabels.h
mps_fire.i
i
Definition:
mps_fire.py:428
CaloSamples::MAXSAMPLES
static const int MAXSAMPLES
Definition:
CaloSamples.h:86
HcalCalibrations
Definition:
HcalCalibrations.h:9
CaloSamples.h
CaloSamples
Definition:
CaloSamples.h:14
HBHERecHit
Definition:
HBHERecHit.h:13
photonIsolationHIProducer_cfi.hbhe
hbhe
Definition:
photonIsolationHIProducer_cfi.py:8
callgraph.cs
cs
Definition:
callgraph.py:102
calib
Definition:
CalibElectron.h:12
HBHENegativeFlagSetter::filter_
const HBHENegativeEFilter * filter_
Definition:
HBHENegativeFlag.h:26
HcalCaloFlagLabels::HBHENegativeNoise
Definition:
HcalCaloFlagLabels.h:26
HcalCoder
Definition:
HcalCoder.h:19
HBHENegativeFlagSetter::setPulseShapeFlags
void setPulseShapeFlags(HBHERecHit &hbhe, const HBHEDataFrame &digi, const HcalCoder &coder, const HcalCalibrations &calib)
Definition:
HBHENegativeFlag.cc:5
HcalCoder::adc2fC
virtual void adc2fC(const HBHEDataFrame &df, CaloSamples &lf) const =0
HBHEDataFrame
Definition:
HBHEDataFrame.h:14
HBHENegativeEFilter::checkPassFilter
bool checkPassFilter(const HcalDetId &id, const double *ts, unsigned lenTS) const
Definition:
HBHENegativeEFilter.cc:76
HBHENegativeFlag.h
Generated for CMSSW Reference Manual by
1.8.14