20 const std::vector<LumiYear>& years)
21 : ieta_shift_(ieta_shift), drdA_(drdA), drdB_(drdB), dosemaps_(dosemaps), years_(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()))
74 throw cms::Exception(
"ValueError") <<
"HBHEDarkening: insufficient LHC run information provided to simulate " 75 <<
intlumi <<
"/fb - check the python config" << std::endl;
90 float intlumiToUse =
year.intlumi_;
95 return std::exp(-(intlumiToUse * doseToUse) / decayConst);
106 float response = 1.0;
108 assert(!yearForLumi.empty());
112 if (
year.year_ == yearForLumi)
HBHEDarkening(int ieta_shift, float drdA, float drdB, const std::map< int, std::vector< std::vector< float >>> &dosemaps, const std::vector< LumiYear > &years)
float degradation(float intlumi, int ieta, int lay) const
std::string getYearForLumi(float intlumi) const
float degradationYear(const LumiYear &year, float intlumi, int ieta, int lay) const
std::map< int, std::vector< std::vector< float > > > dosemaps_
static std::vector< std::vector< float > > readDoseMap(const std::string &fullpath)
The Signals That Services Can Subscribe To This is based on ActivityRegistry and is current per Services can connect to the signals distributed by the ActivityRegistry in order to monitor the activity of the application Each possible callback has some defined which we here list in angle e< void, edm::EventID const &, edm::Timestamp const & > We also list in braces which AR_WATCH_USING_METHOD_ is used for those or
Abs< T >::type abs(const T &t)
std::vector< LumiYear > years_
float dose(int ieta, int lay, int energy) const
Power< A, B >::type pow(const A &a, const B &b)