CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
HcalIsoTrkAnalyzer.cc
Go to the documentation of this file.
1 // -*- C++ -*-
2 //
3 // Package: HcalCalibAlgos
4 // Class: HcalIsoTrkAnalyzer
5 
6 //
13 //
14 // Original Authors: Andrey Pozdnyakov, Sergey Petrushanko,
15 // Grigory Safronov, Olga Kodolova
16 // Created: Thu Jul 12 18:12:19 CEST 2007
17 //
18 //
19 
20 // system include files
21 #include <memory>
22 
23 // user include files
26 
34 
38 
42 
45 
51 
63 
65 
66 
67 #include "TROOT.h"
68 #include "TH1.h"
69 #include "TH2.h"
70 #include "TFile.h"
71 #include "TTree.h"
72 
73 #include "TString.h"
74 #include "TObject.h"
75 #include "TObjArray.h"
76 #include "TClonesArray.h"
77 #include "TRefArray.h"
78 #include "TLorentzVector.h"
79 
80 
81 #include <iostream>
82 #include <fstream>
83 
84 using namespace edm;
85 using namespace std;
86 using namespace reco;
87 
88 //
89 // class decleration
90 //
91 
93 public:
94  explicit HcalIsoTrkAnalyzer(const edm::ParameterSet&);
96 
97  //double getDistInPlaneSimple(const GlobalPoint caloPoint, const GlobalPoint rechitPoint);
98 
99 private:
100  virtual void beginJob() override ;
101  virtual void analyze(const edm::Event&, const edm::EventSetup&) override;
102  virtual void endJob() override ;
103 
104  // ----------member data ---------------------------
105 
106 
109 
116 
123 
124  double associationConeSize_, calibrationConeSize_;
125  string AxB_;
128 
129  double trackEta, trackPhi;
130  double rvert;
131 
132 
133  int nIterations, MinNTrackHitsBarrel,MinNTECHitsEndcap;
134  float eventWeight;
135  double energyMinIso, energyMaxIso;
136  double energyECALmip, maxPNear;
137  double hottestHitDistance, EcalCone, EcalConeOuter;
138 
139  TFile* rootFile;
140  TTree* tree;
141  Float_t targetE;
143  UInt_t cell;
144  Float_t cellEnergy;
145 
146  TClonesArray* cells;
147  TRefArray* cells3x3;
148  TRefArray* cellsPF;
149  UInt_t eventNumber;
150  UInt_t runNumber;
151  Int_t iEtaHit;
152  UInt_t iPhiHit;
153 
154  Float_t xTrkEcal, yTrkEcal, zTrkEcal;
155  Float_t xTrkHcal, yTrkHcal, zTrkHcal;
156  Float_t PxTrkHcal, PyTrkHcal, PzTrkHcal;
157 
158  Float_t emEnergy, emRingEnergy;
159 
160  // TLorentzVector* exampleP4;
161  TLorentzVector* tagJetP4; // dijet
162  TLorentzVector* probeJetP4; // dijet
163  Float_t etVetoJet; // dijet
164  Float_t tagJetEmFrac; // dijet
165  Float_t probeJetEmFrac; // dijet
166 
167  std::ofstream input_to_L3;
168 
169 };
170 
171 
173 {
174 
175  m_ecalLabel = iConfig.getUntrackedParameter<std::string> ("ecalRecHitsLabel","ecalRecHit");
176  m_ebInstance = iConfig.getUntrackedParameter<std::string> ("ebRecHitsInstance","EcalRecHitsEB");
177  m_eeInstance = iConfig.getUntrackedParameter<std::string> ("eeRecHitsInstance","EcalRecHitsEE");
178  m_hcalLabel = iConfig.getUntrackedParameter<std::string> ("hcalRecHitsLabel","hbhereco");
179 
180  tok_hbhe_ = consumes<HBHERecHitCollection>(iConfig.getParameter<edm::InputTag>("hbheInput"));
181  tok_ho_ = consumes<HORecHitCollection>(iConfig.getParameter<edm::InputTag>("hoInput"));
182  tok_ecal_ = consumes<EcalRecHitCollection>(iConfig.getParameter<edm::InputTag>("eInput"));
183  tok_track_ = consumes<reco::IsolatedPixelTrackCandidateCollection>(iConfig.getParameter<edm::InputTag>("HcalIsolTrackInput"));
184  tok_track1_ = consumes<reco::TrackCollection>(iConfig.getParameter<edm::InputTag>("trackInput"));
185  associationConeSize_=iConfig.getParameter<double>("associationConeSize");
186  allowMissingInputs_=iConfig.getUntrackedParameter<bool>("allowMissingInputs",true);
187  outputFileName_=iConfig.getParameter<std::string>("outputFileName");
188 
189  AxB_=iConfig.getParameter<std::string>("AxB");
190  calibrationConeSize_=iConfig.getParameter<double>("calibrationConeSize");
191 
192  nIterations = iConfig.getParameter<int>("noOfIterations");
193  eventWeight = iConfig.getParameter<double>("eventWeight");
194  energyMinIso = iConfig.getParameter<double>("energyMinIso");
195  energyMaxIso = iConfig.getParameter<double>("energyMaxIso");
196  energyECALmip = iConfig.getParameter<double>("energyECALmip");
197  maxPNear = iConfig.getParameter<double>("maxPNear");
198  MinNTrackHitsBarrel = iConfig.getParameter<int>("MinNTrackHitsBarrel");
199  MinNTECHitsEndcap = iConfig.getParameter<int>("MinNTECHitsEndcap");
200  hottestHitDistance = iConfig.getParameter<double>("hottestHitDistance");
201  EcalCone = iConfig.getParameter<double>("EcalCone");
202  EcalConeOuter = iConfig.getParameter<double>("EcalConeOuter");
203 
204  edm::ParameterSet parameters = iConfig.getParameter<edm::ParameterSet>("TrackAssociatorParameters");
205  edm::ConsumesCollector iC = consumesCollector();
206  parameters_.loadParameters( parameters, iC );
207  trackAssociator_.useDefaultPropagator();
208 
209 }
210 
212 {
213 }
214 
215 // ------------ method called to for each event ------------
216 void
218 {
219  using namespace edm;
220  using namespace std;
221 
222  vector<float> rawEnergyVec;
223  vector<int> detiphi;
224  vector<int> detieta;
225  vector<int> i3i5;
226  vector<HcalDetId> detidvec;
227  float calEnergy;
228 
230  iEvent.getByToken(tok_track1_,isoProdTracks);
231 
233  iEvent.getByToken(tok_track_,isoPixelTracks);
234 
236  iEvent.getByToken(tok_ecal_,ecal);
237  const EcalRecHitCollection Hitecal = *(ecal.product());
238 
240  iEvent.getByToken(tok_hbhe_,hbhe);
241  const HBHERecHitCollection Hithbhe = *(hbhe.product());
242 
244  iSetup.get<CaloGeometryRecord>().get(pG);
245  geo = pG.product();
246 
247  const CaloSubdetectorGeometry* gHcal = geo->getSubdetectorGeometry(DetId::Hcal,HcalBarrel);
248  //Note: even though it says HcalBarrel, we actually get the whole Hcal detector geometry!
249 
250 
251 // rof 16.05.2008 start: include the possibility for recalibration (use "recalibrate" label for safety)
252 /*
253  edm::ESHandle <HcalRespCorrs> recalibCorrs;
254  iSetup.get<HcalRespCorrsRcd>().get("recalibrate",recalibCorrs);
255  const HcalRespCorrs* myRecalib = recalibCorrs.product();
256 */
257 // rof end
258 
259  parameters_.useEcal = true;
260  parameters_.useHcal = true;
261  parameters_.useCalo = false;
262  parameters_.useMuon = false;
263  parameters_.dREcal = 0.5;
264  parameters_.dRHcal = 0.6;
265 
266  if (isoPixelTracks->size()==0) return;
267 
268  for (reco::TrackCollection::const_iterator trit=isoProdTracks->begin(); trit!=isoProdTracks->end(); trit++)
269  {
270  reco::IsolatedPixelTrackCandidateCollection::const_iterator isoMatched=isoPixelTracks->begin();
271  bool matched=false;
272 
273  //Note: this part needs to be changed: obtain isoPixelTracks from isoProdTracks (should be a way)
274  for (reco::IsolatedPixelTrackCandidateCollection::const_iterator it = isoPixelTracks->begin(); it!=isoPixelTracks->end(); it++)
275  {
276 
277  if (abs((trit->pt() - it->pt())/it->pt()) < 0.005 && abs(trit->eta() - it->eta()) < 0.01)
278  {
279  isoMatched=it;
280  matched=true;
281  break;
282  }
283  }
284  if (!matched) continue;
285 
286  if (trit->hitPattern().numberOfValidHits()<MinNTrackHitsBarrel) continue;
287  if (fabs(trit->eta())>1.47&&trit->hitPattern().numberOfValidStripTECHits()<MinNTECHitsEndcap) continue;
288 
289 
290  calEnergy = sqrt(trit->px()*trit->px()+trit->py()*trit->py()+trit->pz()*trit->pz()+0.14*0.14);
291 
292  trackEta = trit->eta();
293  trackPhi = trit->phi();
294 
295  double corrHCAL = 1.; //another possibility for correction. - why?
296 
297  // cout << endl << " ISO TRACK E = "<< calEnergy << " ETA = " << trackEta<< " PHI = " << trackPhi << " Correction " << corrHCAL<< endl;
298 
299  rvert = sqrt(trit->vx()*trit->vx()+trit->vy()*trit->vy()+trit->vz()*trit->vz());
300 
301  //Associate track with a calorimeter
302  TrackDetMatchInfo info = trackAssociator_.associate(iEvent, iSetup,trackAssociator_.getFreeTrajectoryState(iSetup, *trit),parameters_);
303 
304 
305  xTrkHcal=info.trkGlobPosAtHcal.x();
306  yTrkHcal=info.trkGlobPosAtHcal.y();
307  zTrkHcal=info.trkGlobPosAtHcal.z();
308 
309  xTrkEcal=info.trkGlobPosAtEcal.x();
310  yTrkEcal=info.trkGlobPosAtEcal.y();
311  zTrkEcal=info.trkGlobPosAtEcal.z();
312 
313  if (xTrkEcal==0 && yTrkEcal==0&& zTrkEcal==0) {cout<<"zero point at Ecal"<<endl; continue;}
314  if (xTrkHcal==0 && yTrkHcal==0&& zTrkHcal==0) {cout<<"zero point at Hcal"<<endl; continue;}
315 
316  GlobalVector trackMomAtHcal = info.trkMomAtHcal;
317 
318  PxTrkHcal = trackMomAtHcal.x();
319  PyTrkHcal = trackMomAtHcal.y();
320  PzTrkHcal = trackMomAtHcal.z();
321 
322  //PxTrkHcal=0;
323  //PyTrkHcal=0;
324  //PzTrkHcal=0;
325 
326  GlobalPoint gPointEcal(xTrkEcal,yTrkEcal,zTrkEcal);
327  GlobalPoint gPointHcal(xTrkHcal,yTrkHcal,zTrkHcal);
328 
329  // emEnergy = isoMatched->energyIn();
330  emEnergy = ecalEnergyInCone(gPointEcal, EcalCone, Hitecal, geo);
331 
332  emRingEnergy = ecalEnergyInCone(gPointEcal, EcalConeOuter, Hitecal, geo) - ecalEnergyInCone(gPointEcal, EcalCone, Hitecal, geo);
333 
334 
335  int iphitrue = -10;
336  int ietatrue = 100;
337 
338  const HcalDetId tempId = gHcal->getClosestCell(gPointHcal);
339  ietatrue = tempId.ieta();
340  iphitrue = tempId.iphi();
341 
342 
343  //container for used recHits
344  std::vector<DetId> usedHits;
345  //
346  //clear usedHits
347  usedHits.clear();
348 
349 
350  // Find Hcal RecHit with maximum energy and collect other information
351  MaxHit_struct MaxHit;
352  MaxHit.hitenergy=-100;
353 
354 
355  for (HBHERecHitCollection::const_iterator hhit=Hithbhe.begin(); hhit!=Hithbhe.end(); hhit++)
356  {
357 
358  //check that this hit was not considered before and push it into usedHits
359  bool hitIsUsed=false;
360  DetId hitId=hhit->id();
361  for (uint32_t i=0; i<usedHits.size(); i++)
362  {
363  if (usedHits[i]==hitId) hitIsUsed=true;
364  }
365  if (hitIsUsed) continue;
366  usedHits.push_back(hitId);
367  //
368 
369  // rof 16.05.2008 start: include the possibility for recalibration
370  float recal = 1;
371  // rof end
372 
373  GlobalPoint pos = geo->getPosition(hhit->detid());
374 
375  int iphihitm = (hhit->id()).iphi();
376  int ietahitm = (hhit->id()).ieta();
377  int depthhit = (hhit->id()).depth();
378  double enehit = hhit->energy() * recal;
379 
380  if (depthhit!=1) continue;
381 
382 
383  double distAtHcal = getDistInPlaneTrackDir(gPointHcal, trackMomAtHcal, pos);
384  //double distAtHcal = getDistInPlaneSimple(gPointHcal, pos);
385 
386  //if(dr<associationConeSize_)
387  if(distAtHcal < associationConeSize_)
388  {
389  for (HBHERecHitCollection::const_iterator hhit2=Hithbhe.begin(); hhit2!=Hithbhe.end(); hhit2++)
390  {
391  int iphihitm2 = (hhit2->id()).iphi();
392  int ietahitm2 = (hhit2->id()).ieta();
393  int depthhit2 = (hhit2->id()).depth();
394  double enehit2 = hhit2->energy() * recal;
395 
396  if ( iphihitm==iphihitm2 && ietahitm==ietahitm2 && depthhit!=depthhit2){
397 
398  enehit = enehit+enehit2;
399  }
400  }
401 
402  if(enehit > MaxHit.hitenergy)
403  {
404  MaxHit.hitenergy = enehit;
405  MaxHit.ietahitm = (hhit->id()).ieta();
406  MaxHit.iphihitm = (hhit->id()).iphi();
407  MaxHit.depthhit = (hhit->id()).depth();
408  MaxHit.dr = distAtHcal;
409 
410  MaxHit.posMax = geo->getPosition(hhit->detid());
411 
412  }
413  }
414  }
415 
416 
417  Bool_t passCuts = kFALSE;
418  if(calEnergy > energyMinIso && calEnergy < energyMaxIso && emEnergy < energyECALmip &&
419  isoMatched->maxPtPxl() < maxPNear && abs(MaxHit.ietahitm)<30 && MaxHit.hitenergy > 0. &&
420  MaxHit.dr < hottestHitDistance && emRingEnergy<8.){ passCuts = kTRUE; }
421 
422 
423  if(AxB_=="5x5" || AxB_=="3x3" || AxB_=="7x7"|| AxB_=="Cone")
424  {
425 
426  //clear usedHits
427  usedHits.clear();
428  //
429 
430  for (HBHERecHitCollection::const_iterator hhit=Hithbhe.begin(); hhit!=Hithbhe.end(); hhit++)
431  {
432 
433  //check that this hit was not considered before and push it into usedHits
434  bool hitIsUsed=false;
435  DetId hitId=hhit->id();
436  for (uint32_t i=0; i<usedHits.size(); i++)
437  {
438  if (usedHits[i]==hitId) hitIsUsed=true;
439  }
440  if (hitIsUsed)
441  {
442  //cout<<"Hit is Used! ieta: "<< (hhit->id()).ieta()<<" iphi: "<<(hhit->id()).iphi()<<" depth: "<<(hhit->id()).depth()<<" hashed_index: "<<hitHashedIndex<<endl;
443  continue;}
444 
445  usedHits.push_back(hitId);
446  //
447 
448  int DIETA = 100;
449  if(MaxHit.ietahitm*(hhit->id()).ieta()>0)
450  {
451  DIETA = MaxHit.ietahitm - (hhit->id()).ieta();
452  }
453  if(MaxHit.ietahitm*(hhit->id()).ieta()<0)
454  {
455  DIETA = MaxHit.ietahitm - (hhit->id()).ieta();
456  DIETA = DIETA>0 ? DIETA-1 : DIETA+1;
457  }
458 
459  int DIPHI = abs(MaxHit.iphihitm - (hhit->id()).iphi());
460  DIPHI = DIPHI>36 ? 72-DIPHI : DIPHI;
461  /*AP DIPHI = DIPHI<-36 ? 72+DIPHI : DIPHI; */
462 
463  int numbercell=0;
464  if(AxB_=="3x3") numbercell = 1;
465  if(AxB_=="5x5") numbercell = 2;
466  if(AxB_=="7x7") numbercell = 3;
467  if(AxB_=="Cone") numbercell = 1000;
468 
469  if( abs(DIETA)<=numbercell && (abs(DIPHI)<=numbercell || ( abs(MaxHit.ietahitm)>=20 && abs(DIPHI)<=numbercell+1)) ) {
470 
471  // rof 16.05.2008 start: include the possibility for recalibration
472  float recal = 1;
473 
474  int iii3i5 = 0;
475 
476  const GlobalPoint pos2 = geo->getPosition(hhit->detid());
477 
478  if(passCuts){
479 
480  if(AxB_=="5x5" || AxB_=="3x3" || AxB_=="7x7") {
481 
482  rawEnergyVec.push_back(hhit->energy() * recal * corrHCAL);
483  detidvec.push_back(hhit->id());
484  detiphi.push_back((hhit->id()).iphi());
485  detieta.push_back((hhit->id()).ieta());
486  i3i5.push_back(iii3i5);
487 
488  }
489 
490  if (AxB_=="Cone" && getDistInPlaneTrackDir(gPointHcal, trackMomAtHcal, pos2) < calibrationConeSize_) {
491  //if (AxB_=="Cone" && getDistInPlaneSimple(gPointHcal,pos2) < calibrationConeSize_) {
492 
493  rawEnergyVec.push_back(hhit->energy() * recal * corrHCAL);
494  detidvec.push_back(hhit->id());
495  detiphi.push_back((hhit->id()).iphi());
496  detieta.push_back((hhit->id()).ieta());
497  i3i5.push_back(iii3i5);
498 
499  }
500 
501  }
502  }
503  }
504  }
505 
506  if(AxB_!="3x3" && AxB_!="5x5" && AxB_!="7x7" && AxB_!="Cone") LogWarning(" AxB ")<<" Not supported: "<< AxB_;
507 
508  if(passCuts){
509 
510  input_to_L3 << rawEnergyVec.size() << " " << calEnergy;
511 
512 
513  for (unsigned int i=0; i<rawEnergyVec.size(); i++)
514  {
515  input_to_L3 << " " << rawEnergyVec.at(i) << " " << detidvec.at(i).rawId() ;
516 
517  }
518  input_to_L3 <<endl;
519 
520  eventNumber = iEvent.id().event();
521  runNumber = iEvent.id().run();
522  iEtaHit = ietatrue;
523  iPhiHit = iphitrue;
524 
525  numberOfCells=rawEnergyVec.size();
526  targetE = calEnergy;
527 
528  for (unsigned int ia=0; ia<numberOfCells; ++ia) {
529  cellEnergy = rawEnergyVec.at(ia);
530  cell = detidvec.at(ia).rawId();
531 
532  new((*cells)[ia]) TCell(cell, cellEnergy);
533 
534 
535  }
536 
537  tree->Fill();
538 
539  cells->Clear();
540 
541  }
542 
543  rawEnergyVec.clear();
544  detidvec.clear();
545  detiphi.clear();
546  detieta.clear();
547  i3i5.clear();
548 
549  try {
551  iEvent.getByToken(tok_ho_,ho);
552  const HORecHitCollection Hitho = *(ho.product());
553 
554  //clear usedHits
555  usedHits.clear();
556  //
557 
558  for(HORecHitCollection::const_iterator hoItr=Hitho.begin(); hoItr!=Hitho.end(); hoItr++)
559  {
560 
561  //check that this hit was not considered before and push it into usedHits
562  bool hitIsUsed=false;
563  DetId hitId=hoItr->id();
564  for (uint32_t i=0; i<usedHits.size(); i++)
565  {
566  if (usedHits[i]==hitId) hitIsUsed=true;
567  }
568  if (hitIsUsed) continue;
569 
570  usedHits.push_back(hitId);
571 
572  /*AP
573  GlobalPoint pos = geo->getPosition(hoItr->detid());
574  double phihit = pos.phi();
575  double etahit = pos.eta();
576 
577  int iphihitm = (hoItr->id()).iphi();
578  int ietahitm = (hoItr->id()).ieta();
579  int depthhit = (hoItr->id()).depth();
580 
581  double dphi = fabs(trackPhi - phihit);
582  if(dphi > 4.*atan(1.)) dphi = 8.*atan(1.) - dphi;
583  double deta = fabs(trackEta - etahit);
584  double dr = sqrt(dphi*dphi + deta*deta);
585  */
586 
587  }
588  } catch (cms::Exception& e) { // can't find it!
589  if (!allowMissingInputs_) throw e;
590  }
591  }
592 }
593 
594 
595 
596 // ------------ method called once each job just before starting event loop ------------
597 void
599 {
600 
601  // MyL3Algo = new MinL3AlgoUniv<HcalDetId>(eventWeight);
602 
603  input_to_L3.open("input_to_l3.txt");
604 
605  rootFile = new TFile("rootFile.root", "RECREATE");
606  tree = new TTree("hcalCalibTree", "Tree for IsoTrack Calibration");
607  cells = new TClonesArray("TCell", 10000);
608 // cells3x3 = new TRefArray;
609 // cellsPF = new TRefArray;
610 // exampleP4 = new TLorentzVector();
611  tagJetP4 = new TLorentzVector(); // dijet
612  probeJetP4 = new TLorentzVector(); // dijet
613 
614  tree->Branch("cells", &cells, 64000, 0);
615  tree->Branch("targetE", &targetE, "targetE/F");
616  tree->Branch("emEnergy", &emEnergy, "emEnergy/F");
617 
618  tree->Branch("PxTrkHcal", &PxTrkHcal, "PxTrkHcal/F");
619  tree->Branch("PyTrkHcal", &PyTrkHcal, "PyTrkHcal/F");
620  tree->Branch("PzTrkHcal", &PzTrkHcal, "PzTrkHcal/F");
621 
622 
623  tree->Branch("xTrkHcal", &xTrkHcal, "xTrkHcal/F");
624  tree->Branch("yTrkHcal", &yTrkHcal, "yTrkHcal/F");
625  tree->Branch("zTrkHcal", &zTrkHcal, "zTrkHcal/F");
626 
627  tree->Branch("iEtaHit", &iEtaHit, "iEtaHit/I");
628  tree->Branch("iPhiHit", &iPhiHit, "iPhiHit/i");
629  tree->Branch("eventNumber", &eventNumber, "eventNumber/i");
630  tree->Branch("runNumber", &runNumber, "runNumber/i");
631 
632  tree->Branch("tagJetP4", "TLorentzVector", &tagJetP4); // dijet
633  tree->Branch("probeJetP4", "TLorentzVector", &probeJetP4); // dijet
634  tree->Branch("etVetoJet", &etVetoJet, "etVetoJet/F"); // dijet
635  tree->Branch("tagJetEmFrac", &tagJetEmFrac,"tagJetEmFrac/F"); // dijet
636  tree->Branch("probeJetEmFrac", &probeJetEmFrac,"probeJetEmFrac/F"); // dijet
637 
638 }
639 
640 // ------------ method called once each job just after ending the event loop ------------
641 void
643 
644  input_to_L3.close();
645 
646  rootFile->Write();
647  rootFile->Close();
648 
649  if (cells) delete cells;
650 // if (cells3x3) delete cells3x3;
651 // if (cellsPF) delete cellsPF;
652 // if (exampleP4) delete exampleP4;
653  if (tagJetP4) delete tagJetP4; // dijet
654  if (probeJetP4) delete probeJetP4; // dijet
655 
656 }
657 
658 //define this as a plug-in
660 
RunNumber_t run() const
Definition: EventID.h:39
T getParameter(std::string const &) const
EventNumber_t event() const
Definition: EventID.h:41
T getUntrackedParameter(std::string const &, T const &) const
int i
Definition: DBlmapReader.cc:9
dictionary parameters
Definition: Parameters.py:2
static const TGPicture * info(bool iBackgroundIsBlack)
edm::EDGetTokenT< EcalRecHitCollection > tok_ecal_
GlobalPoint posMax
bool getByToken(EDGetToken token, Handle< PROD > &result) const
Definition: Event.h:449
HcalIsoTrkAnalyzer(const edm::ParameterSet &)
double ecalEnergyInCone(const GlobalPoint center, double radius, const EcalRecHitCollection ecalCol, const CaloGeometry *geo)
#define DEFINE_FWK_MODULE(type)
Definition: MakerMacros.h:17
double getDistInPlaneTrackDir(const GlobalPoint caloPoint, const GlobalVector caloVector, const GlobalPoint rechitPoint)
std::vector< HBHERecHit >::const_iterator const_iterator
T y() const
Definition: PV3DBase.h:63
Definition: TCell.h:15
TrackDetectorAssociator trackAssociator_
edm::EDGetTokenT< HBHERecHitCollection > tok_hbhe_
void beginJob()
Definition: Breakpoints.cc:15
TLorentzVector * probeJetP4
int iEvent
Definition: GenABIO.cc:230
edm::EDGetTokenT< reco::IsolatedPixelTrackCandidateCollection > tok_track_
T sqrt(T t)
Definition: SSEVec.h:48
T z() const
Definition: PV3DBase.h:64
int ieta() const
get the cell ieta
Definition: HcalDetId.h:36
Abs< T >::type abs(const T &t)
Definition: Abs.h:22
virtual void analyze(const edm::Event &, const edm::EventSetup &) override
const CaloGeometry * geo
TLorentzVector * tagJetP4
const_iterator end() const
TrackAssociatorParameters parameters_
int iphi() const
get the cell iphi
Definition: HcalDetId.h:38
Definition: DetId.h:18
T const * product() const
Definition: Handle.h:81
const T & get() const
Definition: EventSetup.h:55
edm::EDGetTokenT< HORecHitCollection > tok_ho_
virtual void endJob() override
edm::EventID id() const
Definition: EventBase.h:60
tuple cout
Definition: gather_cfg.py:121
virtual void beginJob() override
T x() const
Definition: PV3DBase.h:62
edm::EDGetTokenT< reco::TrackCollection > tok_track1_
const_iterator begin() const