test
CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
EcalChannelStatusPyWrapper.cc
Go to the documentation of this file.
1 
4 #include "TROOT.h"
5 #include "TH2F.h"
6 #include "TCanvas.h"
7 #include "TStyle.h"
8 #include "TColor.h"
9 #include "TLine.h"
12 
15 
16 #include <string>
17 #include <fstream>
18 #include <algorithm>
19 #include <numeric>
20 #include <iterator>
21 #include <boost/ref.hpp>
22 #include <boost/bind.hpp>
23 #include <boost/function.hpp>
24 #include <boost/iterator/transform_iterator.hpp>
25 
26 namespace cond {
27 
28 
29  namespace ecalcond {
30 
34 
36 
37  int bad(Items const & cont) {
38  return std::count_if(cont.begin(),cont.end(),
39  boost::bind(std::greater<int>(),
40  boost::bind(&value_type::getStatusCode,_1),0)
41  );
42  }
43 
44 
45  void extractBarrel(Container const & cont, std::vector<int> const &, std::vector<float> & result) {
46  result.resize(1);
47  result[0] = bad(cont.barrelItems());
48  }
49  void extractEndcap(Container const & cont, std::vector<int> const &, std::vector<float> & result) {
50  result.resize(1);
51  result[0] = bad(cont.endcapItems());
52  }
53  void extractAll(Container const & cont, std::vector<int> const &, std::vector<float> & result) {
54  result.resize(1);
55  result[0] = bad(cont.barrelItems())+bad(cont.endcapItems());
56  }
57 
58  void extractSuperModules(Container const & cont, std::vector<int> const & which, std::vector<float> & result) {
59  // bho...
60  }
61 
62  void extractSingleChannel(Container const & cont, std::vector<int> const & which, std::vector<float> & result) {
63  result.reserve(which.size());
64  for (unsigned int i=0; i<which.size();i++) {
65  result.push_back(cont[which[i]].getStatusCode());
66  }
67  }
68 
69  typedef boost::function<void(Container const & cont, std::vector<int> const & which, std::vector<float> & result)> CondExtractor;
70 
71  } // ecalcond
72 
73  template<>
74  struct ExtractWhat<ecalcond::Container> {
75 
77  std::vector<int> m_which;
78 
79  ecalcond::How const & how() const { return m_how;}
80  std::vector<int> const & which() const { return m_which;}
81 
82  void set_how(ecalcond::How i) {m_how=i;}
83  void set_which(std::vector<int> & i) { m_which.swap(i);}
84  };
85 
86 
87 
88 
89  template<>
90  class ValueExtractor<ecalcond::Container>: public BaseValueExtractor<ecalcond::Container> {
91  public:
92 
94  static ecalcond::CondExtractor fun[5] = {
100  };
101  return fun[how];
102  }
103 
104 
107  static What what() { return What();}
108 
111  : m_what(what)
112  {
113  // here one can make stuff really complicated...
114  // ask to make average on selected channels...
115  }
116 
117  void compute(Class const & it) override{
118  std::vector<float> res;
119  extractor(m_what.how())(it,m_what.which(),res);
120  swap(res);
121  }
122 
123  private:
125 
126  };
127 
128 
129  template<>
132  std::stringstream ss;
134  ss << EcalChannelStatusXMLTranslator::dumpXML(h,object());
135  return ss.str();
136 
137  }
138 
139  std::string StCodeToStr(unsigned int const & statusCode){
140  unsigned int bits_1to5, bits, mask;
141  mask = 0x1F;//get first 5 bits;
142  bits_1to5 = mask & statusCode;
143  std::stringstream ss;
144  switch(bits_1to5){
145  case 0: break;
146  case 1: ss<< "["<< bits_1to5 << "]:" << "DAC settings problem, pedestal not in the design range, " << "Reco Action: standard reco."; break;
147  case 2: ss<< "["<< bits_1to5 << "]:" << "channel with no laser, ok elsewhere; " << "Reco Action: standard reco."; break;
148  case 3: ss<< "["<< bits_1to5 << "]:" << "noisy; " << "Reco Action: standard reco."; break;
149  case 4: ss<< "["<< bits_1to5 << "]:" << "very noisy; " << "Reco Action: special reco (to be decided)."; break;
150  case 5: ss<< "["<< bits_1to5 << "]: reserved for more categories of noisy channels."; break;
151  case 6: ss<< "["<< bits_1to5 << "]: reserved for more categories of noisy channels."; break;
152  case 7: ss<< "["<< bits_1to5 << "]: reserved for more categories of noisy channels."; break;
153  case 8: ss<< "["<< bits_1to5 << "]:" << " channel at fixed gain 6 (or 6 and 1); " << "Reco Action: 3+5 or 3+1, special reco."; break;
154  case 9: ss<< "["<< bits_1to5 << "]:" << " channel at fixed gain 1; " << "Reco Action: 3+5 or 3+1, special reco."; break;
155  case 10: ss<< "["<< bits_1to5 << "]:" << " channel at fixed gain 0 (dead of type this); " << "Reco Action: recovery from neighbours."; break;
156  case 11: ss<< "["<< bits_1to5 << "]:" << " non responding isolated channel (dead of type other); " << "Reco Action: recovery from neighbours."; break;
157  case 12: ss<< "["<< bits_1to5 << "]:" << " channel and one or more neigbors not responding (e.g.: in a dead VFE 5x1 channel) " << "Reco Action: no recovery."; break;
158  case 13: ss<< "["<< bits_1to5 << "]:" << " channel in TT with no data link, TP data ok; " << "Reco Action: recovery from TP data."; break;
159  case 14: ss<< "["<< bits_1to5 << "]:" << " channel in TT with no data link and no TP data; " << "Reco Action: none."; break;
160  default:
161  ss<< "no such bits can be set!";
162  }
163  bits = 6;
164 
165  mask = 1 << bits;
166  if (statusCode & mask) //case 15
167  ss << " bit["<< bits << "]:" << " HV good/not good;";
168 
169  mask = 1 << ++bits;
170  if (statusCode & mask)//case 16
171  ss << " bit["<< bits << "]:" << " LV on/off;";
172 
173  mask = 1 << ++bits;
174  if (statusCode & mask)//case 17
175  ss << " bit["<< bits << "]:" << " DAQ in/out;";
176 
177  mask = 1 << ++bits;
178  if (statusCode & mask)//case 18
179  ss << " bit["<< bits << "]:" << " TP readout on/off;";
180 
181  mask = 1 << ++bits;
182  if (statusCode & mask)//case 19
183  ss << " bit["<< bits << "]:" << " Trigger in/out;";
184 
185  mask = 1 << ++bits;
186  if (statusCode & mask)//case 20
187  ss << " bit["<< bits << "]:" << " Temperature ok/not ok;";
188 
189  mask = 1 << ++bits;
190  if (statusCode & mask)//case 21
191  ss << " bit["<< bits << "]:" << " Humidity ok/not;";
192 
193  //for debugging:
194  //ss << " StatusCode: " << statusCode << " bits_1to5: " <<bits_1to5 << std::endl;
195  ss << std::endl;
196  return ss.str();
197  }
198 
199  void setErr(unsigned int const & statusCode, std::vector< std::pair< std::string, unsigned int> > & vTotalWithErr){
200  unsigned int bits_1to5, bits, mask;
201  mask = 0x1F;//get first 5 bits;
202 
203  bits_1to5 = mask & statusCode;
204  if ((bits_1to5 > 0) &&( bits_1to5 < 15)){
205  vTotalWithErr[bits_1to5].second += 1;
206  }
207 
208  bits = 6;
209 
210  mask = 1 << bits;
211  if (statusCode & mask) //case 15
212  vTotalWithErr[bits + 11].second += 1;
213 
214  mask = 1 << ++bits;
215  if (statusCode & mask)//case 16
216  vTotalWithErr[bits + 11].second += 1;
217 
218  mask = 1 << ++bits;
219  if (statusCode & mask)//case 17
220  vTotalWithErr[bits + 11].second += 1;
221 
222  mask = 1 << ++bits;
223  if (statusCode & mask)//case 18
224  vTotalWithErr[bits + 11].second += 1;
225 
226  mask = 1 << ++bits;
227  if (statusCode & mask)//case 19
228  vTotalWithErr[bits + 11].second += 1;
229 
230  mask = 1 << ++bits;
231  if (statusCode & mask)//case 20
232  vTotalWithErr[bits + 11].second += 1;
233 
234  mask = 1 << ++bits;
235  if (statusCode & mask)//case 21
236  vTotalWithErr[bits + 11].second += 1;
237  }
238 
239  std::string getTotalErrors(const std::vector<EcalChannelStatusCode> & vItems){
240  unsigned int stcode = 0, index = 0, totalErrorCodes = 22;
241  std::stringstream ss;
242  std::vector< std::pair< std::string, unsigned int > > vTotalWithErr(totalErrorCodes);
243 
244 
245  // init error codes:
246  index = 0;
247  ss.str(""); ss << " No errors. "; vTotalWithErr[index].first = ss.str(); ++index;
248  ss.str(""); ss << "["<< index << "]:" << "DAC settings problem, pedestal not in the design range, " << "Reco Action: standard reco."; vTotalWithErr[index].first = ss.str(); ++index;//1
249  ss.str(""); ss << "["<< index << "]:" << "channel with no laser, ok elsewhere; " << "Reco Action: standard reco."; vTotalWithErr[index].first = ss.str(); ++index;
250  ss.str(""); ss << "["<< index << "]:" << "noisy; " << "Reco Action: standard reco."; vTotalWithErr[index].first = ss.str(); ++index;
251  ss.str(""); ss << "["<< index << "]:" << "very noisy; " << "Reco Action: special reco (to be decided)."; vTotalWithErr[index].first = ss.str(); ++index;
252  ss.str(""); ss << "["<< index << "]: reserved for more categories of noisy channels."; vTotalWithErr[index].first = ss.str(); ++index;
253  ss.str(""); ss << "["<< index << "]: reserved for more categories of noisy channels."; vTotalWithErr[index].first = ss.str(); ++index;
254  ss.str(""); ss << "["<< index << "]: reserved for more categories of noisy channels."; vTotalWithErr[index].first = ss.str(); ++index;
255  ss.str(""); ss << "["<< index << "]:" << " channel at fixed gain 6 (or 6 and 1); " << "Reco Action: 3+5 or 3+1, special reco."; vTotalWithErr[index].first = ss.str(); ++index;
256  ss.str(""); ss << "["<< index << "]:" << " channel at fixed gain 1; " << "Reco Action: 3+5 or 3+1, special reco."; vTotalWithErr[index].first = ss.str(); ++index;
257  ss.str(""); ss << "["<< index << "]:" << " channel at fixed gain 0 (dead of type this); " << "Reco Action: recovery from neighbours."; vTotalWithErr[index].first = ss.str(); ++index;
258  ss.str(""); ss << "["<< index << "]:" << " non responding isolated channel (dead of type other); " << "Reco Action: recovery from neighbours."; vTotalWithErr[index].first = ss.str(); ++index;
259  ss.str(""); ss << "["<< index << "]:" << " channel and one or more neigbors not responding (e.g.: in a dead VFE 5x1 channel) " << "Reco Action: no recovery."; vTotalWithErr[index].first = ss.str(); ++index;
260  ss.str(""); ss << "["<< index << "]:" << " channel in TT with no data link, TP data ok; " << "Reco Action: recovery from TP data."; vTotalWithErr[index].first = ss.str(); ++index;
261  ss.str(""); ss << "["<< index << "]:" << " channel in TT with no data link and no TP data; " << "Reco Action: none."; vTotalWithErr[index].first = ss.str(); ++index;
262 
263  unsigned int bits = 6;
264  ss.str(""); ss << " bit["<< bits++ << "]:" << " HV good/not good;"; vTotalWithErr[index].first = ss.str(); ++index;//15
265  ss.str(""); ss << " bit["<< bits++ << "]:" << " LV on/off;"; vTotalWithErr[index].first = ss.str(); ++index;
266  ss.str(""); ss << " bit["<< bits++ << "]:" << " DAQ in/out;"; vTotalWithErr[index].first = ss.str(); ++index;
267  ss.str(""); ss << " bit["<< bits++ << "]:" << " TP readout on/off;"; vTotalWithErr[index].first = ss.str(); ++index;
268  ss.str(""); ss << " bit["<< bits++ << "]:" << " Trigger in/out;"; vTotalWithErr[index].first = ss.str(); ++index;
269  ss.str(""); ss << " bit["<< bits++ << "]:" << " Temperature ok/not ok;"; vTotalWithErr[index].first = ss.str(); ++index;
270  ss.str(""); ss << " bit["<< bits++ << "]:" << " Humidity ok/not;"; vTotalWithErr[index].first = ss.str(); ++index;//21
271 
272 
273  ss.str("");
274  //count error codes for each error:
275  for (std::vector<EcalChannelStatusCode>::const_iterator vIter = vItems.begin(); vIter != vItems.end(); ++vIter){
276  stcode = vIter->getStatusCode();
277  if (stcode !=0){
278  setErr(stcode, vTotalWithErr);
279  }
280  }
281 
282  unsigned int i = 0;
283  for (std::vector< std::pair< std::string, unsigned int > >::const_iterator iTotalErr = vTotalWithErr.begin(); iTotalErr != vTotalWithErr.end(); ++iTotalErr){
284  if (iTotalErr->second != 0)
285  ss << "Total:" << iTotalErr->second << " Error:" << iTotalErr->first << std::endl;
286  ++i;
287  }
288  return ss.str();
289  }
290 
291  template<>
293  const std::vector<EcalChannelStatusCode> barrelItems = object().barrelItems();
294  const std::vector<EcalChannelStatusCode> endcapItems = object().endcapItems();
295  std::stringstream ss;
296 
297  ss << std::endl << "------Barrel Items: " << std::endl;
298  ss << "---Total: " << barrelItems.size() << std::endl;
299  ss << "---With errors: " << ecalcond::bad(barrelItems) << std::endl;
300  ss << getTotalErrors(barrelItems);
301 
302  ss << std::endl << "------Endcap Items: " << std::endl;
303  ss << "---Total: " << endcapItems.size() << std::endl;
304  ss << "---With errors: " << ecalcond::bad(endcapItems) << std::endl;
305  ss << getTotalErrors(endcapItems);
306 
307  //for (std::vector<EcalChannelStatusCode>::const_iterator barIter = barrelItems.begin(); barIter != barrelItems.end(); ++barIter){
308  // stcode = barIter->getStatusCode();
309  // if (stcode !=0){
310  // barrelId = EBDetId::detIdFromDenseIndex(count);
311  // ss << "Id[" << count << "] RawId:[" << barrelId.rawId() << "]"
312  // << "; Ieta:" << barrelId.ieta() <<
313  // "; Iphi:" << barrelId.iphi()<<
314  // "; Ism:" << barrelId.ism()<<
315  // "; Ic:" << barrelId.ic()<<
316  // "; Errors:" << StCodeToStr(barIter->getStatusCode(), vBarrWithErr, barrelId);
317  // }
318  // ++count;
319  //}
320 
321  //EEDetId endcapId;
322  //ss << std::endl << "------Endcap Items: " << std::endl;
323  //ss << "---Total: " << endcapItems.size() << std::endl;
324  //ss << "---With errors: " << ecalcond::bad(endcapItems) << std::endl;
325  //count = 0;
326  //for (std::vector<EcalChannelStatusCode>::const_iterator endcapIter = endcapItems.begin(); endcapIter != endcapItems.end(); ++endcapIter){
327  // stcode = endcapIter->getStatusCode();
328  // if (stcode !=0){
329  // endcapId = EEDetId::detIdFromDenseIndex(count);
330  // ss << "Id[" << count << "] RawId:[" << endcapId.rawId() << "]"
331  // << "; Zside:" << endcapId.zside() <<
332  // "; Ix:" << endcapId.ix()<<
333  // "; Iy:" << endcapId.iy()<<
334  // "; Errors:" << StCodeToStr(endcapIter->getStatusCode());
335  // }
336  // ++count;
337  //}
338 
339  //ss << StCodeToStr(0xFFF09);
340 
341  return ss.str();
342  }
343 
344 
345  template<>
347  std::string const &,
348  std::vector<int> const&,
349  std::vector<float> const& ) const {
350  // use David's palette
351  gStyle->SetPalette(1);
352 
353  const Int_t NRGBs = 5;
354  const Int_t NCont = 255;
355 
356  Double_t stops[NRGBs] = { 0.00, 0.34, 0.61, 0.84, 1.00 };
357  Double_t red[NRGBs] = { 0.00, 0.00, 0.87, 1.00, 0.51 };
358  Double_t green[NRGBs] = { 0.00, 0.81, 1.00, 0.20, 0.00 };
359  Double_t blue[NRGBs] = { 0.51, 1.00, 0.12, 0.00, 0.00 };
360  TColor::CreateGradientColorTable(NRGBs, stops, red, green, blue, NCont);
361  gStyle->SetNumberContours(NCont);
362 
363  TCanvas canvas("CC map","CC map",800,800);
364  TPad* padb = new TPad("padb","padb", 0., 0.55, 1., 1.);
365  padb->Draw();
366  TPad* padem = new TPad("padem","padem", 0., 0., 0.45, 0.45);
367  padem->Draw();
368  TPad* padep = new TPad("padep","padep", 0.55, 0., 1., 0.45);
369  padep->Draw();
370 
371  const int kSides = 2;
372  const int kBarlRings = EBDetId::MAX_IETA;
373  const int kBarlWedges = EBDetId::MAX_IPHI;
374  const int kEndcWedgesX = EEDetId::IX_MAX;
375  const int kEndcWedgesY = EEDetId::IY_MAX;
376 
377  TH2F* barrel = new TH2F("EB","EB Channel Status",360,0,360, 171, -85,86);
378  TH2F* endc_p = new TH2F("EE+","EE+ Channel Status",100,1,101,100,1,101);
379  TH2F* endc_m = new TH2F("EE-","EE- Channel Status",100,1,101,100,1,101);
380 
381  for (int sign=0; sign < kSides; sign++) {
382  int thesign = sign==1 ? 1:-1;
383 
384  for (int ieta=0; ieta<kBarlRings; ieta++) {
385  for (int iphi=0; iphi<kBarlWedges; iphi++) {
386  EBDetId id((ieta+1)*thesign, iphi+1);
387  barrel->Fill(iphi, ieta*thesign + thesign, object()[id.rawId()].getStatusCode());
388  // if(iphi < 20 && object()[id.rawId()].getStatusCode() > 10)
389  // std::cout << " phi " << iphi << " eta " << ieta << " status " << object()[id.rawId()].getStatusCode() << std::endl;
390  } // iphi
391  } // ieta
392 
393  for (int ix=0; ix<kEndcWedgesX; ix++) {
394  for (int iy=0; iy<kEndcWedgesY; iy++) {
395  if (! EEDetId::validDetId(ix+1,iy+1,thesign)) continue;
396  EEDetId id(ix+1,iy+1,thesign);
397  if (thesign==1) {
398  endc_p->Fill(ix+1,iy+1,object()[id.rawId()].getStatusCode());
399  }
400  else{
401  endc_m->Fill(ix+1,iy+1,object()[id.rawId()].getStatusCode());
402  }
403  } // iy
404  } // ix
405  } // side
406 
407  TLine* l = new TLine(0., 0., 0., 0.);
408  l->SetLineWidth(1);
409  padb->cd();
410  barrel->SetStats(0);
411  barrel->SetMaximum(14);
412  barrel->SetMinimum(0);
413  barrel->Draw("colz");
414  for(int i = 0; i <17; i++) {
415  Double_t x = 20.+ (i *20);
416  l = new TLine(x,-85.,x,86.);
417  l->Draw();
418  }
419  l = new TLine(0.,0.,360.,0.);
420  l->Draw();
421  int ixSectorsEE[202] = {
422  62, 62, 61, 61, 60, 60, 59, 59, 58, 58, 56, 56, 46, 46, 44, 44, 43, 43, 42, 42,
423  41, 41, 40, 40, 41, 41, 42, 42, 43, 43, 44, 44, 46, 46, 56, 56, 58, 58, 59, 59,
424  60, 60, 61, 61, 62, 62, 0,101,101, 98, 98, 96, 96, 93, 93, 88, 88, 86, 86, 81,
425  81, 76, 76, 66, 66, 61, 61, 41, 41, 36, 36, 26, 26, 21, 21, 16, 16, 14, 14, 9,
426  9, 6, 6, 4, 4, 1, 1, 4, 4, 6, 6, 9, 9, 14, 14, 16, 16, 21, 21, 26,
427  26, 36, 36, 41, 41, 61, 61, 66, 66, 76, 76, 81, 81, 86, 86, 88, 88, 93, 93, 96,
428  96, 98, 98,101,101, 0, 62, 66, 66, 71, 71, 81, 81, 91, 91, 93, 0, 62, 66, 66,
429  91, 91, 98, 0, 58, 61, 61, 66, 66, 71, 71, 76, 76, 81, 81, 0, 51, 51, 0, 44,
430  41, 41, 36, 36, 31, 31, 26, 26, 21, 21, 0, 40, 36, 36, 11, 11, 4, 0, 40, 36,
431  36, 31, 31, 21, 21, 11, 11, 9, 0, 46, 46, 41, 41, 36, 36, 0, 56, 56, 61, 61, 66, 66};
432 
433  int iySectorsEE[202] = {
434  51, 56, 56, 58, 58, 59, 59, 60, 60, 61, 61, 62, 62, 61, 61, 60, 60, 59, 59, 58,
435  58, 56, 56, 46, 46, 44, 44, 43, 43, 42, 42, 41, 41, 40, 40, 41, 41, 42, 42, 43,
436  43, 44, 44, 46, 46, 51, 0, 51, 61, 61, 66, 66, 76, 76, 81, 81, 86, 86, 88, 88,
437  93, 93, 96, 96, 98, 98,101,101, 98, 98, 96, 96, 93, 93, 88, 88, 86, 86, 81, 81,
438  76, 76, 66, 66, 61, 61, 41, 41, 36, 36, 26, 26, 21, 21, 16, 16, 14, 14, 9, 9,
439  6, 6, 4, 4, 1, 1, 4, 4, 6, 6, 9, 9, 14, 14, 16, 16, 21, 21, 26, 26,
440  36, 36, 41, 41, 51, 0, 46, 46, 41, 41, 36, 36, 31, 31, 26, 26, 0, 51, 51, 56,
441  56, 61, 61, 0, 61, 61, 66, 66, 71, 71, 76, 76, 86, 86, 88, 0, 62,101, 0, 61,
442  61, 66, 66, 71, 71, 76, 76, 86, 86, 88, 0, 51, 51, 56, 56, 61, 61, 0, 46, 46,
443  41, 41, 36, 36, 31, 31, 26, 26, 0, 40, 31, 31, 16, 16, 6, 0, 40, 31, 31, 16, 16, 6};
444 
445  padem->cd();
446  endc_m->SetStats(0);
447  endc_m->SetMaximum(14);
448  endc_m->SetMinimum(0);
449  endc_m->Draw("colz");
450  for ( int i=0; i<201; i=i+1) {
451  if ( (ixSectorsEE[i]!=0 || iySectorsEE[i]!=0) &&
452  (ixSectorsEE[i+1]!=0 || iySectorsEE[i+1]!=0) ) {
453  l->DrawLine(ixSectorsEE[i], iySectorsEE[i],
454  ixSectorsEE[i+1], iySectorsEE[i+1]);
455  }
456  }
457  padep->cd();
458  endc_p->SetStats(0);
459  endc_p->SetMaximum(14);
460  endc_p->SetMinimum(0);
461  endc_p->Draw("colz");
462  for ( int i=0; i<201; i=i+1) {
463  if ( (ixSectorsEE[i]!=0 || iySectorsEE[i]!=0) &&
464  (ixSectorsEE[i+1]!=0 || iySectorsEE[i+1]!=0) ) {
465  l->DrawLine(ixSectorsEE[i], iySectorsEE[i],
466  ixSectorsEE[i+1], iySectorsEE[i+1]);
467  }
468  }
469  canvas.SaveAs(filename.c_str());
470  return filename;
471  }
472 }
473 
474 namespace condPython {
475  template<>
476  void defineWhat<cond::ecalcond::Container>() {
477  using namespace boost::python;
478  enum_<cond::ecalcond::How>("How")
479  .value("singleChannel",cond::ecalcond::singleChannel)
480  .value("bySuperModule",cond::ecalcond::bySuperModule)
481  .value("barrel",cond::ecalcond::barrel)
482  .value("endcap",cond::ecalcond::endcap)
483  .value("all",cond::ecalcond::all)
484  ;
485 
487  class_<What>("What",init<>())
488  .def("set_how",&What::set_how)
489  .def("set_which",&What::set_which)
490  .def("how",&What::how, return_value_policy<copy_const_reference>())
491  .def("which",&What::which, return_value_policy<copy_const_reference>())
492  ;
493  }
494 }
495 
void extractSuperModules(Container const &cont, std::vector< int > const &which, std::vector< float > &result)
int i
Definition: DBlmapReader.cc:9
std::string plot(std::string const &, std::string const &, std::vector< int > const &, std::vector< float > const &) const
EcalChannelStatus Container
static ecalcond::CondExtractor & extractor(ecalcond::How how)
ExtractWhat< Class > What
void setErr(unsigned int const &statusCode, std::vector< std::pair< std::string, unsigned int > > &vTotalWithErr)
std::vector< int > const & which() const
static const int kBarlRings
const Items & barrelItems() const
How EventSelector::AcceptEvent() decides whether to accept an event for output otherwise it is excluding the probing of A single or multiple positive and the trigger will pass if any such matching triggers are PASS or EXCEPTION[A criterion thatmatches no triggers at all is detected and causes a throw.] A single negative with an expectation of appropriate bit checking in the decision bits
Code getStatusCode() const
return decoded status
boost::function< void(Container const &cont, std::vector< int > const &which, std::vector< float > &result)> CondExtractor
#define PYTHON_WRAPPER(_class, _name)
static const int kSides
static std::string dumpXML(const EcalCondHeader &header, const EcalChannelStatus &record)
def canvas
Definition: svgfig.py:481
int bad(Items const &cont)
static const int kBarlWedges
std::string summary() const
static const int kEndcWedgesX
tuple result
Definition: query.py:137
The Signals That Services Can Subscribe To This is based on ActivityRegistry h
Helper function to determine trigger accepts.
Definition: Activities.doc:4
Container::value_type value_type
void swap(std::vector< float > &v)
std::string StCodeToStr(unsigned int const &statusCode)
static const int IX_MAX
Definition: EEDetId.h:302
static const int MAX_IPHI
Definition: EBDetId.h:144
static bool validDetId(int crystal_ix, int crystal_iy, int iz)
Definition: EEDetId.h:248
static const int MAX_IETA
Definition: EBDetId.h:143
int cont
list object
Definition: dbtoconf.py:77
void extractSingleChannel(Container const &cont, std::vector< int > const &which, std::vector< float > &result)
tuple filename
Definition: lut2db_cfg.py:20
static const int IY_MAX
Definition: EEDetId.h:306
Definition: DDAxes.h:10
void extractBarrel(Container const &cont, std::vector< int > const &, std::vector< float > &result)
const Items & endcapItems() const
std::string dump() const
std::string getTotalErrors(const std::vector< EcalChannelStatusCode > &vItems)
void extractEndcap(Container const &cont, std::vector< int > const &, std::vector< float > &result)
void extractAll(Container const &cont, std::vector< int > const &, std::vector< float > &result)
static const int kEndcWedgesY