CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Protected Attributes | Private Member Functions | Private Attributes
PFTauElecRejectionBenchmark Class Reference

#include <PFTauElecRejectionBenchmark.h>

Public Member Functions

 PFTauElecRejectionBenchmark ()
 
void process (edm::Handle< edm::HepMCProduct > mcevt, edm::Handle< reco::PFTauCollection > pfTaus, edm::Handle< reco::PFTauDiscriminator > pfTauIsoDiscr, edm::Handle< reco::PFTauDiscriminator > pfTauElecDiscr)
 
void setup (std::string Filename, std::string benchmarkLabel, double maxDeltaR, double minRecoPt, double maxRecoAbsEta, double minMCPt, double maxMCAbsEta, std::string sGenMatchObjectLabel, bool applyEcalCrackCut, DQMStore *db_store)
 
void write ()
 
virtual ~PFTauElecRejectionBenchmark ()
 

Protected Attributes

DQMStoredb_
 

Private Member Functions

bool isInEcalCrack (double eta) const
 

Private Attributes

std::vector< TLorentzVector > _GenObjects
 
bool applyEcalCrackCut_
 
std::string benchmarkLabel_
 
TFile * file_
 
TH1F * hElecMVA
 
TH1F * hElecPreID
 
TH1F * hEmfrac
 
TH1F * hEmfrac_barrel
 
TH1F * hEmfrac_endcap
 
TH1F * hEmfrac_preid0
 
TH1F * hEmfrac_preid1
 
TH2F * hEmfracvsEoP
 
TH2F * hEmfracvsEoP_preid0
 
TH2F * hEmfracvsEoP_preid1
 
TH1F * hEoverP
 
TH1F * hEoverP_barrel
 
TH1F * hEoverP_endcap
 
TH1F * hEoverP_preid0
 
TH1F * hEoverP_preid1
 
TH2F * hHoPvsEoP
 
TH2F * hHoPvsEoP_preid0
 
TH2F * hHoPvsEoP_preid1
 
TH1F * hHoverP
 
TH1F * hHoverP_barrel
 
TH1F * hHoverP_endcap
 
TH1F * hHoverP_preid0
 
TH1F * hHoverP_preid1
 
TH1F * hleadGsfTk_eta
 
TH1F * hleadGsfTk_phi
 
TH1F * hleadGsfTk_pt
 
TH1F * hleadTk_eta
 
TH1F * hleadTk_phi
 
TH1F * hleadTk_pt
 
TH1F * hpfcand_deltaEta
 
TH1F * hpfcand_deltaEta_weightE
 
TH1F * hpfcand_deltaPhiOverQ
 
TH1F * hpfcand_deltaPhiOverQ_weightE
 
TH1F * hTauElecDiscriminant
 
double maxDeltaR_
 
double maxMCAbsEta_
 
double maxRecoAbsEta_
 
double minMCPt_
 
double minRecoPt_
 
std::string outputFile_
 
std::string sGenMatchObjectLabel_
 

Detailed Description

Definition at line 34 of file PFTauElecRejectionBenchmark.h.

Constructor & Destructor Documentation

PFTauElecRejectionBenchmark::PFTauElecRejectionBenchmark ( )

Definition at line 24 of file PFTauElecRejectionBenchmark.cc.

PFTauElecRejectionBenchmark::~PFTauElecRejectionBenchmark ( )
virtual

Definition at line 26 of file PFTauElecRejectionBenchmark.cc.

References file_.

26  {
27  if(file_) file_->Close();
28 }

Member Function Documentation

bool PFTauElecRejectionBenchmark::isInEcalCrack ( double  eta) const
private

Definition at line 357 of file PFTauElecRejectionBenchmark.cc.

Referenced by process().

357  {
358  return (eta < 0.018 ||
359  (eta>0.423 && eta<0.461) ||
360  (eta>0.770 && eta<0.806) ||
361  (eta>1.127 && eta<1.163) ||
362  (eta>1.460 && eta<1.558));
363 }
void PFTauElecRejectionBenchmark::process ( edm::Handle< edm::HepMCProduct mcevt,
edm::Handle< reco::PFTauCollection pfTaus,
edm::Handle< reco::PFTauDiscriminator pfTauIsoDiscr,
edm::Handle< reco::PFTauDiscriminator pfTauElecDiscr 
)

Definition at line 216 of file PFTauElecRejectionBenchmark.cc.

References _GenObjects, funct::abs(), applyEcalCrackCut_, HLTFastRecoForTau_cff::deltaEta, SiPixelRawToDigiRegional_cfi::deltaPhi, reco::tau::disc::Eta(), hElecMVA, hEmfrac, hEmfrac_barrel, hEmfrac_endcap, hEmfrac_preid0, hEmfrac_preid1, hEmfracvsEoP, hEmfracvsEoP_preid0, hEmfracvsEoP_preid1, hEoverP, hEoverP_barrel, hEoverP_endcap, hEoverP_preid0, hEoverP_preid1, hHoPvsEoP, hHoPvsEoP_preid0, hHoPvsEoP_preid1, hHoverP, hHoverP_barrel, hHoverP_endcap, hHoverP_preid0, hHoverP_preid1, hleadTk_eta, hleadTk_phi, hleadTk_pt, hpfcand_deltaEta, hpfcand_deltaEta_weightE, hpfcand_deltaPhiOverQ, hpfcand_deltaPhiOverQ_weightE, hTauElecDiscriminant, i, isInEcalCrack(), edm::Ref< C, T, F >::isNonnull(), maxDeltaR_, maxMCAbsEta_, maxRecoAbsEta_, minMCPt_, minRecoPt_, AlCaHLTBitMon_ParallelJobs::p, sGenMatchObjectLabel_, metsig::tau, and z.

Referenced by ConfigBuilder.ConfigBuilder::addExtraStream(), ConfigBuilder.ConfigBuilder::completeInputCommand(), ConfigBuilder.ConfigBuilder::doNotInlineEventContent(), ConfigBuilder.ConfigBuilder.PrintAllModules::leave(), ConfigBuilder.ConfigBuilder::prepare_HLT(), ConfigBuilder.ConfigBuilder::prepare_LHE(), ConfigBuilder.ConfigBuilder::prepare_PATFILTER(), ConfigBuilder.ConfigBuilder::prepare_VALIDATION(), ConfigBuilder.ConfigBuilder::renameHLTprocessInSequence(), ConfigBuilder.ConfigBuilder::renameInputTagsInSequence(), and ConfigBuilder.ConfigBuilder::scheduleSequence().

218  {
219 
220 
221  // Find Gen Objects to be matched with
222  HepMC::GenEvent * generated_event = new HepMC::GenEvent(*(mcevt->GetEvent()));
223  _GenObjects.clear();
224 
225  TLorentzVector taunet;
226  HepMC::GenEvent::particle_iterator p;
227  for (p = generated_event->particles_begin(); p != generated_event->particles_end(); p++) {
228  if(std::abs((*p)->pdg_id()) == 15&&(*p)->status()==2) {
229  bool lept_decay = false;
230  TLorentzVector tau((*p)->momentum().px(),(*p)->momentum().py(),(*p)->momentum().pz(),(*p)->momentum().e());
231  HepMC::GenVertex::particle_iterator z = (*p)->end_vertex()->particles_begin(HepMC::descendants);
232  for(; z != (*p)->end_vertex()->particles_end(HepMC::descendants); z++) {
233  if(std::abs((*z)->pdg_id()) == 11 || std::abs((*z)->pdg_id()) == 13) lept_decay=true;
234  if(std::abs((*z)->pdg_id()) == 16)
235  taunet.SetPxPyPzE((*z)->momentum().px(),(*z)->momentum().py(),(*z)->momentum().pz(),(*z)->momentum().e());
236 
237  }
238  if(lept_decay==false) {
239  TLorentzVector jetMom=tau-taunet;
240  if (sGenMatchObjectLabel_=="tau") _GenObjects.push_back(jetMom);
241  }
242  } else if(std::abs((*p)->pdg_id()) == 11&&(*p)->status()==1) {
243  TLorentzVector elec((*p)->momentum().px(),(*p)->momentum().py(),(*p)->momentum().pz(),(*p)->momentum().e());
244  if (sGenMatchObjectLabel_=="e") _GenObjects.push_back(elec);
245  }
246  }
247 
249 
250 
251  // Loop over all PFTaus
252  math::XYZPointF myleadTkEcalPos;
253  for (PFTauCollection::size_type iPFTau=0;iPFTau<pfTaus->size();iPFTau++) {
254  PFTauRef thePFTau(pfTaus,iPFTau);
255  if ((*pfTauIsoDiscr)[thePFTau] == 1) {
256  if ((*thePFTau).et() > minRecoPt_ && std::abs((*thePFTau).eta()) < maxRecoAbsEta_) {
257 
258  // Check if track goes to Ecal crack
259  TrackRef myleadTk;
260  if(thePFTau->leadPFChargedHadrCand().isNonnull()){
261  myleadTk=thePFTau->leadPFChargedHadrCand()->trackRef();
262  myleadTkEcalPos = thePFTau->leadPFChargedHadrCand()->positionAtECALEntrance();
263 
264  if(myleadTk.isNonnull()){
265  if (applyEcalCrackCut_ && isInEcalCrack(std::abs((double)myleadTkEcalPos.eta()))) {
266  continue; // do nothing
267  } else {
268 
269  // Match with gen object
270  for (unsigned int i = 0; i<_GenObjects.size();i++) {
271  if (_GenObjects[i].Et() >= minMCPt_ && std::abs(_GenObjects[i].Eta()) < maxMCAbsEta_ ) {
272  TLorentzVector pftau((*thePFTau).px(),(*thePFTau).py(),(*thePFTau).pz(),(*thePFTau).energy());
273  double GenDeltaR = pftau.DeltaR(_GenObjects[i]);
274  if (GenDeltaR<maxDeltaR_) {
275 
276  hleadTk_pt->Fill((float)myleadTk->pt());
277  hleadTk_eta->Fill((float)myleadTk->eta());
278  hleadTk_phi->Fill((float)myleadTk->phi());
279 
280  hEoverP->Fill((*thePFTau).ecalStripSumEOverPLead());
281  hHoverP->Fill((*thePFTau).hcal3x3OverPLead());
282  hEmfrac->Fill((*thePFTau).emFraction());
283 
284  if (std::abs(myleadTk->eta())<1.5) {
285  hEoverP_barrel->Fill((*thePFTau).ecalStripSumEOverPLead());
286  hHoverP_barrel->Fill((*thePFTau).hcal3x3OverPLead());
287  hEmfrac_barrel->Fill((*thePFTau).emFraction());
288  } else if (std::abs(myleadTk->eta())>1.5 && std::abs(myleadTk->eta())<2.5) {
289  hEoverP_endcap->Fill((*thePFTau).ecalStripSumEOverPLead());
290  hHoverP_endcap->Fill((*thePFTau).hcal3x3OverPLead());
291  hEmfrac_endcap->Fill((*thePFTau).emFraction());
292  }
293 
294  // if -999 fill in -1 bin!
295  if ((*thePFTau).electronPreIDOutput()<-1)
296  hElecMVA->Fill(-1);
297  else
298  hElecMVA->Fill((*thePFTau).electronPreIDOutput());
299 
300  hTauElecDiscriminant->Fill((*pfTauElecDiscr)[thePFTau]);
301 
302  hHoPvsEoP->Fill((*thePFTau).ecalStripSumEOverPLead(),(*thePFTau).hcal3x3OverPLead());
303  hEmfracvsEoP->Fill((*thePFTau).emFraction(),(*thePFTau).hcal3x3OverPLead());
304 
305  if ((*thePFTau).electronPreIDDecision()==1) {
306  hEoverP_preid1->Fill((*thePFTau).ecalStripSumEOverPLead());
307  hHoverP_preid1->Fill((*thePFTau).hcal3x3OverPLead());
308  hEmfrac_preid1->Fill((*thePFTau).emFraction());
309  hHoPvsEoP_preid1->Fill((*thePFTau).ecalStripSumEOverPLead(),(*thePFTau).hcal3x3OverPLead());
310  hEmfracvsEoP_preid1->Fill((*thePFTau).emFraction(),(*thePFTau).hcal3x3OverPLead());
311  } else {
312  hEoverP_preid0->Fill((*thePFTau).ecalStripSumEOverPLead());
313  hHoverP_preid0->Fill((*thePFTau).hcal3x3OverPLead());
314  hEmfrac_preid0->Fill((*thePFTau).emFraction());
315  hHoPvsEoP_preid0->Fill((*thePFTau).ecalStripSumEOverPLead(),(*thePFTau).hcal3x3OverPLead());
316  hEmfracvsEoP_preid0->Fill((*thePFTau).emFraction(),(*thePFTau).hcal3x3OverPLead());
317  }
318 
319 
320  }
321  }
322 
323  // Loop over all PFCands for cluster plots
324  std::vector<PFCandidatePtr> myPFCands=(*thePFTau).pfTauTagInfoRef()->PFCands();
325  for(int i=0;i<(int)myPFCands.size();i++){
326 
327  math::XYZPointF candPos;
328  if (myPFCands[i]->particleId()==1 || myPFCands[i]->particleId()==2) // if charged hadron or electron
329  candPos = myPFCands[i]->positionAtECALEntrance();
330  else
331  candPos = math::XYZPointF(myPFCands[i]->px(),myPFCands[i]->py(),myPFCands[i]->pz());
332 
333  //double deltaR = ROOT::Math::VectorUtil::DeltaR(myleadTkEcalPos,candPos);
334  double deltaPhi = ROOT::Math::VectorUtil::DeltaPhi(myleadTkEcalPos,candPos);
335  double deltaEta = std::abs(myleadTkEcalPos.eta()-myPFCands[i]->eta());
336  double deltaPhiOverQ = deltaPhi/(double)myleadTk->charge();
337 
338  hpfcand_deltaEta->Fill(deltaEta);
339  hpfcand_deltaEta_weightE->Fill(deltaEta*myPFCands[i]->ecalEnergy());
340  hpfcand_deltaPhiOverQ->Fill(deltaPhiOverQ);
341  hpfcand_deltaPhiOverQ_weightE->Fill(deltaPhiOverQ*myPFCands[i]->ecalEnergy());
342 
343  }
344 
345  }
346 
347  }
348  }
349  }
350 
351  }
352  }
353  }
354 }
int i
Definition: DBlmapReader.cc:9
bool isNonnull() const
Checks for non-null.
Definition: Ref.h:252
ROOT::Math::PositionVector3D< ROOT::Math::Cartesian3D< float > > XYZPointF
point in space with cartesian internal representation
Definition: Point3D.h:10
uint16_t size_type
std::vector< TLorentzVector > _GenObjects
Abs< T >::type abs(const T &t)
Definition: Abs.h:22
void PFTauElecRejectionBenchmark::setup ( std::string  Filename,
std::string  benchmarkLabel,
double  maxDeltaR,
double  minRecoPt,
double  maxRecoAbsEta,
double  minMCPt,
double  maxMCAbsEta,
std::string  sGenMatchObjectLabel,
bool  applyEcalCrackCut,
DQMStore db_store 
)

Definition at line 47 of file PFTauElecRejectionBenchmark.cc.

References applyEcalCrackCut_, benchmarkLabel_, BOOK1D, BOOK2D, gather_cfg::cout, db_, file_, maxDeltaR_, maxMCAbsEta_, maxRecoAbsEta_, minMCPt_, minRecoPt_, NULL, outputFile_, fed_dqm_sourceclient-live_cfg::path, SETAXES, and sGenMatchObjectLabel_.

57  {
58  maxDeltaR_ = maxDeltaR;
59  benchmarkLabel_ = benchmarkLabel;
60  outputFile_=Filename;
61  minRecoPt_ = minRecoPt;
62  maxRecoAbsEta_= maxRecoAbsEta;
63  minMCPt_ = minMCPt;
64  maxMCAbsEta_= maxMCAbsEta;
65  sGenMatchObjectLabel_ = sGenMatchObjectLabel;
66  applyEcalCrackCut_= applyEcalCrackCut;
67 
68  file_ = NULL;
69  db_ = db_store;
70 
71  // print parameters
72  cout<< "PFTauElecRejectionBenchmark Setup parameters =============================================="<<endl;
73  cout << "Filename to write histograms " << Filename<<endl;
74  cout << "Benchmark label name " << benchmarkLabel_<<endl;
75  cout << "maxDeltaRMax " << maxDeltaR << endl;
76  cout << "minRecoPt " << minRecoPt_ << endl;
77  cout << "maxRecoAbsEta " << maxRecoAbsEta_ << endl;
78  cout << "minMCPt " << minMCPt_ << endl;
79  cout << "maxMCAbsEta " << maxMCAbsEta_ << endl;
80  cout << "applyEcalCrackCut " << applyEcalCrackCut_ << endl;
81  cout << "sGenMatchObjectLabel " << sGenMatchObjectLabel_ << endl;
82 
83  // Book histogram
84 
85  // Establish DQM Store
86  string path = "PFTask/Benchmarks/"+ benchmarkLabel_ + "/";
87  path += "Gen";
88  if (db_) {
89  db_->setCurrentFolder(path.c_str());
90  }
91  else {
92  file_ = new TFile(outputFile_.c_str(), "recreate");
93  cout << "Info: DQM is not available to provide data storage service. Using TFile to save histograms. "<<endl;
94  }
95 
96  // E/p
97  BOOK1D(EoverP,"E/p",100, 0., 4.);
98  SETAXES(EoverP, "E/p", "Entries");
99 
100  BOOK1D(EoverP_barrel,"E/p barrel",100, 0., 4.);
101  SETAXES(EoverP_barrel, "E/p barrel", "Entries");
102 
103  BOOK1D(EoverP_endcap,"E/p endcap",100, 0., 4.);
104  SETAXES(EoverP_endcap, "E/p endcap", "Entries");
105 
106  BOOK1D(EoverP_preid0,"E/p (preid=0)",100, 0., 4.);
107  SETAXES(EoverP_preid0, "E/p", "Entries");
108 
109  BOOK1D(EoverP_preid1,"E/p (preid=1)",100, 0., 4.);
110  SETAXES(EoverP_preid1, "E/p", "Entries");
111 
112  // H/p
113  BOOK1D(HoverP,"H/p",100, 0., 2.);
114  SETAXES(HoverP, "H/p", "Entries");
115 
116  BOOK1D(HoverP_barrel,"H/p barrel",100, 0., 2.);
117  SETAXES(HoverP_barrel, "H/p barrel", "Entries");
118 
119  BOOK1D(HoverP_endcap,"H/p endcap",100, 0., 2.);
120  SETAXES(HoverP_endcap, "H/p endcap", "Entries");
121 
122  BOOK1D(HoverP_preid0,"H/p (preid=0)",100, 0., 2.);
123  SETAXES(HoverP_preid0, "H/p", "Entries");
124 
125  BOOK1D(HoverP_preid1,"H/p (preid=1)",100, 0., 2.);
126  SETAXES(HoverP_preid1, "H/p", "Entries");
127 
128  // emfrac
129  BOOK1D(Emfrac,"EM fraction",100, 0., 1.01);
130  SETAXES(Emfrac, "em fraction", "Entries");
131 
132  BOOK1D(Emfrac_barrel,"EM fraction barrel",100, 0., 1.01);
133  SETAXES(Emfrac_barrel, "em fraction barrel", "Entries");
134 
135  BOOK1D(Emfrac_endcap,"EM fraction endcap",100, 0., 1.01);
136  SETAXES(Emfrac_endcap, "em fraction endcap", "Entries");
137 
138  BOOK1D(Emfrac_preid0,"EM fraction (preid=0)",100, 0., 1.01);
139  SETAXES(Emfrac_preid0, "em fraction", "Entries");
140 
141  BOOK1D(Emfrac_preid1,"EM fraction (preid=1)",100, 0., 1.01);
142  SETAXES(Emfrac_preid1, "em fraction", "Entries");
143 
144  // PreID
145  BOOK1D(ElecPreID,"PFElectron PreID decision",6, 0., 1.01);
146  SETAXES(ElecPreID, "PFElectron PreID decision", "Entries");
147 
148  // MVA
149  BOOK1D(ElecMVA,"PFElectron MVA",100, -1.01, 1.01);
150  SETAXES(ElecMVA, "PFElectron MVA", "Entries");
151 
152  // Discriminant
153  BOOK1D(TauElecDiscriminant,"PFTau-Electron Discriminant",6, 0., 1.01);
154  SETAXES(TauElecDiscriminant, "PFTau-Electron Discriminant", "Entries");
155 
156 
157  // PFCand clusters
158  BOOK1D(pfcand_deltaEta,"PFCand cluster dEta",100, 0., 0.8);
159  SETAXES(pfcand_deltaEta, "PFCand cluster #Delta(#eta)", "Entries");
160 
161  BOOK1D(pfcand_deltaEta_weightE,"PFCand cluster dEta, energy weighted",100, 0., 0.8);
162  SETAXES(pfcand_deltaEta_weightE, "PFCand cluster #Delta(#eta)", "Entries");
163 
164  BOOK1D(pfcand_deltaPhiOverQ,"PFCand cluster dPhi/q",100, -0.8, 0.8);
165  SETAXES(pfcand_deltaPhiOverQ, "PFCand cluster #Delta(#phi)/q", "Entries");
166 
167  BOOK1D(pfcand_deltaPhiOverQ_weightE,"PFCand cluster dEta/q, energy weighted",100, -0.8, 0.8);
168  SETAXES(pfcand_deltaPhiOverQ_weightE, "PFCand cluster #Delta(#phi)/q", "Entries");
169 
170 
171  // Leading KF track
172  BOOK1D(leadTk_pt,"leading KF track pt",100, 0., 80.);
173  SETAXES(leadTk_pt, "leading KF track p_{T} (GeV)", "Entries");
174 
175  BOOK1D(leadTk_eta,"leading KF track eta",100, -4., 4.);
176  SETAXES(leadTk_eta, "leading KF track #eta", "Entries");
177 
178  BOOK1D(leadTk_phi,"leading KF track phi",100, -3.2, 3.2);
179  SETAXES(leadTk_phi, "leading KF track #phi", "Entries");
180 
181  // Leading Gsf track
182  BOOK1D(leadGsfTk_pt,"leading Gsf track pt",100, 0., 80.);
183  SETAXES(leadGsfTk_pt, "leading Gsf track p_{T} (GeV)", "Entries");
184 
185  BOOK1D(leadGsfTk_eta,"leading Gsf track eta",100, -4., 4.);
186  SETAXES(leadGsfTk_eta, "leading Gsf track #eta", "Entries");
187 
188  BOOK1D(leadGsfTk_phi,"leading Gsf track phi",100, -3.2, 3.2);
189  SETAXES(leadGsfTk_phi, "leading Gsf track #phi", "Entries");
190 
191 
192  // H/p vs E/p
193  BOOK2D(HoPvsEoP,"H/p vs. E/p",100, 0., 2., 100, 0., 2.);
194  SETAXES(HoPvsEoP, "E/p", "H/p");
195 
196  BOOK2D(HoPvsEoP_preid0,"H/p vs. E/p (preid=0)",100, 0., 2., 100, 0., 2.);
197  SETAXES(HoPvsEoP_preid0, "E/p", "H/p");
198 
199  BOOK2D(HoPvsEoP_preid1,"H/p vs. E/p (preid=0)",100, 0., 2., 100, 0., 2.);
200  SETAXES(HoPvsEoP_preid1, "E/p", "H/p");
201 
202  // em fraction vs E/p
203  BOOK2D(EmfracvsEoP,"emfrac vs. E/p",100, 0., 2., 100, 0., 1.01);
204  SETAXES(EmfracvsEoP, "E/p", "em fraction");
205 
206  BOOK2D(EmfracvsEoP_preid0,"emfrac vs. E/p (preid=0)",100, 0., 2., 100, 0., 1.01);
207  SETAXES(EmfracvsEoP_preid0, "E/p", "em fraction");
208 
209  BOOK2D(EmfracvsEoP_preid1,"emfrac vs. E/p (preid=0)",100, 0., 2., 100, 0., 1.01);
210  SETAXES(EmfracvsEoP_preid1, "E/p", "em fraction");
211 
212 
213 }
#define NULL
Definition: scimark2.h:8
#define BOOK1D(name, title, nbinsx, lowx, highx)
#define BOOK2D(name, title, nbinsx, lowx, highx, nbinsy, lowy, highy)
#define SETAXES(name, xtitle, ytitle)
tuple cout
Definition: gather_cfg.py:121
void PFTauElecRejectionBenchmark::write ( )

Definition at line 30 of file PFTauElecRejectionBenchmark.cc.

References gather_cfg::cout, db_, file_, and outputFile_.

30  {
31  // Store the DAQ Histograms
32  if (outputFile_.size() != 0) {
33  if (db_)
34  db_->save(outputFile_.c_str());
35  // use bare Root if no DQM (FWLite applications)
36  else if (file_) {
37  file_->Write(outputFile_.c_str());
38  cout << "Benchmark output written to file " << outputFile_.c_str() << endl;
39  file_->Close();
40  }
41  }
42  else
43  cout << "No output file specified ("<<outputFile_<<"). Results will not be saved!" << endl;
44 
45 }
tuple cout
Definition: gather_cfg.py:121

Member Data Documentation

std::vector<TLorentzVector> PFTauElecRejectionBenchmark::_GenObjects
private

Definition at line 120 of file PFTauElecRejectionBenchmark.h.

Referenced by process().

bool PFTauElecRejectionBenchmark::applyEcalCrackCut_
private

Definition at line 70 of file PFTauElecRejectionBenchmark.h.

Referenced by process(), and setup().

std::string PFTauElecRejectionBenchmark::benchmarkLabel_
private

Definition at line 63 of file PFTauElecRejectionBenchmark.h.

Referenced by setup().

DQMStore* PFTauElecRejectionBenchmark::db_
protected

Definition at line 124 of file PFTauElecRejectionBenchmark.h.

Referenced by setup(), and write().

TFile* PFTauElecRejectionBenchmark::file_
private

Definition at line 61 of file PFTauElecRejectionBenchmark.h.

Referenced by setup(), write(), and ~PFTauElecRejectionBenchmark().

TH1F* PFTauElecRejectionBenchmark::hElecMVA
private

Definition at line 94 of file PFTauElecRejectionBenchmark.h.

Referenced by process().

TH1F* PFTauElecRejectionBenchmark::hElecPreID
private

Definition at line 93 of file PFTauElecRejectionBenchmark.h.

TH1F* PFTauElecRejectionBenchmark::hEmfrac
private

Definition at line 75 of file PFTauElecRejectionBenchmark.h.

Referenced by process().

TH1F* PFTauElecRejectionBenchmark::hEmfrac_barrel
private

Definition at line 79 of file PFTauElecRejectionBenchmark.h.

Referenced by process().

TH1F* PFTauElecRejectionBenchmark::hEmfrac_endcap
private

Definition at line 83 of file PFTauElecRejectionBenchmark.h.

Referenced by process().

TH1F* PFTauElecRejectionBenchmark::hEmfrac_preid0
private

Definition at line 87 of file PFTauElecRejectionBenchmark.h.

Referenced by process().

TH1F* PFTauElecRejectionBenchmark::hEmfrac_preid1
private

Definition at line 91 of file PFTauElecRejectionBenchmark.h.

Referenced by process().

TH2F* PFTauElecRejectionBenchmark::hEmfracvsEoP
private

Definition at line 101 of file PFTauElecRejectionBenchmark.h.

Referenced by process().

TH2F* PFTauElecRejectionBenchmark::hEmfracvsEoP_preid0
private

Definition at line 102 of file PFTauElecRejectionBenchmark.h.

Referenced by process().

TH2F* PFTauElecRejectionBenchmark::hEmfracvsEoP_preid1
private

Definition at line 103 of file PFTauElecRejectionBenchmark.h.

Referenced by process().

TH1F* PFTauElecRejectionBenchmark::hEoverP
private

Definition at line 73 of file PFTauElecRejectionBenchmark.h.

Referenced by process().

TH1F* PFTauElecRejectionBenchmark::hEoverP_barrel
private

Definition at line 77 of file PFTauElecRejectionBenchmark.h.

Referenced by process().

TH1F* PFTauElecRejectionBenchmark::hEoverP_endcap
private

Definition at line 81 of file PFTauElecRejectionBenchmark.h.

Referenced by process().

TH1F* PFTauElecRejectionBenchmark::hEoverP_preid0
private

Definition at line 85 of file PFTauElecRejectionBenchmark.h.

Referenced by process().

TH1F* PFTauElecRejectionBenchmark::hEoverP_preid1
private

Definition at line 89 of file PFTauElecRejectionBenchmark.h.

Referenced by process().

TH2F* PFTauElecRejectionBenchmark::hHoPvsEoP
private

Definition at line 97 of file PFTauElecRejectionBenchmark.h.

Referenced by process().

TH2F* PFTauElecRejectionBenchmark::hHoPvsEoP_preid0
private

Definition at line 98 of file PFTauElecRejectionBenchmark.h.

Referenced by process().

TH2F* PFTauElecRejectionBenchmark::hHoPvsEoP_preid1
private

Definition at line 99 of file PFTauElecRejectionBenchmark.h.

Referenced by process().

TH1F* PFTauElecRejectionBenchmark::hHoverP
private

Definition at line 74 of file PFTauElecRejectionBenchmark.h.

Referenced by process().

TH1F* PFTauElecRejectionBenchmark::hHoverP_barrel
private

Definition at line 78 of file PFTauElecRejectionBenchmark.h.

Referenced by process().

TH1F* PFTauElecRejectionBenchmark::hHoverP_endcap
private

Definition at line 82 of file PFTauElecRejectionBenchmark.h.

Referenced by process().

TH1F* PFTauElecRejectionBenchmark::hHoverP_preid0
private

Definition at line 86 of file PFTauElecRejectionBenchmark.h.

Referenced by process().

TH1F* PFTauElecRejectionBenchmark::hHoverP_preid1
private

Definition at line 90 of file PFTauElecRejectionBenchmark.h.

Referenced by process().

TH1F* PFTauElecRejectionBenchmark::hleadGsfTk_eta
private

Definition at line 116 of file PFTauElecRejectionBenchmark.h.

TH1F* PFTauElecRejectionBenchmark::hleadGsfTk_phi
private

Definition at line 117 of file PFTauElecRejectionBenchmark.h.

TH1F* PFTauElecRejectionBenchmark::hleadGsfTk_pt
private

Definition at line 115 of file PFTauElecRejectionBenchmark.h.

TH1F* PFTauElecRejectionBenchmark::hleadTk_eta
private

Definition at line 111 of file PFTauElecRejectionBenchmark.h.

Referenced by process().

TH1F* PFTauElecRejectionBenchmark::hleadTk_phi
private

Definition at line 112 of file PFTauElecRejectionBenchmark.h.

Referenced by process().

TH1F* PFTauElecRejectionBenchmark::hleadTk_pt
private

Definition at line 110 of file PFTauElecRejectionBenchmark.h.

Referenced by process().

TH1F* PFTauElecRejectionBenchmark::hpfcand_deltaEta
private

Definition at line 105 of file PFTauElecRejectionBenchmark.h.

Referenced by process().

TH1F* PFTauElecRejectionBenchmark::hpfcand_deltaEta_weightE
private

Definition at line 106 of file PFTauElecRejectionBenchmark.h.

Referenced by process().

TH1F* PFTauElecRejectionBenchmark::hpfcand_deltaPhiOverQ
private

Definition at line 107 of file PFTauElecRejectionBenchmark.h.

Referenced by process().

TH1F* PFTauElecRejectionBenchmark::hpfcand_deltaPhiOverQ_weightE
private

Definition at line 108 of file PFTauElecRejectionBenchmark.h.

Referenced by process().

TH1F* PFTauElecRejectionBenchmark::hTauElecDiscriminant
private

Definition at line 95 of file PFTauElecRejectionBenchmark.h.

Referenced by process().

double PFTauElecRejectionBenchmark::maxDeltaR_
private

Definition at line 64 of file PFTauElecRejectionBenchmark.h.

Referenced by process(), and setup().

double PFTauElecRejectionBenchmark::maxMCAbsEta_
private

Definition at line 66 of file PFTauElecRejectionBenchmark.h.

Referenced by process(), and setup().

double PFTauElecRejectionBenchmark::maxRecoAbsEta_
private

Definition at line 68 of file PFTauElecRejectionBenchmark.h.

Referenced by process(), and setup().

double PFTauElecRejectionBenchmark::minMCPt_
private

Definition at line 65 of file PFTauElecRejectionBenchmark.h.

Referenced by process(), and setup().

double PFTauElecRejectionBenchmark::minRecoPt_
private

Definition at line 67 of file PFTauElecRejectionBenchmark.h.

Referenced by process(), and setup().

std::string PFTauElecRejectionBenchmark::outputFile_
private

Definition at line 62 of file PFTauElecRejectionBenchmark.h.

Referenced by setup(), and write().

std::string PFTauElecRejectionBenchmark::sGenMatchObjectLabel_
private

Definition at line 69 of file PFTauElecRejectionBenchmark.h.

Referenced by process(), and setup().