CMS 3D CMS Logo

ClusterTask.cc
Go to the documentation of this file.
2 
16 
17 namespace ecaldqm {
19  : DQWorkerTask(),
20  ebHits_(nullptr),
21  eeHits_(nullptr),
22  // ievt_(0),
23  // massCalcPrescale_(_workerParams.getUntrackedParameter<int>("massCalcPrescale")),
24  doExtra_(true),
25  energyThreshold_(0.),
26  swissCrossMaxThreshold_(3.),
27  egTriggerAlgos_(),
28  trigTypeToME_{0, 1, 2, 3, 4},
29  L1GlobalTriggerReadoutRecordTag_(),
30  L1MuGMTReadoutCollectionTag_(),
31  L1GlobalTriggerReadoutRecordToken_(),
32  L1MuGMTReadoutCollectionToken_() {}
33 
35  doExtra_ = _params.getUntrackedParameter<bool>("doExtra");
36 
37  if (!doExtra_) {
38  MEs_.erase(std::string("SCSizeVsEnergy"));
39  MEs_.erase(std::string("SCSeedOccupancyHighE"));
40  MEs_.erase(std::string("SCSeedOccupancyTrig"));
41  MEs_.erase(std::string("SCSeedTimeTrigEx"));
42  MEs_.erase(std::string("SCSeedTimeMapTrigEx"));
43  MEs_.erase(std::string("SCOccupancyProjEta"));
44  MEs_.erase(std::string("SCOccupancyProjPhi"));
45  MEs_.erase(std::string("SCSwissCross"));
46  MEs_.erase(std::string("Triggers"));
47  MEs_.erase(std::string("ExclusiveTriggers"));
48 
49  return;
50  }
51 
52  energyThreshold_ = _params.getUntrackedParameter<double>("energyThreshold");
53  swissCrossMaxThreshold_ = _params.getUntrackedParameter<double>("swissCrossMaxThreshold");
54  egTriggerAlgos_ = _params.getUntrackedParameter<std::vector<std::string> >("egTriggerAlgos");
55  L1GlobalTriggerReadoutRecordTag_ = _params.getUntrackedParameter<edm::InputTag>("L1GlobalTriggerReadoutRecordTag");
56  L1MuGMTReadoutCollectionTag_ = _params.getUntrackedParameter<edm::InputTag>("L1MuGMTReadoutCollectionTag");
57 
59 
60  std::string triggerTypeNames[nTriggerTypes] = {"ECAL", "HCAL", "CSC", "DT", "RPC"};
61 
62  MESetMulti& occupancy(static_cast<MESetMulti&>(MEs_.at("SCSeedOccupancyTrig")));
63  for (unsigned iT(0); iT != nTriggerTypes; ++iT) {
64  repl["trig"] = triggerTypeNames[iT];
65  trigTypeToME_[iT] = occupancy.getIndex(repl);
66  }
67  }
68 
72  }
73 
74  void ClusterTask::beginEvent(edm::Event const& _evt, edm::EventSetup const& _es, bool const&, bool&) {
75  if (!doExtra_)
76  return;
77 
78  triggered_.reset();
79 
80  // TODO IS THIS THE MOST UP-TO-DATE ACCESSOR TO L1 INFO?
81 
84  DecisionWord const& dWord(l1GTHndl->decisionWord());
85 
86  //Ecal
87 
88  L1GtTriggerMenu const* menu(&_es.getData(menuRcd));
89 
90  if (!dWord.empty()) { //protect against no L1GT in run
91  for (unsigned iT(0); iT != egTriggerAlgos_.size(); ++iT) {
92  if (menu->gtAlgorithmResult(egTriggerAlgos_[iT], dWord)) {
94  break;
95  }
96  }
97  }
98 
99  //Hcal
100  bool hcal_top = false;
101  bool hcal_bot = false;
102  const L1GtPsbWord psb = l1GTHndl->gtPsbWord(0xbb0d, 0);
103  std::vector<int> valid_phi;
104  if ((psb.aData(4) & 0x3f) >= 1) {
105  valid_phi.push_back((psb.aData(4) >> 10) & 0x1f);
106  }
107  if ((psb.bData(4) & 0x3f) >= 1) {
108  valid_phi.push_back((psb.bData(4) >> 10) & 0x1f);
109  }
110  if ((psb.aData(5) & 0x3f) >= 1) {
111  valid_phi.push_back((psb.aData(5) >> 10) & 0x1f);
112  }
113  if ((psb.bData(5) & 0x3f) >= 1) {
114  valid_phi.push_back((psb.bData(5) >> 10) & 0x1f);
115  }
116  std::vector<int>::const_iterator iphi;
117  for (iphi = valid_phi.begin(); iphi != valid_phi.end(); iphi++) {
118  if (*iphi < 9)
119  hcal_top = true;
120  if (*iphi > 8)
121  hcal_bot = true;
122  }
123  if (hcal_top && hcal_bot)
125 
126  //Muons
128  if (!_evt.getByToken(L1MuGMTReadoutCollectionToken_, l1MuHndl))
129  return;
130  std::vector<L1MuGMTReadoutRecord> const& records(l1MuHndl->getRecords());
131 
132  for (unsigned iR(0); iR != records.size(); ++iR) {
133  if (records[iR].getBxInEvent() != 0)
134  continue;
135 
136  unsigned iC(0);
137 
138  //DT triggers
139  std::vector<L1MuRegionalCand> dtBXCands(records[iR].getDTBXCands());
140  for (iC = 0; iC != dtBXCands.size(); ++iC)
141  if (!dtBXCands[iC].empty())
142  break;
143  if (iC != dtBXCands.size())
144  triggered_.set(kDTTrigger);
145 
146  //RPC triggers
147  std::vector<L1MuRegionalCand> brlRPCCands(records[iR].getBrlRPCCands());
148  for (iC = 0; iC != brlRPCCands.size(); ++iC)
149  if (!brlRPCCands[iC].empty())
150  break;
151  if (iC != brlRPCCands.size())
152  triggered_.set(kRPCTrigger);
153 
154  //CSC Triggers
155  std::vector<L1MuRegionalCand> cscCands(records[iR].getCSCCands());
156  for (iC = 0; iC != cscCands.size(); ++iC)
157  if (!cscCands[iC].empty())
158  break;
159  if (iC != cscCands.size())
160  triggered_.set(kCSCTrigger);
161  }
162 
163  if (triggered_.none())
164  return;
165 
166  MESet& meTriggers(MEs_.at("Triggers"));
167  MESet& meExclusiveTriggers(MEs_.at("ExclusiveTriggers"));
168 
169  for (unsigned iT(0); iT != nTriggerTypes; ++iT) {
170  if (!triggered_[iT])
171  continue;
172  meTriggers.fill(getEcalDQMSetupObjects(), iT + 0.5);
173  if (triggered_.count() == 1)
174  meExclusiveTriggers.fill(getEcalDQMSetupObjects(), iT + 0.5);
175  }
176  }
177 
179  // ++ievt_;
180 
181  ebHits_ = nullptr;
182  eeHits_ = nullptr;
183  }
184 
185  bool ClusterTask::filterRunType(short const* _runType) {
186  for (unsigned iFED(0); iFED != nDCC; iFED++) {
187  if (_runType[iFED] == EcalDCCHeaderBlock::COSMIC || _runType[iFED] == EcalDCCHeaderBlock::MTCC ||
188  _runType[iFED] == EcalDCCHeaderBlock::COSMICS_GLOBAL ||
189  _runType[iFED] == EcalDCCHeaderBlock::PHYSICS_GLOBAL || _runType[iFED] == EcalDCCHeaderBlock::COSMICS_LOCAL ||
190  _runType[iFED] == EcalDCCHeaderBlock::PHYSICS_LOCAL)
191  return true;
192  }
193 
194  return false;
195  }
196 
198  switch (_collection) {
199  case kEBRecHit:
200  ebHits_ = &_hits;
201  break;
202  case kEERecHit:
203  eeHits_ = &_hits;
204  break;
205  default:
206  break;
207  }
208  }
209 
211  MESet& meBCE(MEs_.at("BCE"));
212  MESet& meBCEMap(MEs_.at("BCEMap"));
213  MESet& meBCEMapProjEta(MEs_.at("BCEMapProjEta"));
214  MESet& meBCEMapProjPhi(MEs_.at("BCEMapProjPhi"));
215  MESet& meBCEtMapProjEta(MEs_.at("BCEtMapProjEta"));
216  MESet& meBCEtMapProjPhi(MEs_.at("BCEtMapProjPhi"));
217  MESet& meBCOccupancy(MEs_.at("BCOccupancy"));
218  MESet& meBCOccupancyProjEta(MEs_.at("BCOccupancyProjEta"));
219  MESet& meBCOccupancyProjPhi(MEs_.at("BCOccupancyProjPhi"));
220  MESet& meBCSize(MEs_.at("BCSize"));
221  MESet& meTrendBCSize(MEs_.at("TrendBCSize"));
222  MESet& meBCSizeMap(MEs_.at("BCSizeMap"));
223  MESet& meBCSizeMapProjEta(MEs_.at("BCSizeMapProjEta"));
224  MESet& meBCSizeMapProjPhi(MEs_.at("BCSizeMapProjPhi"));
225  MESet& meBCNum(MEs_.at("BCNum"));
226  MESet& meTrendNBC(MEs_.at("TrendNBC"));
227 
228  int nBC[] = {0, 0};
229  bool isBarrel(_collection == kEBBasicCluster);
230 
231  // vector<reco::BasicCluster const*> lowMassCands;
232 
233  for (edm::View<reco::CaloCluster>::const_iterator bcItr(_bcs.begin()); bcItr != _bcs.end(); ++bcItr) {
234  if (bcItr->caloID().detectors() != 0) {
235  if (isBarrel && !bcItr->caloID().detector(reco::CaloID::DET_ECAL_BARREL))
236  continue;
237  if (!isBarrel && !bcItr->caloID().detector(reco::CaloID::DET_ECAL_ENDCAP))
238  continue;
239  }
240 
241  math::XYZPoint const& position(bcItr->position());
242 
243  DetId id(bcItr->seed());
244  if (id.null()) {
245  GlobalPoint gp(position.x(), position.y(), position.z());
246  CaloSubdetectorGeometry const* subgeom(
247  GetGeometry()->getSubdetectorGeometry(DetId::Ecal, isBarrel ? EcalBarrel : EcalEndcap));
248 
249  id = subgeom->getClosestCell(gp);
250  }
251 
252  if (id.null() || (id.subdetId() == EcalBarrel && !isBarrel) || (id.subdetId() == EcalEndcap && isBarrel))
253  continue;
254 
255  float energy(bcItr->energy());
256  float posEta(position.eta());
257  float posPhi(phi(position.phi()));
258  float et(energy / std::cosh(posEta));
259  int subdet(isBarrel ? EcalBarrel : EcalEndcap);
260  if (subdet == EcalEndcap && position.z() < 0.)
261  subdet = -EcalEndcap;
262 
263  meBCE.fill(getEcalDQMSetupObjects(), id, energy);
264 
265  meBCEMap.fill(getEcalDQMSetupObjects(), id, energy);
266  meBCEMapProjEta.fill(getEcalDQMSetupObjects(), posEta, energy);
267  meBCEMapProjPhi.fill(getEcalDQMSetupObjects(), subdet, posPhi, energy);
268  meBCEtMapProjEta.fill(getEcalDQMSetupObjects(), posEta, et);
269  meBCEtMapProjPhi.fill(getEcalDQMSetupObjects(), subdet, posPhi, et);
270 
271  meBCOccupancy.fill(getEcalDQMSetupObjects(), id);
272  meBCOccupancyProjEta.fill(getEcalDQMSetupObjects(), posEta);
273  meBCOccupancyProjPhi.fill(getEcalDQMSetupObjects(), subdet, posPhi);
274 
275  float size(bcItr->size());
276 
277  meBCSize.fill(getEcalDQMSetupObjects(), id, size);
278  meTrendBCSize.fill(getEcalDQMSetupObjects(), id, double(timestamp_.iLumi), size);
279 
280  meBCSizeMap.fill(getEcalDQMSetupObjects(), id, size);
281  meBCSizeMapProjEta.fill(getEcalDQMSetupObjects(), posEta, size);
282  meBCSizeMapProjPhi.fill(getEcalDQMSetupObjects(), subdet, posPhi, size);
283 
284  int zside(position.z() > 0 ? 1 : 0);
285  nBC[zside]++;
286 
287  // if(ievt_ % massCalcPrescale_ != 0) continue;
288 
289  // if(energy > 10.) continue;
290 
291  // EcalRecHitCollection::const_iterator hitItr(isBarrel ? ebHits_->find(id) : eeHits_->find(id));
292  // if(hitItr == (isBarrel ? ebHits_->end() : eeHits_->end())) continue;
293 
294  // // cuts here must be parametrized
295  // if(hitItr->energy() < 0.5) continue;
296 
297  // if(hitItr->energy() / energy > 0.95) continue;
298 
299  // lowMassCands.push_back(&(*bcItr));
300  }
301 
302  if (isBarrel) {
303  meBCNum.fill(getEcalDQMSetupObjects(), EcalBarrel, nBC[0] + nBC[1]);
304  meTrendNBC.fill(getEcalDQMSetupObjects(), EcalBarrel, double(timestamp_.iLumi), nBC[0] + nBC[1]);
305  } else {
306  meBCNum.fill(getEcalDQMSetupObjects(), -EcalEndcap, nBC[0]);
307  meBCNum.fill(getEcalDQMSetupObjects(), EcalEndcap, nBC[1]);
308  meTrendNBC.fill(getEcalDQMSetupObjects(), EcalEndcap, double(timestamp_.iLumi), nBC[0] + nBC[1]);
309  }
310 
311  // if(ievt_ % massCalcPrescale_ != 0) return;
312 
313  // double const pi(3.14159265);
314 
315  // for(vector<reco::BasicCluster const*>::iterator bcItr1(lowMassCands.begin()); bcItr1 != lowMassCands.end(); ++bcItr1){
316  // reco::BasicCluster const& bc1(**bcItr1);
317  // float energy1(bc1.energy());
318  // float px1(energy1 * sin(bc1.position().theta()) * cos(bc1.phi()));
319  // float py1(energy1 * sin(bc1.position().theta()) * sin(bc1.phi()));
320  // float pz1(energy1 * cos(bc1.position().theta()));
321 
322  // for(vector<reco::BasicCluster const*>::iterator bcItr2(lowMassCands.begin()); bcItr2 != lowMassCands.end(); ++bcItr2){
323  // if(*bcItr1 == *bcItr2) continue;
324  // reco::BasicCluster const& bc2(**bcItr2);
325  // float energy2(bc2.energy());
326  // float px2(energy2 * sin(bc2.position().theta()) * cos(bc2.phi()));
327  // float py2(energy2 * sin(bc2.position().theta()) * sin(bc2.phi()));
328  // float pz2(energy2 * cos(bc2.position().theta()));
329 
330  // float ptpair(sqrt((px1 + px2) * (px1 + px2) + (py1 + py2) * (py1 + py2)));
331  // if(ptpair < 2.5) continue;
332 
333  // float epair(energy1 + energy2);
334  // float pzpair(abs(pz1 + pz2));
335 
336  // float m2(epair * epair - pzpair * pzpair - ptpair * ptpair);
337  // if(m2 < 0.) continue;
338 
339  // float eta(0.5 * log((epair + pzpair)/(epair - pzpair)));
340  // float phi(atan2(px1 + px2, py1 + py2));
341 
342  // float iso(0.);
343  // for(reco::BasicClusterCollection::const_iterator bcItr(_bcs.begin()); bcItr != _bcs.end(); ++bcItr){
344  // float dEta(bcItr->eta() - eta);
345  // float dPhi(bcItr->phi() - phi);
346  // if(dPhi > 2. * pi) dPhi -= 2. * pi;
347  // else if(dPhi < -2. * pi) dPhi += 2. * pi;
348  // if(sqrt(dEta * dEta + dPhi * dPhi) < 0.2) iso += bcItr->energy() * sin(bcItr->position().theta());
349  // }
350  // if(iso > 0.5) continue;
351 
352  // float mass(sqrt(m2));
353  // MEs_[kPi0]->fill(mass);
354  // MEs_[kJPsi]->fill(mass);
355  // }
356  // }
357  }
358 
360  bool isBarrel(_collection == kEBSuperCluster);
362 
363  MESet& meSCE(MEs_.at("SCE"));
364  MESet& meSCELow(MEs_.at("SCELow"));
365  MESet& meSCRawE(MEs_.at("SCRawE"));
366  MESet& meSCRawELow(MEs_.at("SCRawELow"));
367  MESet& meSCNBCs(MEs_.at("SCNBCs"));
368  MESet& meSCNcrystals(MEs_.at("SCNcrystals"));
369  MESet& meTrendSCSize(MEs_.at("TrendSCSize"));
370  MESet& meSCSeedEnergy(MEs_.at("SCSeedEnergy"));
371  MESet& meSCClusterVsSeed(MEs_.at("SCClusterVsSeed"));
372  MESet& meSCSeedOccupancy(MEs_.at("SCSeedOccupancy"));
373  MESet& meSingleCrystalCluster(MEs_.at("SingleCrystalCluster"));
374  MESet& meSCR9(MEs_.at("SCR9"));
375  MESet& meSCR9Raw(MEs_.at("SCR9Raw"));
376  MESet& meSCR9Full(MEs_.at("SCR9Full"));
377  MESet& meSCR9FullRaw(MEs_.at("SCR9FullRaw"));
378 
379  MESet* meSCSizeVsEnergy(doExtra_ ? &MEs_.at("SCSizeVsEnergy") : nullptr);
380  MESet* meSCSeedOccupancyHighE(doExtra_ ? &MEs_.at("SCSeedOccupancyHighE") : nullptr);
381  MESet* meSCSeedOccupancyTrig(doExtra_ ? &MEs_.at("SCSeedOccupancyTrig") : nullptr);
382  MESet* meSCSeedTimeTrigEx(doExtra_ ? &MEs_.at("SCSeedTimeTrigEx") : nullptr);
383  MESet* meSCSeedTimeMapTrigEx(doExtra_ ? &MEs_.at("SCSeedTimeMapTrigEx") : nullptr);
384  MESet* meSCOccupancyProjEta(doExtra_ ? &MEs_.at("SCOccupancyProjEta") : nullptr);
385  MESet* meSCOccupancyProjPhi(doExtra_ ? &MEs_.at("SCOccupancyProjPhi") : nullptr);
386  MESet* meSCSwissCross(doExtra_ ? &MEs_.at("SCSwissCross") : nullptr);
387 
389 
390  // reco::SuperCluster const* leading(0);
391  // reco::SuperCluster const* subLeading(0);
392 
393  int nSC(0);
394 
395  for (reco::SuperClusterCollection::const_iterator scItr(_scs.begin()); scItr != _scs.end(); ++scItr) {
396  DetId seedId(scItr->seed()->seed());
397  if (seedId.null()) {
398  math::XYZPoint const& position(scItr->position());
399 
400  GlobalPoint gp(position.x(), position.y(), position.z());
401 
402  CaloSubdetectorGeometry const* subgeom(
403  GetGeometry()->getSubdetectorGeometry(DetId::Ecal, isBarrel ? EcalBarrel : EcalEndcap));
404 
405  seedId = subgeom->getClosestCell(gp);
406  }
407 
408  if (seedId.null() || (seedId.subdetId() != subdet))
409  continue;
410 
411  EcalRecHitCollection::const_iterator seedItr(hits->find(seedId));
412  if (seedItr == hits->end())
413  continue;
414 
415  ++nSC;
416 
417  float energy(scItr->energy());
418  float rawEnergy(scItr->rawEnergy());
419  float size(scItr->size());
420 
421  meSCE.fill(getEcalDQMSetupObjects(), seedId, energy);
422  meSCELow.fill(getEcalDQMSetupObjects(), seedId, energy);
423 
424  meSCRawE.fill(getEcalDQMSetupObjects(), seedId, rawEnergy);
425  meSCRawELow.fill(getEcalDQMSetupObjects(), seedId, rawEnergy);
426 
427  meSCNBCs.fill(getEcalDQMSetupObjects(), seedId, scItr->clustersSize());
428  meSCNcrystals.fill(getEcalDQMSetupObjects(), seedId, size);
429 
430  if (doExtra_)
431  meSCSizeVsEnergy->fill(getEcalDQMSetupObjects(), subdet, energy, size);
432 
433  meTrendSCSize.fill(getEcalDQMSetupObjects(), seedId, double(timestamp_.iLumi), size);
434 
435  meSCSeedEnergy.fill(getEcalDQMSetupObjects(), seedId, seedItr->energy());
436  meSCClusterVsSeed.fill(getEcalDQMSetupObjects(), seedId, seedItr->energy(), energy);
437 
438  meSCSeedOccupancy.fill(getEcalDQMSetupObjects(), seedId);
440  meSCSeedOccupancyHighE->fill(getEcalDQMSetupObjects(), seedId);
441 
442  if (scItr->size() == 1)
443  meSingleCrystalCluster.fill(getEcalDQMSetupObjects(), seedId);
444 
445  float e3x3(EcalClusterTools::e3x3(*scItr->seed(), hits, GetTopology()));
446  float e3x3Full(noZS::EcalClusterTools::e3x3(*scItr->seed(), hits, GetTopology()));
447 
448  meSCR9.fill(getEcalDQMSetupObjects(), seedId, e3x3 / energy);
449  meSCR9Raw.fill(getEcalDQMSetupObjects(), seedId, e3x3 / rawEnergy);
450  meSCR9Full.fill(getEcalDQMSetupObjects(), seedId, e3x3Full / energy);
451  meSCR9FullRaw.fill(getEcalDQMSetupObjects(), seedId, e3x3Full / rawEnergy);
452 
453  if (doExtra_) {
454  for (unsigned iT(0); iT != nTriggerTypes; ++iT) {
455  if (!triggered_[iT])
456  continue;
457 
458  static_cast<MESetMulti*>(meSCSeedOccupancyTrig)->use(trigTypeToME_[iT]);
459  meSCSeedOccupancyTrig->fill(getEcalDQMSetupObjects(), seedId);
460 
461  // exclusive
462  if (triggered_.count() == 1) {
463  static_cast<MESetMulti*>(meSCSeedTimeTrigEx)->use(trigTypeToME_[iT]);
464  static_cast<MESetMulti*>(meSCSeedTimeMapTrigEx)->use(trigTypeToME_[iT]);
465  meSCSeedTimeTrigEx->fill(getEcalDQMSetupObjects(), subdet, seedItr->time());
466  meSCSeedTimeMapTrigEx->fill(getEcalDQMSetupObjects(), seedId, seedItr->time());
467  }
468  }
469 
470  meSCOccupancyProjEta->fill(getEcalDQMSetupObjects(), subdet, scItr->eta());
471  meSCOccupancyProjPhi->fill(getEcalDQMSetupObjects(), subdet, phi(scItr->phi()));
472 
473  if (isBarrel) {
474  float e1(EcalClusterTools::eMax(*scItr, ebHits_));
475  if (e1 > swissCrossMaxThreshold_) {
476  float e4(EcalClusterTools::eTop(*scItr, ebHits_, GetTopology()) +
477  EcalClusterTools::eRight(*scItr, ebHits_, GetTopology()) +
478  EcalClusterTools::eBottom(*scItr, ebHits_, GetTopology()) +
479  EcalClusterTools::eLeft(*scItr, ebHits_, GetTopology()));
480 
481  meSCSwissCross->fill(getEcalDQMSetupObjects(), 1. - e4 / e1);
482  }
483  }
484  }
485 
486  // if(ievt_ % massCalcPrescale_ != 0) continue;
487 
488  // float et(energy * sin(scItr->position().theta()));
489  // if(!leading || et > leading->energy() * sin(leading->position().theta())){
490  // subLeading = leading;
491  // leading = &(*scItr);
492  // }
493  // else if(!subLeading || et > subLeading->energy() * sin(subLeading->position().theta())){
494  // subLeading = &(*scItr);
495  // }
496  }
497 
498  MEs_.at("SCNum").fill(getEcalDQMSetupObjects(), subdet, nSC);
499  MEs_.at("TrendNSC").fill(getEcalDQMSetupObjects(), subdet, double(timestamp_.iLumi), nSC);
500 
501  // if(ievt_ % massCalcPrescale_ != 0) return;
502 
503  // // implement isolation & cuts
504  // if(!leading || !subLeading) return;
505  // float e(leading->energy() + subLeading->energy());
506  // float px(leading->energy() * sin(leading->position().theta()) * cos(leading->phi()) + subLeading->energy() * sin(subLeading->position().theta()) * cos(subLeading->phi()));
507  // float py(leading->energy() * sin(leading->position().theta()) * sin(leading->phi()) + subLeading->energy() * sin(subLeading->position().theta()) * sin(subLeading->phi()));
508  // float pz(leading->energy() * cos(leading->position().theta()) + subLeading->energy() * cos(subLeading->position().theta()));
509  // float m2(e * e - px * px - py * py - pz * pz);
510  // if(m2 < 0.) return;
511  // float mass(sqrt(m2));
512  // MEs_[kZ]->fill(mass);
513  // MEs_[kHighMass]->fill(mass);
514  }
515 
520  menuRcd = _collector.esConsumes();
521  }
522 
524 } // namespace ecaldqm
size
Write out results.
EDGetTokenT< ProductType > consumes(edm::InputTag const &tag)
void runOnBasicClusters(edm::View< reco::CaloCluster > const &, Collections)
Definition: ClusterTask.cc:210
#define DEFINE_ECALDQM_WORKER(TYPE)
Definition: DQWorker.h:168
T const & getData(const ESGetToken< T, R > &iToken) const noexcept(false)
Definition: EventSetup.h:119
void endEvent(edm::Event const &, edm::EventSetup const &) override
Definition: ClusterTask.cc:178
edm::LuminosityBlockNumber_t iLumi
Definition: DQWorker.h:48
const cms_uint16_t aData(int iA) const
get/set A_DATA_CH_IA
Definition: L1GtPsbWord.cc:181
void addDependencies(DependencySet &) override
Definition: ClusterTask.cc:69
MESet & at(const std::string &key)
Definition: MESet.h:399
EcalRecHitCollection const * ebHits_
Definition: ClusterTask.h:47
std::vector< EcalRecHit >::const_iterator const_iterator
edm::EDGetTokenT< L1GlobalTriggerReadoutRecord > L1GlobalTriggerReadoutRecordToken_
Definition: ClusterTask.h:60
const DecisionWord & decisionWord(int bxInEventValue) const
bool getByToken(EDGetToken token, Handle< PROD > &result) const
Definition: Event.h:536
int zside(DetId const &)
CaloTopology const * GetTopology()
Definition: DQWorker.cc:165
CaloGeometry const * GetGeometry()
Definition: DQWorker.cc:160
void fill(EcalDQMSetupObjects const edso, DetId const &_id, double _xyw=1., double _yw=1., double _w=1.) override
Definition: MESetMulti.h:29
const cms_uint16_t bData(int iB) const
get/set B_DATA_CH_IB
Definition: L1GtPsbWord.cc:253
std::vector< std::string > egTriggerAlgos_
Definition: ClusterTask.h:54
std::vector< SuperCluster > SuperClusterCollection
collection of SuperCluser objectr
float swissCrossMaxThreshold_
Definition: ClusterTask.h:53
std::vector< bool > DecisionWord
typedefs
virtual void fill(EcalDQMSetupObjects const, DetId const &, double=1., double=1., double=1.)
Definition: MESet.h:74
unsigned trigTypeToME_[nTriggerTypes]
Definition: ClusterTask.h:56
bool filterRunType(short const *) override
Definition: ClusterTask.cc:185
void beginEvent(edm::Event const &, edm::EventSetup const &, bool const &, bool &) override
Definition: ClusterTask.cc:74
EcalRecHitCollection const * eeHits_
Definition: ClusterTask.h:48
EcalDQMSetupObjects const getEcalDQMSetupObjects()
Definition: DQWorker.cc:170
edm::EDGetTokenT< L1MuGMTReadoutCollection > L1MuGMTReadoutCollectionToken_
Definition: ClusterTask.h:61
Definition: DetId.h:17
unsigned getIndex(PathReplacements const &) const
Definition: MESetMulti.cc:140
Timestamp timestamp_
Definition: DQWorker.h:134
std::vector< L1MuGMTReadoutRecord > const & getRecords() const
void runOnRecHits(EcalRecHitCollection const &, Collections)
Definition: ClusterTask.cc:197
const L1GtPsbWord gtPsbWord(cms_uint16_t boardIdValue, int bxInEventValue) const
get / set PSB word (record) in the GT readout record
XYZPointD XYZPoint
point in space with cartesian internal representation
Definition: Point3D.h:12
MESetCollection MEs_
Definition: DQWorker.h:131
void setTokens(edm::ConsumesCollector &) override
Definition: ClusterTask.cc:516
void runOnSuperClusters(reco::SuperClusterCollection const &, Collections)
Definition: ClusterTask.cc:359
edm::InputTag L1GlobalTriggerReadoutRecordTag_
Definition: ClusterTask.h:58
boost::indirect_iterator< typename seq_t::const_iterator > const_iterator
Definition: View.h:86
static int position[264][3]
Definition: ReadPGInfo.cc:289
static float e3x3(const reco::BasicCluster &cluster, const EcalRecHitCollection *recHits, const CaloTopology *topology)
std::bitset< nTriggerTypes > triggered_
Definition: ClusterTask.h:55
const_iterator begin() const
edm::InputTag L1MuGMTReadoutCollectionTag_
Definition: ClusterTask.h:59
std::map< std::string, std::string > PathReplacements
Definition: MESet.h:46
EcalSubdetector
void push_back(Dependency const &_d)
Definition: DQWorkerTask.h:46
double phi(EBDetId const &)
const_iterator end() const
void erase(const std::string &key)
Definition: MESet.h:390
void setParams(edm::ParameterSet const &) override
Definition: ClusterTask.cc:34
edm::ESGetToken< L1GtTriggerMenu, L1GtTriggerMenuRcd > menuRcd
Definition: ClusterTask.h:62