CMS 3D CMS Logo

EcalSRCondTools.cc
Go to the documentation of this file.
1 //emacs settings:-*- mode: c++; c-basic-offset: 2; indent-tabs-mode: nil -*-
2 /*
3  *
4  * author: Ph Gras. June, 2010
5  */
6 
8 
14 
19 
20 #include <string>
21 #include <fstream>
22 #include <iostream>
23 #include <algorithm>
24 
25 constexpr int tccNum[12][12] = {
26  /* EE- */
27  {36, 19, 20, 21, 22, 23, 18, 1, 2, 3, 4, 5}, //SRP 1
28  {24, 25, 26, 27, 28, 29, 6, 7, 8, 9, 10, 11}, //SRP 2
29  {30, 31, 32, 33, 34, 35, 12, 13, 14, 15, 16, 17}, //SRP 3
30  /* EB- */
31  {54, 37, 38, 39, 40, 41, -1, -1, -1, -1, -1, -1}, //SRP 4
32  {42, 43, 44, 45, 46, 47, -1, -1, -1, -1, -1, -1}, //SRP 5
33  {48, 49, 50, 51, 52, 53, -1, -1, -1, -1, -1, -1}, //SRP 6
34  /* EB+ */
35  {72, 55, 56, 57, 58, 59, -1, -1, -1, -1, -1, -1}, //SRP 7
36  {60, 61, 62, 63, 64, 65, -1, -1, -1, -1, -1, -1}, //SRP 8
37  {66, 67, 68, 69, 70, 71, -1, -1, -1, -1, -1, -1}, //SRP 9
38  /* EE+ */
39  {90, 73, 74, 75, 76, 77, 108, 91, 92, 93, 94, 95}, //SRP 10
40  {78, 79, 80, 81, 82, 83, 96, 97, 98, 99, 100, 101}, //SRP 11
41  {84, 85, 86, 87, 88, 89, 102, 103, 104, 105, 106, 107} //SRP 12
42 };
43 
44 constexpr int dccNum[12][12] = {
45  {1, 2, 3, -1, -1, -1, -1, -1, -1, -1, -1, -1}, //SRP 1
46  {4, 5, 6, -1, -1, -1, -1, -1, -1, -1, -1, -1}, //SRP 2
47  {7, 8, 9, -1, -1, -1, -1, -1, -1, -1, -1, -1}, //SRP 3
48  {10, 11, 12, 13, 14, 15, -1, -1, -1, -1, -1, -1}, //SRP 4
49  {16, 17, 18, 19, 20, 21, -1, -1, -1, -1, -1, -1}, //SRP 5
50  {22, 23, 24, 25, 26, 27, -1, -1, -1, -1, -1, -1}, //SRP 6
51  {28, 29, 30, 31, 32, 33, -1, -1, -1, -1, -1, -1}, //SRP 7
52  {34, 35, 36, 37, 38, 39, -1, -1, -1, -1, -1, -1}, //SRP 8
53  {40, 41, 42, 43, 44, 45, -1, -1, -1, -1, -1, -1}, //SRP 9
54  {46, 47, 48, -1, -1, -1, -1, -1, -1, -1, -1, -1}, //SRP 10
55  {49, 50, 51, -1, -1, -1, -1, -1, -1, -1, -1, -1}, //SRP 11
56  {52, 53, 54, -1, -1, -1, -1, -1, -1, -1, -1, -1} //SRP 12
57 };
58 
59 using namespace std;
60 
62 
64 
66  if (done_)
67  return;
69 
70  string mode = ps_.getParameter<string>("mode");
71 
72  bool iomode_write = true;
73  if (mode == "online_config" || mode == "combine_config") {
74  string fname = ps_.getParameter<string>("onlineSrpConfigFile");
75  ifstream f(fname.c_str());
76  if (!f.good()) {
77  throw cms::Exception("EcalSRCondTools") << "Failed to open file " << fname;
78  }
79  importSrpConfigFile(*sr, f, true);
80  }
81 
82  if (mode == "python_config" || mode == "combine_config") {
83  importParameterSet(*sr, ps_);
84  }
85 
86  if (mode == "read") {
87  iomode_write = false;
88  }
89 
90  if (!(mode == "python_config" || mode == "online_config" || mode == "combine_config" || (mode == "read"))) {
91  throw cms::Exception("Config") << "Invalid value," << mode << ", for parameter mode. "
92  << "Valid values: online_config, python_config, combine_config, read";
93  }
94 
95  if (iomode_write) {
96  sr->bxGlobalOffset_ = ps_.getParameter<int>("bxGlobalOffset");
97  sr->automaticSrpSelect_ = ps_.getParameter<int>("automaticSrpSelect");
98  sr->automaticMasks_ = ps_.getParameter<int>("automaticMasks");
99 
101  if (!db.isAvailable()) {
102  throw cms::Exception("CondDBAccess") << "Failed to connect to PoolDBOutputService\n";
103  }
104  //fillup DB
105  //create new infinite IOV
106  cond::Time_t firstSinceTime = db->beginOfTime();
107  db->writeOne(sr, firstSinceTime, "EcalSRSettingsRcd");
108  done_ = true;
109  } else { //read mode
111  es.get<EcalSRSettingsRcd>().get(hSr);
112  if (!hSr.isValid()) {
113  cout << "EcalSRSettings record not found. Check the Cond DB Global tag.\n";
114  } else {
115  const EcalSRSettings* ssr = hSr.product();
116  cout << "ECAL Seletive readout settings:\n";
117  cout << *ssr << "\n" << endl;
118  }
119 
120  //trigger tower thresholds (from FENIX configuration):
122  es.get<EcalTPGPhysicsConstRcd>().get(hTp);
123  if (!hTp.isValid()) {
124  cout << "EcalTPGPhysicsConst record not found. Check the Cond DB Global tag.\n";
125  } else {
126  const EcalTPGPhysicsConst* tp = hTp.product();
127  const EcalTPGPhysicsConstMap& mymap = tp->getMap();
128  if (mymap.size() != 2) {
129  cout << "Error: TPG physics record is of unexpected size: " << mymap.size()
130  << " elements instead of two (one for EB, one for EE)\n";
131  } else {
132  EcalTPGPhysicsConstMap::const_iterator it = mymap.begin();
133  cout << "----------------------------------------------------------------------\n"
134  "Trigger tower Et thresholds extracted from TPG configuration \n"
135  "(EcalSRCondTools modules supports only read mode for these parameters):\n\n";
136  cout << "EB: "
137  << "LT = " << it->second.ttf_threshold_Low << " GeV "
138  << "HT = " << it->second.ttf_threshold_High << " GeV\n";
139  ++it;
140  cout << "EE: "
141  << "LT = " << it->second.ttf_threshold_Low << " GeV "
142  << "HT = " << it->second.ttf_threshold_High << " GeV\n";
143  }
144  }
145  }
146  delete sr;
147 }
148 
150  sr.deltaPhi_.resize(1);
151  sr.deltaPhi_[0] = ps.getParameter<int>("deltaPhi");
152  sr.deltaEta_.resize(1);
153  sr.deltaEta_[0] = ps.getParameter<int>("deltaEta");
154  sr.ecalDccZs1stSample_.resize(1);
155  sr.ecalDccZs1stSample_[0] = ps.getParameter<int>("ecalDccZs1stSample");
156  sr.ebDccAdcToGeV_ = ps.getParameter<double>("ebDccAdcToGeV");
157  sr.eeDccAdcToGeV_ = ps.getParameter<double>("eeDccAdcToGeV");
158  sr.dccNormalizedWeights_.resize(1);
159  const std::vector<double>& w = ps.getParameter<std::vector<double> >("dccNormalizedWeights");
160  sr.dccNormalizedWeights_[0].resize(w.size());
161  std::copy(w.begin(), w.end(), sr.dccNormalizedWeights_[0].begin());
162  sr.symetricZS_.resize(1);
163  sr.symetricZS_[0] = ps.getParameter<bool>("symetricZS");
164  sr.srpLowInterestChannelZS_.resize(2);
165  const int eb = 0;
166  const int ee = 1;
167  sr.srpLowInterestChannelZS_[eb] = ps.getParameter<double>("srpBarrelLowInterestChannelZS");
168  sr.srpLowInterestChannelZS_[ee] = ps.getParameter<double>("srpEndcapLowInterestChannelZS");
169  sr.srpHighInterestChannelZS_.resize(2);
170  sr.srpHighInterestChannelZS_[eb] = ps.getParameter<double>("srpBarrelHighInterestChannelZS");
171  sr.srpHighInterestChannelZS_[ee] = ps.getParameter<double>("srpEndcapHighInterestChannelZS");
172  //sr.trigPrimBypass_.resize(1);
173  //sr.trigPrimBypass_[0] = ps.getParameter<bool >("trigPrimBypass");
174  //sr.trigPrimBypassMode_.resize(1);
175  //sr.trigPrimBypassMode_[0] = ps.getParameter<int >("trigPrimBypassMode");
176  //sr.trigPrimBypassLTH_.resize(1);
177  //sr.trigPrimBypassLTH_[0] = ps.getParameter<double >("trigPrimBypassLTH");
178  //sr.trigPrimBypassHTH_.resize(1);
179  //sr.trigPrimBypassHTH_[0] = ps.getParameter<double >("trigPrimBypassHTH");
180  //sr.trigPrimBypassWithPeakFinder_.resize(1);
181  //sr.trigPrimBypassWithPeakFinder_[0] = ps.getParameter<bool >("trigPrimBypassWithPeakFinder");
182  //sr.defaultTtf_.resize(1);
183  //sr.defaultTtf_[0] = ps.getParameter<int >("defaultTtf");
184  sr.actions_ = ps.getParameter<std::vector<int> >("actions");
185 }
186 
187 void EcalSRCondTools::importSrpConfigFile(EcalSRSettings& sr, std::istream& f, bool d) {
188  //initialize vectors:
189  sr.deltaEta_ = vector<int>(1, 0);
190  sr.deltaPhi_ = vector<int>(1, 0);
191  sr.actions_ = vector<int>(4, 0);
192  sr.tccMasksFromConfig_ = vector<short>(EcalSRSettings::nTccs_, 0);
193  sr.srpMasksFromConfig_ = vector<vector<short> >(EcalSRSettings::nSrps_, vector<short>(8, 0));
194  sr.dccMasks_ = vector<short>(EcalSRSettings::nDccs_);
195  sr.srfMasks_ = vector<short>(EcalSRSettings::nDccs_);
196  sr.substitutionSrfs_ = vector<vector<short> >(EcalSRSettings::nSrps_, vector<short>(68, 0));
197  sr.testerTccEmuSrpIds_ = vector<int>(EcalSRSettings::nSrps_, 0);
198  sr.testerSrpEmuSrpIds_ = vector<int>(EcalSRSettings::nSrps_, 0);
199  sr.testerDccTestSrpIds_ = vector<int>(EcalSRSettings::nSrps_, 0);
200  sr.testerSrpTestSrpIds_ = vector<int>(EcalSRSettings::nSrps_, 0);
201  sr.bxOffsets_ = vector<short>(EcalSRSettings::nSrps_, 0);
202  sr.automaticMasks_ = 0;
203  sr.automaticSrpSelect_ = 0;
204 
205  //string line;
206  int iLine = 0;
207  int iValueSet = -1;
208  const int nValueSets = 6 * EcalSRSettings::nSrps_ + 9;
209  string line;
210  stringstream sErr("");
211  while (!f.eof() && sErr.str().empty()) {
212  getline(f, line);
213  ++iLine;
214  line = trim(line);
215  if (line[0] == '#' || line.empty()) { //comment line and empty line to ignore
216  continue;
217  } else {
218  ++iValueSet;
219  }
220  if (iValueSet >= nValueSets)
221  break;
222  uint32_t value;
223  string sValue;
224  int pos = 0;
225  int iCh = 0;
226  int nChs[nValueSets] = {
227  //TCC masks: 0-11
228  12,
229  12,
230  12,
231  12,
232  12,
233  12,
234  12,
235  12,
236  12,
237  12,
238  12,
239  12,
240  //SRP masks: 12-23
241  8,
242  8,
243  8,
244  8,
245  8,
246  8,
247  8,
248  8,
249  8,
250  8,
251  8,
252  8,
253  //DCC masks: 24-35
254  12,
255  12,
256  12,
257  12,
258  12,
259  12,
260  12,
261  12,
262  12,
263  12,
264  12,
265  12,
266  //SRF Masks: 36-47
267  6,
268  6,
269  6,
270  6,
271  6,
272  6,
273  6,
274  6,
275  6,
276  6,
277  6,
278  6,
279  //substitution SRFs: 48-59
280  68,
281  68,
282  68,
283  68,
284  68,
285  68,
286  68,
287  68,
288  68,
289  68,
290  68,
291  68,
292  //Tester card to emulate or test: 60-71
293  4,
294  4,
295  4,
296  4,
297  4,
298  4,
299  4,
300  4,
301  4,
302  4,
303  4,
304  4,
305  //Bx offsets: 72
306  12,
307  //algo type: 73
308  1,
309  //action flags: 74
310  4,
311  //pattern file directory: 75
312  1,
313  //VME slots: 76
314  12,
315  //card types: 77
316  12,
317  //config Mode
318  1,
319  //VME Interface card
320  1,
321  //Spy Mode
322  12,
323  };
324 
325  while (((sValue = tokenize(line, " \t", pos)) != string("")) && (iCh < nChs[iValueSet]) && sErr.str().empty()) {
326  value = strtoul(sValue.c_str(), nullptr, 0);
327  const int iSrp = iValueSet % EcalSRSettings::nSrps_;
328  if (iValueSet < 12) { //TCC
329  assert((unsigned)iSrp < sizeof(tccNum) / sizeof(tccNum[0]));
330  assert((unsigned)iCh < sizeof(tccNum[0]) / sizeof(tccNum[0][0]));
331  int tcc = tccNum[iSrp][iCh];
332  if (tcc >= 0) {
333  if (d)
334  cout << "tccMasksFromConfig_[" << tcc << "] <- " << value << "\n";
335  sr.tccMasksFromConfig_[tcc - 1] = value;
336  }
337  } else if (iValueSet < 24) { //SRP-SRP
338  if (d)
339  cout << "srpMasks_[" << iSrp << "][" << iCh << "] <- " << value << "\n";
340  sr.srpMasksFromConfig_[iSrp][iCh] = value;
341  } else if (iValueSet < 36) { //DCC output
342  assert((unsigned)iSrp < sizeof(dccNum) / sizeof(dccNum[0]));
343  assert((unsigned)iCh < sizeof(dccNum[0]) / sizeof(dccNum[0][0]));
344  int dcc = dccNum[iSrp][iCh];
345  if (dcc > 0) {
346  assert((unsigned)(dcc - 1) < sr.dccMasks_.size());
347  if (d)
348  cout << "dccMasks_[" << (dcc - 1) << "] <- " << value << "\n";
349  sr.dccMasks_[dcc - 1] = value;
350  }
351  } else if (iValueSet < 48) { //SRF masks
352  assert((unsigned)iSrp < sizeof(dccNum) / sizeof(dccNum[0]));
353  assert((unsigned)iCh < sizeof(dccNum[0]) / sizeof(dccNum[0][0]));
354  int dcc = dccNum[iSrp][iCh];
355  if (dcc > 0) {
356  if (d)
357  cout << "srfMasks_[" << (dcc - 1) << "] <- " << value << "\n";
358  assert((unsigned)(dcc - 1) < sr.srfMasks_.size());
359  sr.srfMasks_[dcc - 1] = value;
360  }
361  } else if (iValueSet < 60) { //substiution SRFs
362  assert((unsigned)iSrp < sr.substitutionSrfs_.size());
363  assert((unsigned)iCh < sr.substitutionSrfs_[0].size());
364  if (d)
365  cout << "substitutionMasks_[" << iSrp << "][" << iCh << "] <- " << value << "\n";
366  sr.substitutionSrfs_[iSrp][iCh] = value;
367  } else if (iValueSet < 72) { //Tester card config
368  switch (iCh) {
369  case 0:
370  assert((unsigned)iSrp < sr.testerTccEmuSrpIds_.size());
371  if (d)
372  cout << "testerTccEmuSrpIds_[" << iSrp << "] <- " << value << "\n";
373  sr.testerTccEmuSrpIds_[iSrp] = value;
374  break;
375  case 1:
376  assert((unsigned)iSrp < sr.testerSrpEmuSrpIds_.size());
377  if (d)
378  cout << "testerSrpEmuSrpIds_[" << iSrp << "] <- " << value << "\n";
379  sr.testerSrpEmuSrpIds_[iSrp] = value;
380  break;
381  case 2:
382  assert((unsigned)iSrp < sr.testerDccTestSrpIds_.size());
383  if (d)
384  cout << "testerDccTestSrpIds_[" << iSrp << "] <- " << value << "\n";
385  sr.testerDccTestSrpIds_[iSrp] = value;
386  break;
387  case 3:
388  assert((unsigned)iSrp < sr.testerSrpTestSrpIds_.size());
389  if (d)
390  cout << "testerSrpTestSrpIds_[" << iSrp << "] <- " << value << "\n";
391  sr.testerSrpTestSrpIds_[iSrp] = value;
392  break;
393  default:
394  sErr << "Syntax error in SRP system configuration "
395  << " line " << iLine << ".";
396  }
397  } else if (iValueSet < 73) { //bx offsets
398  assert((unsigned)iCh < sr.bxOffsets_.size());
399  if (d)
400  cout << "bxOffset_[" << iCh << "] <- " << value << "\n";
401  sr.bxOffsets_[iCh] = value;
402  } else if (iValueSet < 74) { //algo type
403  int algo = value;
404  switch (algo) {
405  case 0:
406  sr.deltaEta_[0] = sr.deltaPhi_[0] = 1;
407  break;
408  case 1:
409  sr.deltaEta_[0] = sr.deltaPhi_[0] = 2;
410  break;
411  default:
412  throw cms::Exception("OutOfRange")
413  << "Value of parameter algo ," << algo << ", is invalid. Valid values are 0 and 1.";
414  }
415  if (d)
416  cout << "deltaEta_[0] <- " << sr.deltaEta_[0] << "\t"
417  << "deltaPhi_[0] <- " << sr.deltaPhi_[0] << "\n";
418  } else if (iValueSet < 75) { //action flags
419  assert((unsigned)iCh < sr.actions_.size());
420  if (d)
421  cout << "actions_[" << iCh << "] <- " << value << "\n";
422  sr.actions_[iCh] = value;
423  } else if (iValueSet < 76) { //pattern file directory
424  // emuDir_ = sValue;
425  // if(d) cout << "emuDir_ <= "
426  // << value << "\n";
427  } else if (iValueSet < 77) { //VME slots
428  // slotIds_[iCh] = value;
429  // if(d) cout << "slotIds_[" << iCh << "] <= "
430  // << value << "\n";
431  } else if (iValueSet < 78) { //card types
432  // cardTypes_[iCh] = sValue[0];
433  // if(d) cout << "cardTypes_[" << iCh << "] <= "
434  // << value << "\n";
435  } else if (iValueSet < 79) { //config mode
436  //TODO validity check on value
437  // configMode_ = (ConfigMode)value;
438  // if(d) cout << "config mode <= " << value << "\n";
439  } else if (iValueSet < 80) { //VME I/F
440  //TODO validity check on value
441  // vmeInterface_ = (Vme::type_t)value;
442  //if(d) cout << "Vme Interface code <= " << value << "\n";
443  } else if (iValueSet < 81) { //Spy Mode
444  //TODO validity check on value
445  // spyMode_[iCh] = value & 0x3;
446  // if(d) cout << "Spy mode <= " << value << "\n";
447  } else { //should never be reached!
448  assert(false);
449  }
450  ++iCh;
451  }
452  if (iCh != nChs[iValueSet]) { //error
453  sErr << "Syntax error in imported SRP system configuration file "
454  /*<< filename <<*/ " line "
455  << iLine << ".";
456  }
457  }
458  if (sErr.str().empty() && iValueSet != (nValueSets - 1)) { //error
459  sErr << "Syntax Error in imported SRP system configuration file "
460  /*<< filename <<*/ " line "
461  << iLine << ".";
462  }
463  if (!sErr.str().empty())
464  throw cms::Exception("SyntaxError") << sErr.str();
465 }
466 
467 double EcalSRCondTools::normalizeWeights(int hwWeight) {
468  //Fix sign bit in case only the 12 least significant bits of hwWeight were set
469  //(hardware reprensentation uses only 12 bits)
470  if (hwWeight & (1 << 11))
471  hwWeight |= ~0xEFF;
472  return hwWeight / 1024.;
473 }
474 
475 string EcalSRCondTools::tokenize(const string& s, const string& delim, int& pos) {
476  if (pos < 0)
477  return "";
478  int pos0 = pos;
479  int len = s.size();
480  //eats delimeters at beginning of the string
481  while (pos0 < len && find(delim.begin(), delim.end(), s[pos0]) != delim.end()) {
482  ++pos0;
483  }
484  if (pos0 == len)
485  return "";
486  pos = s.find_first_of(delim, pos0);
487  return s.substr(pos0, (pos > 0 ? pos : len) - pos0);
488 }
489 
491  std::string::size_type pos0 = s.find_first_not_of(" \t");
492  if (pos0 == string::npos) {
493  pos0 = 0;
494  }
495  string::size_type pos1 = s.find_last_not_of(" \t") + 1;
496  if (pos1 == string::npos) {
497  pos1 = pos0;
498  }
499  return s.substr(pos0, pos1 - pos0);
500 }
edm::ESHandle::product
T const * product() const
Definition: ESHandle.h:86
EcalSRCondTools::importParameterSet
static void importParameterSet(EcalSRSettings &sr, const edm::ParameterSet &ps)
Definition: EcalSRCondTools.cc:149
EcalSRSettings::srpLowInterestChannelZS_
std::vector< float > srpLowInterestChannelZS_
Definition: EcalSRSettings.h:121
EcalSRSettings::substitutionSrfs_
std::vector< std::vector< short > > substitutionSrfs_
Definition: EcalSRSettings.h:189
EcalSRCondTools::done_
bool done_
Definition: EcalSRCondTools.h:71
funct::false
false
Definition: Factorize.h:34
EcalSRSettingsRcd.h
filterCSVwithJSON.copy
copy
Definition: filterCSVwithJSON.py:36
ESHandle.h
f
double f[11][100]
Definition: MuScleFitUtils.cc:78
gather_cfg.cout
cout
Definition: gather_cfg.py:144
pos
Definition: PixelAliasList.h:18
ALCARECOPromptCalibProdSiPixelAli0T_cff.mode
mode
Definition: ALCARECOPromptCalibProdSiPixelAli0T_cff.py:96
cms::cuda::assert
assert(be >=bs)
EcalSRSettings::srpMasksFromConfig_
std::vector< std::vector< short > > srpMasksFromConfig_
Definition: EcalSRSettings.h:177
EcalSRSettings::nTccs_
static const int nTccs_
Definition: EcalSRSettings.h:49
EcalSRSettings::actions_
std::vector< int > actions_
Definition: EcalSRSettings.h:168
spr::find
void find(edm::Handle< EcalRecHitCollection > &hits, DetId thisDet, std::vector< EcalRecHitCollection::const_iterator > &hit, bool debug=false)
Definition: FindCaloHit.cc:19
EcalSRSettings.h
dqmiodatasetharvest.db
db
Definition: dqmiodatasetharvest.py:119
cmsdt::algo
algo
Definition: constants.h:164
EcalSRSettings::deltaEta_
std::vector< int > deltaEta_
Definition: EcalSRSettings.h:58
alignCSCRings.s
s
Definition: alignCSCRings.py:92
PoolDBOutputService.h
trigger::size_type
uint16_t size_type
Definition: TriggerTypeDefs.h:18
edm::EventSetup::get
T get() const
Definition: EventSetup.h:73
Service.h
w
const double w
Definition: UKUtility.cc:23
nChs
const int nChs
Definition: recycleTccEmu.cc:11
EcalSRCondTools::ps_
edm::ParameterSet ps_
Definition: EcalSRCondTools.h:69
edm::ESHandle
Definition: DTSurvey.h:22
EcalSRCondTools::EcalSRCondTools
EcalSRCondTools(const edm::ParameterSet &)
Definition: EcalSRCondTools.cc:61
cmsswSequenceInfo.tp
tp
Definition: cmsswSequenceInfo.py:17
EcalSRSettings::symetricZS_
std::vector< int > symetricZS_
Definition: EcalSRSettings.h:111
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
EcalSRSettings::testerSrpTestSrpIds_
std::vector< int > testerSrpTestSrpIds_
Definition: EcalSRSettings.h:197
EcalSRSettings::srfMasks_
std::vector< short > srfMasks_
Definition: EcalSRSettings.h:185
tccNum
constexpr int tccNum[12][12]
Definition: EcalSRCondTools.cc:25
EcalSRCondTools::normalizeWeights
static double normalizeWeights(int hwWeight)
Definition: EcalSRCondTools.cc:467
edm::ParameterSet
Definition: ParameterSet.h:36
Event.h
EcalSRCondTools::~EcalSRCondTools
~EcalSRCondTools() override
Definition: EcalSRCondTools.cc:63
EcalSRSettings::testerDccTestSrpIds_
std::vector< int > testerDccTestSrpIds_
Definition: EcalSRSettings.h:196
EcalSRCondTools.h
cond::Time_t
unsigned long long Time_t
Definition: Time.h:14
EcalSRSettingsRcd
Definition: EcalSRSettingsRcd.h:5
edm::Service< cond::service::PoolDBOutputService >
EcalSRSettings::dccMasks_
std::vector< short > dccMasks_
Definition: EcalSRSettings.h:181
EcalSRCondTools::analyze
void analyze(const edm::Event &evt, const edm::EventSetup &es) override
Definition: EcalSRCondTools.cc:65
EcalSRCondTools::importSrpConfigFile
static void importSrpConfigFile(EcalSRSettings &sr, std::istream &f, bool debug=false)
Definition: EcalSRCondTools.cc:187
value
Definition: value.py:1
EcalSRSettings::bxGlobalOffset_
short bxGlobalOffset_
Definition: EcalSRSettings.h:208
dccNum
constexpr int dccNum[12][12]
Definition: EcalSRCondTools.cc:44
EcalSRSettings::deltaPhi_
std::vector< int > deltaPhi_
Definition: EcalSRSettings.h:71
edm::EventSetup
Definition: EventSetup.h:57
get
#define get
EcalSRSettings::ebDccAdcToGeV_
float ebDccAdcToGeV_
ADC to GeV conversion factor used in ZS filter for EB.
Definition: EcalSRSettings.h:83
edm::ESHandleBase::isValid
bool isValid() const
Definition: ESHandle.h:44
EcalSRSettings::testerSrpEmuSrpIds_
std::vector< int > testerSrpEmuSrpIds_
Definition: EcalSRSettings.h:195
EcalSRCondTools::trim
static std::string trim(std::string s)
Definition: EcalSRCondTools.cc:490
EcalSRSettings::nSrps_
static const int nSrps_
Definition: EcalSRSettings.h:47
EcalSRSettings::bxOffsets_
std::vector< short > bxOffsets_
Definition: EcalSRSettings.h:203
EcalTPGPhysicsConst
Definition: EcalTPGPhysicsConst.h:9
alignmentValidation.fname
string fname
main script
Definition: alignmentValidation.py:959
edm::ParameterSet::getParameter
T getParameter(std::string const &) const
EcalTPGPhysicsConstMap
std::map< uint32_t, EcalTPGPhysicsConst::Item > EcalTPGPhysicsConstMap
Definition: EcalTPGPhysicsConst.h:36
EcalSRSettings
Definition: EcalSRSettings.h:29
EcalSRSettings::dccNormalizedWeights_
std::vector< std::vector< float > > dccNormalizedWeights_
Definition: EcalSRSettings.h:99
std
Definition: JetResolutionObject.h:76
EcalSRSettings::ecalDccZs1stSample_
std::vector< int > ecalDccZs1stSample_
Definition: EcalSRSettings.h:80
EcalSRSettings::eeDccAdcToGeV_
float eeDccAdcToGeV_
ADC to GeV conversion factor used in ZS filter for EE.
Definition: EcalSRSettings.h:85
relativeConstraints.value
value
Definition: relativeConstraints.py:53
EcalSRSettings::testerTccEmuSrpIds_
std::vector< int > testerTccEmuSrpIds_
Definition: EcalSRSettings.h:194
Exception
Definition: hltDiff.cc:246
EventSetup.h
EcalSRSettings::srpHighInterestChannelZS_
std::vector< float > srpHighInterestChannelZS_
Definition: EcalSRSettings.h:131
EcalTPGPhysicsConst.h
ztail.d
d
Definition: ztail.py:151
cms::Exception
Definition: Exception.h:70
EcalSRSettings::automaticMasks_
int automaticMasks_
Definition: EcalSRSettings.h:213
EcalSRSettings::automaticSrpSelect_
int automaticSrpSelect_
Definition: EcalSRSettings.h:218
event
Definition: event.py:1
EcalTPGPhysicsConstRcd.h
edm::Event
Definition: Event.h:73
mps_splice.line
line
Definition: mps_splice.py:76
EcalSRCondTools::tokenize
static std::string tokenize(const std::string &s, const std::string &delim, int &pos)
Definition: EcalSRCondTools.cc:475
EcalTPGPhysicsConstRcd
Definition: EcalTPGPhysicsConstRcd.h:5
EcalSRSettings::tccMasksFromConfig_
std::vector< short > tccMasksFromConfig_
Definition: EcalSRSettings.h:172
EcalSRSettings::nDccs_
static const int nDccs_
Definition: EcalSRSettings.h:48