CMS 3D CMS Logo

EcalTPCondAnalyzer.cc
Go to the documentation of this file.
1 // -*- C++ -*-
2 //
3 // Class: EcalTPDBAnalyzer
4 //
10 //
11 //
12 // Original Author: Ursula Berthon
13 // Created: Wed Oct 15 11:38:38 CEST 2008
14 //
15 //
16 //
17 
18 // system include files
19 #include <fstream>
20 #include <iostream>
21 #include <memory>
22 #include <utility>
23 
24 // user include files
29 
46 
51 
53 
55 
56 {}
57 
59  // get geometry
60 
61  edm::ESHandle<CaloSubdetectorGeometry> theEndcapGeometry_handle, theBarrelGeometry_handle;
62  evtSetup.get<EcalEndcapGeometryRecord>().get("EcalEndcap", theEndcapGeometry_handle);
63  evtSetup.get<EcalBarrelGeometryRecord>().get("EcalBarrel", theBarrelGeometry_handle);
64  theEndcapGeometry_ = &(*theEndcapGeometry_handle);
65  theBarrelGeometry_ = &(*theBarrelGeometry_handle);
66 
67  cacheID_ = this->getRecords(evtSetup);
68 }
69 
71 
73 
75  //
76  // get Eventsetup records and print them
77  //
78  printComment();
79 
80  edm::ESHandle<EcalTPGPhysicsConst> theEcalTPGPhysConst_handle;
81  setup.get<EcalTPGPhysicsConstRcd>().get(theEcalTPGPhysConst_handle);
82  const EcalTPGPhysicsConst *ecaltpPhysConst = theEcalTPGPhysConst_handle.product();
83  printEcalTPGPhysicsConst(ecaltpPhysConst);
84  // for EcalFenixStrip...
85 
86  // get parameter records for xtals
87  edm::ESHandle<EcalTPGLinearizationConst> theEcalTPGLinearization_handle;
88  setup.get<EcalTPGLinearizationConstRcd>().get(theEcalTPGLinearization_handle);
89  const EcalTPGLinearizationConst *ecaltpLin = theEcalTPGLinearization_handle.product();
90 
91  edm::ESHandle<EcalTPGPedestals> theEcalTPGPedestals_handle;
92  setup.get<EcalTPGPedestalsRcd>().get(theEcalTPGPedestals_handle);
93  const EcalTPGPedestals *ecaltpPed = theEcalTPGPedestals_handle.product();
94  printCRYSTAL(ecaltpPed, ecaltpLin);
95 
96  // weight
97  edm::ESHandle<EcalTPGWeightIdMap> theEcalTPGWEightIdMap_handle;
98  setup.get<EcalTPGWeightIdMapRcd>().get(theEcalTPGWEightIdMap_handle);
99  const EcalTPGWeightIdMap *ecaltpgWeightMap = theEcalTPGWEightIdMap_handle.product();
100  printWEIGHT(ecaltpgWeightMap);
101 
102  // .. and for EcalFenixTcp
103 
104  edm::ESHandle<EcalTPGFineGrainEBIdMap> theEcalTPGFineGrainEBIdMap_handle;
105  setup.get<EcalTPGFineGrainEBIdMapRcd>().get(theEcalTPGFineGrainEBIdMap_handle);
106  const EcalTPGFineGrainEBIdMap *ecaltpgFineGrainEB = theEcalTPGFineGrainEBIdMap_handle.product();
107  printEcalTPGFineGrainEBIdMap(ecaltpgFineGrainEB);
108 
109  edm::ESHandle<EcalTPGLutIdMap> theEcalTPGLutIdMap_handle;
110  setup.get<EcalTPGLutIdMapRcd>().get(theEcalTPGLutIdMap_handle);
111  const EcalTPGLutIdMap *ecaltpgLut = theEcalTPGLutIdMap_handle.product();
112  printEcalTPGLutIdMap(ecaltpgLut);
113 
114  // for strips
115  edm::ESHandle<EcalTPGSlidingWindow> theEcalTPGSlidingWindow_handle;
116  setup.get<EcalTPGSlidingWindowRcd>().get(theEcalTPGSlidingWindow_handle);
117  const EcalTPGSlidingWindow *ecaltpgSlidW = theEcalTPGSlidingWindow_handle.product();
118  edm::ESHandle<EcalTPGFineGrainStripEE> theEcalTPGFineGrainStripEE_handle;
119  setup.get<EcalTPGFineGrainStripEERcd>().get(theEcalTPGFineGrainStripEE_handle);
120  const EcalTPGFineGrainStripEE *ecaltpgFgStripEE = theEcalTPGFineGrainStripEE_handle.product();
121  edm::ESHandle<EcalTPGWeightGroup> theEcalTPGWEightGroup_handle;
122  setup.get<EcalTPGWeightGroupRcd>().get(theEcalTPGWEightGroup_handle);
123  const EcalTPGWeightGroup *ecaltpgWeightGroup = theEcalTPGWEightGroup_handle.product();
124  printSTRIP(ecaltpgSlidW, ecaltpgWeightGroup, ecaltpgFgStripEE);
125 
126  // get parameter records for towers
127  edm::ESHandle<EcalTPGLutGroup> theEcalTPGLutGroup_handle;
128  setup.get<EcalTPGLutGroupRcd>().get(theEcalTPGLutGroup_handle);
129  const EcalTPGLutGroup *ecaltpgLutGroup = theEcalTPGLutGroup_handle.product();
130 
131  edm::ESHandle<EcalTPGFineGrainEBGroup> theEcalTPGFineGrainEBGroup_handle;
132  setup.get<EcalTPGFineGrainEBGroupRcd>().get(theEcalTPGFineGrainEBGroup_handle);
133  const EcalTPGFineGrainEBGroup *ecaltpgFgEBGroup = theEcalTPGFineGrainEBGroup_handle.product();
134  edm::ESHandle<EcalTPGSpike> theEcalTPGSpike_handle;
135  setup.get<EcalTPGSpikeRcd>().get(theEcalTPGSpike_handle);
136  const EcalTPGSpike *ecaltpgSpikeTh = theEcalTPGSpike_handle.product();
137 
138  printTOWEREB(ecaltpgSpikeTh, ecaltpgFgEBGroup, ecaltpgLutGroup);
139  edm::ESHandle<EcalTPGFineGrainTowerEE> theEcalTPGFineGrainTowerEE_handle;
140  setup.get<EcalTPGFineGrainTowerEERcd>().get(theEcalTPGFineGrainTowerEE_handle);
141  const EcalTPGFineGrainTowerEE *ecaltpgFineGrainTowerEE = theEcalTPGFineGrainTowerEE_handle.product();
142 
143  printTOWEREE(ecaltpgFineGrainTowerEE, ecaltpgLutGroup);
144 
145  // get parameters for BadX
146  /* edm::ESHandle<EcalTPGCrystalStatus> theEcalTPGCrystalStatus_handle;
147  setup.get<EcalTPGCrystalStatusRcd>().get(theEcalTPGCrystalStatus_handle);
148  const EcalTPGCrystalStatus * ecaltpgBadX =
149  theEcalTPGCrystalStatus_handle.product(); printBadX(ecaltpgBadX);
150 
151  // get parameters for BadTT
152  edm::ESHandle<EcalTPGTowerStatus> theEcalTPGTowerStatus_handle;
153  setup.get<EcalTPGTowerStatusRcd>().get(theEcalTPGTowerStatus_handle);
154  const EcalTPGTowerStatus * ecaltpgBadTT =
155  theEcalTPGTowerStatus_handle.product(); printBadTT(ecaltpgBadTT);
156  */
157 
158  // get parameters for BadStrip
159  /* edm::ESHandle<EcalTPGStripStatus> theEcalTPGStripStatus_handle;
160  setup.get<EcalTPGStripStatusRcd>().get(theEcalTPGStripStatus_handle);
161  const EcalTPGStripStatus * ecaltpgBadStrip =
162  theEcalTPGStripStatus_handle.product(); printBadStrip(ecaltpgBadStrip);
163  */
164 
165  std::cout << "EOF" << std::endl;
166 
167  return setup.get<EcalTPGFineGrainTowerEERcd>().cacheIdentifier();
168 }
169 
170 // ------------ method called to analyze the data ------------
172 
174 
177  const EcalTPGPhysicsConstMap &mymap = ecaltpgPhysConst->getMap();
178  for (it = mymap.begin(); it != mymap.end(); ++it) {
179  if (it == mymap.begin()) {
180  std::cout << "\nPHYSICS_EB " << (*it).first << std::endl;
181  } else {
182  std::cout << "\nPHYSICS_EE " << (*it).first << std::endl;
183  }
184  std::cout << (*it).second.EtSat << " " << (*it).second.ttf_threshold_Low << " " << (*it).second.ttf_threshold_High
185  << std::endl;
186  std::cout << (*it).second.FG_lowThreshold << " " << (*it).second.FG_highThreshold << " " << (*it).second.FG_lowRatio
187  << " " << (*it).second.FG_highRatio << std::endl;
188  }
189 }
190 
192  const EcalTPGWeightGroup *ecaltpgWeightGroup,
193  const EcalTPGFineGrainStripEE *ecaltpgFgStripEE) const {
194  // print STRIP information
195  const EcalTPGSlidingWindowMap &slwinmap = slWin->getMap();
196  const EcalTPGFineGrainStripEEMap &fgstripEEmap = ecaltpgFgStripEE->getMap();
198  const EcalTPGGroups::EcalTPGGroupsMap &gMap = ecaltpgWeightGroup->getMap();
200 
201  std::cout << std::endl;
202  for (int mysub = 1; mysub <= 2; ++mysub) {
203  std::cout << std::endl;
204  for (it = slwinmap.begin(); it != slwinmap.end(); ++it) {
205  EcalTriggerElectronicsId elid((*it).first);
206  groupId = gMap.find((*it).first);
207  int subdet = elid.subdet();
208  if (subdet == mysub) {
209  if (subdet == 1) {
210  std::cout << "STRIP_EB " << std::dec << (*it).first << std::endl;
211  std::cout << std::hex << "0x" << (*it).second << std::endl;
212  std::cout << "" << (*groupId).second << std::endl; // weightgroupid
213  EcalTPGFineGrainStripEEMapIterator it2 = fgstripEEmap.find((*it).first);
214  if (it2 == fgstripEEmap.end()) {
215  edm::LogWarning("EcalTPGCondAnalyzer") << " could not find strip Id " << (*it).first
216  << ", given in sliding window, inside the "
217  "EcalTPGFineGranStripEEMap!!!";
218  } else {
219  EcalTPGFineGrainStripEE::Item item = (*it2).second;
220  std::cout << std::hex << "0x" << item.threshold << " 0x" << item.lut << std::endl;
221  }
222  } else if (subdet == 2) {
223  std::cout << "STRIP_EE " << std::dec << (*it).first << std::endl;
224  std::cout << std::hex << "0x" << (*it).second << std::endl;
225  std::cout << " " << (*groupId).second << std::endl; // weightgroupid
226  EcalTPGFineGrainStripEEMapIterator it2 = fgstripEEmap.find((*it).first);
227  if (it2 == fgstripEEmap.end()) {
228  edm::LogWarning("EcalTPGCondAnalyzer") << " could not find strip Id " << (*it).first
229  << ", given in sliding window, inside the "
230  "EcalTPGFineGranStripEEMap!!!";
231  } else {
232  EcalTPGFineGrainStripEE::Item item = (*it2).second;
233  std::cout << std::hex << "0x" << item.threshold << " 0x" << item.lut << std::endl;
234  }
235  }
236  }
237  }
238  }
239 }
240 
241 void EcalTPCondAnalyzer::printWEIGHT(const EcalTPGWeightIdMap *ecaltpgWeightIdMap) const {
242  std::cout << std::endl;
244  uint32_t w0, w1, w2, w3, w4;
245  const EcalTPGWeightIdMap::EcalTPGWeightMap &map = ecaltpgWeightIdMap->getMap();
246  for (it = map.begin(); it != map.end(); ++it) {
247  std::cout << "WEIGHT " << (*it).first << std::endl;
248  (*it).second.getValues(w0, w1, w2, w3, w4);
249  std::cout << std::hex << "0x" << w0 << " 0x" << w1 << " 0x" << w2 << " 0x" << w3 << " 0x" << w4 << " " << std::endl;
250  std::cout << std::endl;
251  std::cout << std::endl;
252  }
253 }
254 
257  const EcalTPGFineGrainEBIdMap::EcalTPGFineGrainEBMap &map = ecaltpgFineGrainEB->getMap();
258  uint32_t ThresholdETLow, ThresholdETHigh, RatioLow, RatioHigh, LUT;
259 
260  // std::cout<<std::endl;
261  for (it = map.begin(); it != map.end(); ++it) {
262  std::cout << "FG " << (*it).first << std::endl;
263  (*it).second.getValues(ThresholdETLow, ThresholdETHigh, RatioLow, RatioHigh, LUT);
264  std::cout << std::hex << "0x" << ThresholdETLow << " 0x" << ThresholdETHigh << " 0x" << RatioLow << " 0x"
265  << RatioHigh << " 0x" << LUT << std::endl;
266  }
267 }
268 
271  const EcalTPGLutIdMap::EcalTPGLutMap &map = ecaltpgLut->getMap();
272 
273  std::cout << std::endl;
274  for (it = map.begin(); it != map.end(); ++it) {
275  std::cout << "LUT " << (*it).first << std::endl;
276  const unsigned int *lut = (*it).second.getLut();
277  for (unsigned int i = 0; i < 1024; ++i)
278  std::cout << std::hex << "0x" << *lut++ << std::endl;
279  }
280 }
281 
283  std::cout << std::endl;
284  const EcalTPGPedestalsMap &pedMap = ecaltpPed->getMap();
285  const EcalTPGLinearizationConstMap &linMap = ecaltpLin->getMap();
286 
287  const std::vector<DetId> &ebCells = theBarrelGeometry_->getValidDetIds(DetId::Ecal, EcalBarrel);
288 
289  std::cout << "COMMENT ====== barrel crystals ====== " << std::endl;
290  for (std::vector<DetId>::const_iterator it = ebCells.begin(); it != ebCells.end(); ++it) {
291  EBDetId id(*it);
292  std::cout << "CRYSTAL " << std::dec << id.rawId() << std::endl;
293  const EcalTPGPedestal &ped = pedMap[id.rawId()];
294  const EcalTPGLinearizationConstant &lin = linMap[id.rawId()];
295  std::cout << std::hex << " 0x" << ped.mean_x12 << " 0x" << lin.mult_x12 << " 0x" << lin.shift_x12 << std::endl;
296  std::cout << std::hex << " 0x" << ped.mean_x6 << " 0x" << lin.mult_x6 << " 0x" << lin.shift_x6 << std::endl;
297  std::cout << std::hex << " 0x" << ped.mean_x1 << " 0x" << lin.mult_x1 << " 0x" << lin.shift_x1 << std::endl;
298  }
299 
300  const std::vector<DetId> &eeCells = theEndcapGeometry_->getValidDetIds(DetId::Ecal, EcalEndcap);
301  std::cout << "COMMENT ====== endcap crystals ====== " << std::endl;
302  for (std::vector<DetId>::const_iterator it = eeCells.begin(); it != eeCells.end(); ++it) {
303  EEDetId id(*it);
304  std::cout << "CRYSTAL " << std::dec << id.rawId() << std::endl;
305  const EcalTPGPedestal &ped = pedMap[id.rawId()];
306  const EcalTPGLinearizationConstant &lin = linMap[id.rawId()];
307  std::cout << std::hex << " 0x" << ped.mean_x12 << " 0x" << lin.mult_x12 << " 0x" << lin.shift_x12 << std::endl;
308  std::cout << std::hex << " 0x" << ped.mean_x6 << " 0x" << lin.mult_x6 << " 0x" << lin.shift_x6 << std::endl;
309  std::cout << std::hex << " 0x" << ped.mean_x1 << " 0x" << lin.mult_x1 << " 0x" << lin.shift_x1 << std::endl;
310  }
311 }
313  std::cout << "COMMENT put your comments here\n"
314  << "COMMENT =================================\n"
315  << "COMMENT physics EB structure\n"
316  << "COMMENT\n"
317  << "COMMENT EtSaturation (GeV), ttf_threshold_Low (GeV), "
318  "ttf_threshold_High (GeV)\n"
319  << "COMMENT FG_lowThreshold (GeV), FG_highThreshold (GeV), "
320  "FG_lowRatio, FG_highRatio\n"
321  << "COMMENT =================================\n"
322  << "COMMENT\n"
323  << "COMMENT =================================\n"
324  << "COMMENT physics EE structure\n"
325  << "COMMENT\n"
326  << "COMMENT EtSaturation (GeV), ttf_threshold_Low (GeV), "
327  "ttf_threshold_High (GeV)\n"
328  << "COMMENT FG_Threshold (GeV), dummy, dummy, dummy\n"
329  << "COMMENT =================================\n"
330  << "COMMENT\n"
331  << "COMMENT =================================\n"
332  << "COMMENT crystal structure (same for EB and EE)\n"
333  << "COMMENT\n"
334  << "COMMENT ped, mult, shift [gain12]\n"
335  << "COMMENT ped, mult, shift [gain6]\n"
336  << "COMMENT ped, mult, shift [gain1]\n"
337  << "COMMENT =================================\n"
338  << "COMMENT\n"
339  << "COMMENT =================================\n"
340  << "COMMENT strip EB structure\n"
341  << "COMMENT\n"
342  << "COMMENT sliding_window\n"
343  << "COMMENT weightGroupId\n"
344  << "COMMENT threshold_sfg lut_sfg\n"
345  << "COMMENT =================================\n"
346  << "COMMENT\n"
347  << "COMMENT =================================\n"
348  << "COMMENT strip EE structure\n"
349  << "COMMENT\n"
350  << "COMMENT sliding_window\n"
351  << "COMMENT weightGroupId\n"
352  << "COMMENT threshold_fg lut_fg\n"
353  << "COMMENT =================================\n"
354  << "COMMENT\n"
355  << "COMMENT =================================\n"
356  << "COMMENT tower EB structure\n"
357  << "COMMENT\n"
358  << "COMMENT LUTGroupId\n"
359  << "COMMENT FgGroupId\n"
360  << "COMMENT spike_killing_threshold\n"
361  << "COMMENT =================================\n"
362  << "COMMENT\n"
363  << "COMMENT =================================\n"
364  << "COMMENT tower EE structure\n"
365  << "COMMENT\n"
366  << "COMMENT LUTGroupId\n"
367  << "COMMENT tower_lut_fg\n"
368  << "COMMENT =================================\n"
369  << "COMMENT\n"
370  << "COMMENT =================================\n"
371  << "COMMENT Weight structure\n"
372  << "COMMENT\n"
373  << "COMMENT weightGroupId\n"
374  << "COMMENT w0, w1, w2, w3, w4\n"
375  << "COMMENT =================================\n"
376  << "COMMENT\n"
377  << "COMMENT =================================\n"
378  << "COMMENT lut structure\n"
379  << "COMMENT\n"
380  << "COMMENT LUTGroupId\n"
381  << "COMMENT LUT[1-1024]\n"
382  << "COMMENT =================================\n"
383  << "COMMENT\n"
384  << "COMMENT =================================\n"
385  << "COMMENT fg EB structure\n"
386  << "COMMENT\n"
387  << "COMMENT FgGroupId\n"
388  << "COMMENT el, eh, tl, th, lut_fg\n"
389  << "COMMENT =================================\n"
390  << "COMMENT" << std::endl;
391 }
392 
393 /*void EcalTPCondAnalyzer::printTOWEREB(const EcalTPGFineGrainEBGroup
394 *ecaltpgFgEBGroup,const EcalTPGLutGroup *ecaltpgLutGroup) const {
395 
396  const EcalTPGGroups::EcalTPGGroupsMap &lutMap=ecaltpgLutGroup->getMap();
397  EcalTPGGroups::EcalTPGGroupsMapItr lutGroupId;
398  const EcalTPGGroups::EcalTPGGroupsMap &fgMap=ecaltpgFgEBGroup->getMap();
399  EcalTPGGroups::EcalTPGGroupsMapItr it;
400 
401  std::cout<<std::endl;
402  for (it=fgMap.begin();it!=fgMap.end();++it) {
403  std::cout <<"TOWER_EB "<<std::dec<<(*it).first<<std::endl;
404  lutGroupId=lutMap.find((*it).first);
405  std::cout <<" "<<(*it).second<<std::endl;
406  std::cout <<" "<<(*lutGroupId).second<<std::endl;
407  }
408 }
409 */
410 
412  const EcalTPGFineGrainEBGroup *ecaltpgFgEBGroup,
413  const EcalTPGLutGroup *ecaltpgLutGroup) const {
414  const EcalTPGGroups::EcalTPGGroupsMap &lutMap = ecaltpgLutGroup->getMap();
416  const EcalTPGGroups::EcalTPGGroupsMap &fgMap = ecaltpgFgEBGroup->getMap();
418 
419  const EcalTPGSpike::EcalTPGSpikeMap &spikeThMap = ecaltpgSpikeTh->getMap();
421 
422  std::cout << std::endl;
423  for (it = fgMap.begin(); it != fgMap.end(); ++it) {
424  std::cout << "TOWER_EB " << std::dec << (*it).first << std::endl;
425  lutGroupId = lutMap.find((*it).first);
426  itSpikeTh = spikeThMap.find((*it).first);
427  std::cout << " " << (*it).second << std::endl;
428  std::cout << " " << (*lutGroupId).second << std::endl;
429  std::cout << " " << (*itSpikeTh).second << std::endl;
430  }
431 }
432 
433 void EcalTPCondAnalyzer::printTOWEREE(const EcalTPGFineGrainTowerEE *ecaltpgFineGrainTowerEE,
434  const EcalTPGLutGroup *ecaltpgLutGroup) const {
436  const EcalTPGFineGrainTowerEEMap &map = ecaltpgFineGrainTowerEE->getMap();
437  const EcalTPGGroups::EcalTPGGroupsMap &lutMap = ecaltpgLutGroup->getMap();
439 
440  std::cout << std::endl;
441  for (it = map.begin(); it != map.end(); ++it) {
442  std::cout << "TOWER_EE " << std::dec << (*it).first << std::endl;
443  lutGroupId = lutMap.find((*it).first);
444  std::cout << " " << (*lutGroupId).second << std::endl;
445  std::cout << std::hex << "0x" << (*it).second << std::endl;
446  }
447 }
448 
449 /*void EcalTPCondAnalyzer::printBadX(const EcalTPGCrystalStatus *ecaltpgBadX)
450 const {
451 
452  std::ofstream myfile;
453  myfile.open("badXvalues.txt");
454 
455  const EcalTPGCrystalStatusMap & badXMap = ecaltpgBadX->getMap();
456 
457  const std::vector<DetId> & ebCells =
458 theBarrelGeometry_->getValidDetIds(DetId::Ecal, EcalBarrel);
459 
460  myfile <<"COMMENT ====== barrel masked crystals ====== "<<std::endl;
461  myfile << "RawId eta phi " << std::endl;
462 
463  for (std::vector<DetId>::const_iterator it = ebCells.begin(); it !=
464 ebCells.end(); ++it) {
465 
466  EBDetId id(*it) ;
467  const EcalTPGCrystalStatusCode &badXeb=badXMap[id.rawId()];
468  // Print in the text file obly the masked crystals
469  if (badXeb.getStatusCode() != 0){
470  myfile << "" << id.rawId() << " " << id.ieta() << " " <<
471 id.iphi() << std::endl;
472  }
473 
474  }
475 
476  myfile << " " << std::endl;
477 
478  const std::vector<DetId> & eeCells =
479 theEndcapGeometry_->getValidDetIds(DetId::Ecal, EcalEndcap);
480 
481  myfile <<"COMMENT ====== endcap masked crystals ====== "<<std::endl;
482  myfile << "RawId x y z " << std::endl;
483 
484  for (std::vector<DetId>::const_iterator it = eeCells.begin(); it !=
485 eeCells.end(); ++it) {
486 
487  EEDetId id(*it) ;
488  const EcalTPGCrystalStatusCode &badXee=badXMap[id.rawId()];
489  // Print in the text file only the masked clystals
490  if (badXee.getStatusCode() != 0){
491  myfile << "" << id.rawId() << " " << id.ix() << " " << id.iy() << "
492 "<< id.zside() << std::endl;
493  }
494  }
495 
496  myfile.close();
497 }
498 */
499 
500 /*void EcalTPCondAnalyzer::printBadTT(const EcalTPGTowerStatus *ecaltpgBadTT)
501 const { std::ofstream myfilebadTT; myfilebadTT.open("badTTvalues.txt"); int ieta
502 = 0; int iphi = 0;
503 
504  const EcalTPGTowerStatusMap & badTTMap = ecaltpgBadTT -> getMap();
505  EcalTPGTowerStatusMapIterator it;
506 
507  myfilebadTT <<"Barrel and endcap masked Trigger Towers"<<std::endl;
508  myfilebadTT <<"RawId " << " iphi " << " ieta " << std::endl;
509  myfilebadTT <<""<< std::endl;
510 
511  for (it=badTTMap.begin();it!=badTTMap.end();++it) {
512 
513  // Print in the text file only the masked barrel and endcap TTs
514  if ((*it).second != 0){
515 
516  EcalTrigTowerDetId ttId((*it).first);
517  ieta = ttId.ieta();
518  iphi = ttId.iphi();
519 
520  myfilebadTT <<""<< std::dec<<(*it).first << " " << iphi << " " <<
521 ieta << std::endl;
522 
523  }
524  }
525 
526 
527  myfilebadTT.close();
528 
529 }
530 */
EcalCondObjectContainer::getMap
const self & getMap() const
Definition: EcalCondObjectContainer.h:78
edm::ESHandle::product
T const * product() const
Definition: ESHandle.h:86
EcalTPGFineGrainStripEEMapIterator
std::map< uint32_t, EcalTPGFineGrainStripEE::Item >::const_iterator EcalTPGFineGrainStripEEMapIterator
Definition: EcalTPGFineGrainStripEE.h:31
EcalTPGLutGroupRcd.h
w2
common ppss p3p6s2 common epss epspn46 common const1 w2
Definition: inclppp.h:1
EcalTPGWeightIdMap
Definition: EcalTPGWeightIdMap.h:10
mps_fire.i
i
Definition: mps_fire.py:428
EcalTPGLinearizationConstant::shift_x1
uint32_t shift_x1
Definition: EcalTPGLinearizationConst.h:16
EcalTPGSlidingWindow::getMap
const std::map< uint32_t, uint32_t > & getMap() const
Definition: EcalTPGSlidingWindow.h:14
EcalTPGPedestal::mean_x1
uint32_t mean_x1
Definition: EcalTPGPedestals.h:12
EcalTPGLutIdMap::EcalTPGLutMap
std::map< uint32_t, EcalTPGLut > EcalTPGLutMap
Definition: EcalTPGLutIdMap.h:12
EcalTPGFineGrainTowerEERcd
Definition: EcalTPGFineGrainTowerEERcd.h:5
EcalTPGStripStatusRcd.h
EcalTPGGroups::EcalTPGGroupsMapItr
std::map< uint32_t, uint32_t >::const_iterator EcalTPGGroupsMapItr
Definition: EcalTPGGroups.h:20
ESHandle.h
EcalTriggerElectronicsId
Ecal trigger electronics identification [32:20] Unused (so far) [19:13] TCC id [12:6] TT id [5:3] pse...
Definition: EcalTriggerElectronicsId.h:18
EcalTPGLinearizationConstRcd.h
EcalTPGLinearizationConstant::mult_x6
uint32_t mult_x6
Definition: EcalTPGLinearizationConst.h:12
edm::Run
Definition: Run.h:45
EcalTPGSpikeRcd.h
EcalTPGSpike
Definition: EcalTPGSpike.h:9
EBDetId
Definition: EBDetId.h:17
EcalTPCondAnalyzer::printEcalTPGPhysicsConst
void printEcalTPGPhysicsConst(const EcalTPGPhysicsConst *) const
Definition: EcalTPCondAnalyzer.cc:175
EcalTPCondAnalyzer::printTOWEREE
void printTOWEREE(const EcalTPGFineGrainTowerEE *ecaltpgFineGrainTowerEE, const EcalTPGLutGroup *ecaltpgLutGroup) const
Definition: EcalTPCondAnalyzer.cc:433
EcalTPGFineGrainStripEE
Definition: EcalTPGFineGrainStripEE.h:9
gather_cfg.cout
cout
Definition: gather_cfg.py:144
EcalTPGFineGrainEBIdMap
Definition: EcalTPGFineGrainEBIdMap.h:10
EcalEndcapGeometryRecord
Definition: EcalEndcapGeometryRecord.h:23
EcalTPGWeightIdMap::EcalTPGWeightMapItr
std::map< uint32_t, EcalTPGWeights >::const_iterator EcalTPGWeightMapItr
Definition: EcalTPGWeightIdMap.h:13
EcalTPGPedestalsRcd
Definition: EcalTPGPedestalsRcd.h:5
EcalTPGFineGrainStripEE::Item
Definition: EcalTPGFineGrainStripEE.h:14
EcalTPGWeightIdMap::EcalTPGWeightMap
std::map< uint32_t, EcalTPGWeights > EcalTPGWeightMap
Definition: EcalTPGWeightIdMap.h:12
EcalTPGCrystalStatusRcd.h
EcalTPGPedestal
Definition: EcalTPGPedestals.h:8
EDAnalyzer.h
EcalTPCondAnalyzer::analyze
void analyze(const edm::Event &, const edm::EventSetup &) override
Definition: EcalTPCondAnalyzer.cc:171
EcalTPGLinearizationConstant
Definition: EcalTPGLinearizationConst.h:8
EcalTPGWeightGroup
Definition: EcalTPGWeightGroup.h:8
EcalCondObjectContainer
Definition: EcalCondObjectContainer.h:13
EcalTPCondAnalyzer.h
edm::LogWarning
Log< level::Warning, false > LogWarning
Definition: MessageLogger.h:122
EcalTPGFineGrainStripEERcd
Definition: EcalTPGFineGrainStripEERcd.h:5
EcalBarrelGeometryRecord
Definition: EcalBarrelGeometryRecord.h:23
EcalBarrel
Definition: EcalSubdetector.h:10
singleTopDQM_cfi.setup
setup
Definition: singleTopDQM_cfi.py:37
EcalTPGLutGroup
Definition: EcalTPGLutGroup.h:13
EcalTPGFineGrainTowerEE::getMap
const std::map< uint32_t, uint32_t > & getMap() const
Definition: EcalTPGFineGrainTowerEE.h:15
MakerMacros.h
EcalTPGSlidingWindow
Definition: EcalTPGSlidingWindow.h:9
EcalTPGFineGrainTowerEE
Definition: EcalTPGFineGrainTowerEE.h:9
EcalTPGSpike::getMap
const std::map< uint32_t, uint16_t > & getMap() const
Definition: EcalTPGSpike.h:18
EcalTPCondAnalyzer::beginRun
void beginRun(const edm::Run &run, const edm::EventSetup &es)
Definition: EcalTPCondAnalyzer.cc:58
edm::EventSetup::get
T get() const
Definition: EventSetup.h:87
EcalTPGFineGrainTowerEEMapIterator
std::map< uint32_t, uint32_t >::const_iterator EcalTPGFineGrainTowerEEMapIterator
Definition: EcalTPGFineGrainTowerEE.h:25
EcalTPCondAnalyzer::printComment
void printComment() const
Definition: EcalTPCondAnalyzer.cc:312
EcalTPCondAnalyzer::endJob
void endJob() override
Definition: EcalTPCondAnalyzer.cc:173
EcalTPGFineGrainTowerEEMap
std::map< uint32_t, uint32_t > EcalTPGFineGrainTowerEEMap
Definition: EcalTPGFineGrainTowerEE.h:24
EcalTPCondAnalyzer::beginJob
void beginJob() override
Definition: EcalTPCondAnalyzer.cc:70
edm::ESHandle< CaloSubdetectorGeometry >
EcalTPGSpikeRcd
Definition: EcalTPGSpikeRcd.h:5
EcalTPCondAnalyzer::printEcalTPGLutIdMap
void printEcalTPGLutIdMap(const EcalTPGLutIdMap *ecaltpgLut) const
Definition: EcalTPCondAnalyzer.cc:269
EcalTPGFineGrainEBGroupRcd
Definition: EcalTPGFineGrainEBGroupRcd.h:5
EcalTPGWeightIdMapRcd.h
EcalTPCondAnalyzer::~EcalTPCondAnalyzer
~EcalTPCondAnalyzer() override
Definition: EcalTPCondAnalyzer.cc:72
EcalTPCondAnalyzer::printWEIGHT
void printWEIGHT(const EcalTPGWeightIdMap *ecaltpgWeightMap) const
Definition: EcalTPCondAnalyzer.cc:241
EcalTPGSlidingWindowMapIterator
std::map< uint32_t, uint32_t >::const_iterator EcalTPGSlidingWindowMapIterator
Definition: EcalTPGSlidingWindow.h:24
EcalTPGSlidingWindowRcd.h
CaloSubdetectorGeometry::getValidDetIds
virtual const std::vector< DetId > & getValidDetIds(DetId::Detector det=DetId::Detector(0), int subdet=0) const
Get a list of valid detector ids (for the given subdetector)
Definition: CaloSubdetectorGeometry.cc:32
w4
common ppss p3p6s2 common epss epspn46 common const1 w4
Definition: inclppp.h:1
EcalTPGFineGrainEBGroupRcd.h
EEDetId
Definition: EEDetId.h:14
CaloGeometryRecord.h
EcalTPGLutIdMap
Definition: EcalTPGLutIdMap.h:10
EcalTrigTowerDetId.h
EcalEndcap
Definition: EcalSubdetector.h:10
EcalTPCondAnalyzer::printSTRIP
void printSTRIP(const EcalTPGSlidingWindow *ecaltpgSlidW, const EcalTPGWeightGroup *ecaltpgWeightGroup, const EcalTPGFineGrainStripEE *ecaltpgFgStripEE) const
Definition: EcalTPCondAnalyzer.cc:191
EcalTPGPhysicsConst::getMap
const std::map< uint32_t, Item > & getMap() const
Definition: EcalTPGPhysicsConst.h:27
EcalTPGSlidingWindowMap
std::map< uint32_t, uint32_t > EcalTPGSlidingWindowMap
Definition: EcalTPGSlidingWindow.h:23
CaloSubdetectorGeometry.h
edm::ParameterSet
Definition: ParameterSet.h:47
EcalTPGFineGrainStripEE::getMap
const std::map< uint32_t, Item > & getMap() const
Definition: EcalTPGFineGrainStripEE.h:21
Event.h
EcalTPGFineGrainEBGroup
Definition: EcalTPGFineGrainEBGroup.h:13
EcalTPGLinearizationConstant::mult_x12
uint32_t mult_x12
Definition: EcalTPGLinearizationConst.h:11
EcalTPGLinearizationConstant::mult_x1
uint32_t mult_x1
Definition: EcalTPGLinearizationConst.h:13
EcalTPCondAnalyzer::theBarrelGeometry_
const CaloSubdetectorGeometry * theBarrelGeometry_
Definition: EcalTPCondAnalyzer.h:69
EcalTPGPedestal::mean_x6
uint32_t mean_x6
Definition: EcalTPGPedestals.h:11
EcalTPGFineGrainEBIdMapRcd
Definition: EcalTPGFineGrainEBIdMapRcd.h:5
iEvent
int iEvent
Definition: GenABIO.cc:224
EcalTPCondAnalyzer::theEndcapGeometry_
const CaloSubdetectorGeometry * theEndcapGeometry_
Definition: EcalTPCondAnalyzer.h:68
EcalTriggerElectronicsId.h
w3
common ppss p3p6s2 common epss epspn46 common const1 w3
Definition: inclppp.h:1
EcalTPCondAnalyzer::printEcalTPGFineGrainEBIdMap
void printEcalTPGFineGrainEBIdMap(const EcalTPGFineGrainEBIdMap *ecaltpgFineGrainEB) const
Definition: EcalTPCondAnalyzer.cc:255
EcalTPGGroups::getMap
const EcalTPGGroupsMap & getMap() const
Definition: EcalTPGGroups.h:25
EcalTPGLinearizationConstant::shift_x6
uint32_t shift_x6
Definition: EcalTPGLinearizationConst.h:15
EcalTriggerElectronicsId::subdet
EcalSubdetector subdet() const
get the subdet
Definition: EcalTriggerElectronicsId.cc:32
B2GTnPMonitor_cfi.item
item
Definition: B2GTnPMonitor_cfi.py:147
edm::EventSetup
Definition: EventSetup.h:58
EcalTPGFineGrainStripEEMap
std::map< uint32_t, EcalTPGFineGrainStripEE::Item > EcalTPGFineGrainStripEEMap
Definition: EcalTPGFineGrainStripEE.h:30
EcalTPGLinearizationConstant::shift_x12
uint32_t shift_x12
Definition: EcalTPGLinearizationConst.h:14
DetId::Ecal
Definition: DetId.h:27
get
#define get
EcalTPGFineGrainEBIdMapRcd.h
EcalTPGFineGrainTowerEERcd.h
EcalTPGWeightGroupRcd
Definition: EcalTPGWeightGroupRcd.h:5
EcalTPGPhysicsConst
Definition: EcalTPGPhysicsConst.h:9
EcalTPGPhysicsConstMap
std::map< uint32_t, EcalTPGPhysicsConst::Item > EcalTPGPhysicsConstMap
Definition: EcalTPGPhysicsConst.h:36
EcalTPGLutIdMapRcd
Definition: EcalTPGLutIdMapRcd.h:5
writedatasetfile.run
run
Definition: writedatasetfile.py:27
EcalTPGWeightIdMapRcd
Definition: EcalTPGWeightIdMapRcd.h:5
LUT
std::vector< unsigned short int > LUT
Definition: DTTracoLUTs.h:31
triggerObjects_cff.id
id
Definition: triggerObjects_cff.py:29
EcalTPGSlidingWindowRcd
Definition: EcalTPGSlidingWindowRcd.h:5
EcalTPGLutIdMapRcd.h
EcalTPGLutIdMap::EcalTPGLutMapItr
std::map< uint32_t, EcalTPGLut >::const_iterator EcalTPGLutMapItr
Definition: EcalTPGLutIdMap.h:13
EcalTPCondAnalyzer::EcalTPCondAnalyzer
EcalTPCondAnalyzer(const edm::ParameterSet &)
Definition: EcalTPCondAnalyzer.cc:54
EcalTPGTowerStatusRcd.h
EcalTPCondAnalyzer::printTOWEREB
void printTOWEREB(const EcalTPGSpike *ecaltpgSpike, const EcalTPGFineGrainEBGroup *ecaltpgFgEBGroup, const EcalTPGLutGroup *ecaltpgLutGroup) const
Definition: EcalTPCondAnalyzer.cc:411
EcalTPGWeightGroupRcd.h
EcalTPGFineGrainEBIdMap::EcalTPGFineGrainEBMap
std::map< uint32_t, EcalTPGFineGrainConstEB > EcalTPGFineGrainEBMap
Definition: EcalTPGFineGrainEBIdMap.h:12
EcalTPGFineGrainEBIdMap::EcalTPGFineGrainEBMapItr
std::map< uint32_t, EcalTPGFineGrainConstEB >::const_iterator EcalTPGFineGrainEBMapItr
Definition: EcalTPGFineGrainEBIdMap.h:13
EcalTPGPedestalsRcd.h
EcalTPCondAnalyzer::getRecords
unsigned long long getRecords(edm::EventSetup const &setup)
Definition: EcalTPCondAnalyzer.cc:74
genParticles_cff.map
map
Definition: genParticles_cff.py:11
EcalTPGFineGrainEBIdMap::getMap
const EcalTPGFineGrainEBMap & getMap() const
Definition: EcalTPGFineGrainEBIdMap.h:18
EcalTPGLutGroupRcd
Definition: EcalTPGLutGroupRcd.h:5
EcalTPGSpike::EcalTPGSpikeMapIterator
std::map< uint32_t, uint16_t >::const_iterator EcalTPGSpikeMapIterator
Definition: EcalTPGSpike.h:12
EcalTPGPhysicsConstRcd.h
edm::Event
Definition: Event.h:73
EcalTPCondAnalyzer::printCRYSTAL
void printCRYSTAL(const EcalTPGPedestals *ecaltpPed, const EcalTPGLinearizationConst *ecaltpLin)
Definition: EcalTPCondAnalyzer.cc:282
EcalTPGLinearizationConstRcd
Definition: EcalTPGLinearizationConstRcd.h:5
EcalTPGPhysicsConstMapIterator
std::map< uint32_t, EcalTPGPhysicsConst::Item >::const_iterator EcalTPGPhysicsConstMapIterator
Definition: EcalTPGPhysicsConst.h:37
TauDecayModes.dec
dec
Definition: TauDecayModes.py:143
EcalTPGPhysicsConstRcd
Definition: EcalTPGPhysicsConstRcd.h:5
EcalTPGLutIdMap::getMap
const EcalTPGLutMap & getMap() const
Definition: EcalTPGLutIdMap.h:18
EcalTPGPedestal::mean_x12
uint32_t mean_x12
Definition: EcalTPGPedestals.h:10
EcalTPGFineGrainStripEERcd.h
EcalTPCondAnalyzer::cacheID_
unsigned long long cacheID_
Definition: EcalTPCondAnalyzer.h:66
EcalTPGSpike::EcalTPGSpikeMap
std::map< uint32_t, uint16_t > EcalTPGSpikeMap
Definition: EcalTPGSpike.h:11
EcalTPGGroups::EcalTPGGroupsMap
std::map< uint32_t, uint32_t > EcalTPGGroupsMap
Definition: EcalTPGGroups.h:19
EcalTPGWeightIdMap::getMap
const EcalTPGWeightMap & getMap() const
Definition: EcalTPGWeightIdMap.h:18