CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
HcalHardcodeParameters.cc
Go to the documentation of this file.
2 
4  double pedestalWidth,
5  const std::vector<double>& gain,
6  const std::vector<double>& gainWidth,
7  int zsThreshold,
8  int qieType,
9  const std::vector<double>& qieOffset,
10  const std::vector<double>& qieSlope,
11  int mcShape,
12  int recoShape,
13  double photoelectronsToAnalog,
14  const std::vector<double>& darkCurrent,
15  const std::vector<double>& noiseCorrelation)
16  : pedestal_(pedestal),
17  pedestalWidth_(pedestalWidth),
18  gain_(gain),
19  gainWidth_(gainWidth),
20  zsThreshold_(zsThreshold),
21  qieType_(qieType),
22  qieOffset_(qieOffset),
23  qieSlope_(qieSlope),
24  mcShape_(mcShape),
25  recoShape_(recoShape),
26  photoelectronsToAnalog_(photoelectronsToAnalog),
27  darkCurrent_(darkCurrent),
28  noiseCorrelation_(noiseCorrelation),
29  doSipmRadiationDamage_(false) {}
30 
32  : pedestal_(p.getParameter<double>("pedestal")),
33  pedestalWidth_(p.getParameter<double>("pedestalWidth")),
34  gain_(p.getParameter<std::vector<double>>("gain")),
35  gainWidth_(p.getParameter<std::vector<double>>("gainWidth")),
36  zsThreshold_(p.getParameter<int>("zsThreshold")),
37  qieType_(p.getParameter<int>("qieType")),
38  qieOffset_(p.getParameter<std::vector<double>>("qieOffset")),
39  qieSlope_(p.getParameter<std::vector<double>>("qieSlope")),
40  mcShape_(p.getParameter<int>("mcShape")),
41  recoShape_(p.getParameter<int>("recoShape")),
42  photoelectronsToAnalog_(p.getParameter<double>("photoelectronsToAnalog")),
43  darkCurrent_(p.getParameter<std::vector<double>>("darkCurrent")),
44  noiseCorrelation_(p.getParameter<std::vector<double>>("noiseCorrelation")),
45  doSipmRadiationDamage_(p.getParameter<bool>("doRadiationDamage")) {
48 }
49 
50 const double HcalHardcodeParameters::darkCurrent(unsigned index, double intlumi) const {
51  if (doSipmRadiationDamage_ and intlumi > 0)
52  return sipmRadiationDamage_.getDarkCurrent(intlumi, index);
53  return darkCurrent_.at(index);
54 }
55 
56 const double HcalHardcodeParameters::noiseCorrelation(unsigned index) const { return noiseCorrelation_.at(index); }
const double noiseCorrelation(unsigned index) const
HcalSiPMRadiationDamage sipmRadiationDamage_
std::vector< double > noiseCorrelation_
std::vector< double > darkCurrent_
double getDarkCurrent(double intlumi, unsigned index) const
T getParameter(std::string const &) const
Definition: ParameterSet.h:303
const double darkCurrent(unsigned index, double intlumi) const
static const char gain_[]