20 const std::vector<LumiYear>& years)
21 : ieta_shift_(ieta_shift), drdA_(drdA), drdB_(drdB), dosemaps_(dosemaps), years_(years) {
26 for (
auto& year :
years_) {
27 sumlumi += year.intlumi_;
28 year.sumlumi_ = sumlumi;
38 std::vector<std::vector<float>>
result;
41 std::stringstream linestream(
line);
42 std::vector<float> lineresult;
44 while (linestream >> doseval)
45 lineresult.push_back(doseval);
46 result.push_back(lineresult);
58 const auto& dosemap = dosemapIt->second;
59 if (ieta < 0 or ieta >=
int(dosemap.size()))
63 const auto& doserow = dosemap[
ieta];
64 if (lay < 0 or lay >=
int(doserow.size()))
73 if (lb ==
years_.end()
or lb->sumlumi_ < intlumi) {
74 throw cms::Exception(
"ValueError") <<
"HBHEDarkening: insufficient LHC run information provided to simulate "
75 << intlumi <<
"/fb - check the python config" << std::endl;
95 return std::exp(-(intlumiToUse * doseToUse) / decayConst);
106 float response = 1.0;
108 assert(!yearForLumi.empty());
110 for (
const auto& year :
years_) {
112 if (year.year_ == yearForLumi)