19 _mapDetIdNoise.clear();
28 std::vector<float> vnoise;
33 std::vector<std::string> words;
36 while (getline(_infile1, buff,
'\n')) {
43 ss >> chname >> rpcdetid;
47 while ((pos = buff.find(
" ", pos)) != string::npos) {
48 words.push_back(buff.substr(prev_pos, pos - prev_pos));
51 words.push_back(buff.substr(prev_pos, pos - prev_pos));
53 for (
unsigned int i = 2;
i < words.size(); ++
i) {
54 float value = atof(((words)[
i]).c_str());
55 vnoise.push_back(value);
58 _mapDetIdNoise.insert(make_pair(static_cast<uint32_t>(rpcdetid), vnoise));
69 std::vector<float> veff;
72 while (getline(*_infile2, buff,
'\n')) {
79 ss >> chname >> rpcdetid;
82 while ((pos = buff.find(
" ", pos)) != string::npos) {
83 words.push_back(buff.substr(prev_pos, pos - prev_pos));
86 words.push_back(buff.substr(prev_pos, pos - prev_pos));
88 for (
unsigned int i = 2;
i < words.size(); ++
i) {
89 float value = atof(((words)[
i]).c_str());
90 veff.push_back(value);
92 _mapDetIdEff.insert(make_pair(static_cast<uint32_t>(rpcdetid), veff));
101 uint32_t detUnit = 0;
103 while (!_infile3->eof()) {
104 *_infile3 >> detUnit >> timing;
117 unsigned int row = 1;
118 std::vector<double> sum_clsize;
120 while (*_infile4 >> buffer) {
121 const char* buffer1 = buffer.c_str();
122 double dato = atof(buffer1);
124 sum_clsize.push_back(sum);
126 if (counter == row * 20) {
127 _clsMap[row] = sum_clsize;
138 map<uint32_t, std::vector<float> >::iterator iter = _mapDetIdNoise.find(
id);
139 return (iter->second);
143 map<uint32_t, std::vector<float> >::iterator iter = _mapDetIdEff.find(
id);
149 std::map<RPCDetId, float>::iterator iter = _bxmap.find(rpcid);
std::vector< float > getNoise(uint32_t id)
std::vector< float > getEff(uint32_t id)
float getTime(uint32_t id)
T getParameter(std::string const &) const
static std::atomic< unsigned int > counter
std::map< int, std::vector< double > > getClsMap()
std::string fullPath() const
RPCDBSimSetUp(const edm::ParameterSet &ps)