33 for ( std::vector<std::string>::iterator iParam = parameterNames.begin();
34 iParam != parameterNames.end(); iParam++ ){
43 const int kMaxRecoPFJet = 10000;
55 const int kMaxJetCal = 10000;
56 jhcalpt =
new float[kMaxJetCal];
59 jhcale =
new float[kMaxJetCal];
80 jrcalpt =
new float[kMaxJetCal];
83 jrcale =
new float[kMaxJetCal];
96 const int kMaxJetgen = 10000;
97 jgenpt =
new float[kMaxJetgen];
98 jgenphi =
new float[kMaxJetgen];
99 jgeneta =
new float[kMaxJetgen];
100 jgene =
new float[kMaxJetgen];
101 const int kMaxTower = 10000;
102 towet =
new float[kMaxTower];
103 toweta =
new float[kMaxTower];
104 towphi =
new float[kMaxTower];
105 towen =
new float[kMaxTower];
106 towem =
new float[kMaxTower];
107 towhd =
new float[kMaxTower];
108 towoe =
new float[kMaxTower];
112 const int kMaxTau = 500;
119 tauEta =
new float[kMaxTau];
120 tauPt =
new float[kMaxTau];
121 tauPhi =
new float[kMaxTau];
123 const int kMaxPFTau = 500;
163 const int kMaxPFJet = 500;
166 pfJetPt =
new float[kMaxPFJet];
167 pfJetE =
new float[kMaxPFJet];
176 const int kMaxTauIso = 5000;
198 HltTree->Branch(
"signalTrToPFTauMatch",
signalTrToPFTauMatch,
"signalTrToPFTauMatch[NoRecoPFTausSignal]/I");
199 HltTree->Branch(
"recoPFTauSignalTrDz",
recoPFTauSignalTrDz,
"recoPFTauSignalTrDz[NoRecoPFTausSignal]/F");
200 HltTree->Branch(
"recoPFTauSignalTrPt",
recoPFTauSignalTrPt,
"recoPFTauSignalTrPt[NoRecoPFTausSignal]/F");
202 HltTree->Branch(
"NoRecoPFTausIso",&
noRecoPFTausIso,
"NoRecoPFTausIso/I");
203 HltTree->Branch(
"isoTrToPFTauMatch",
isoTrToPFTauMatch,
"isoTrToPFTauMatch[NoRecoPFTausIso]/I");
204 HltTree->Branch(
"recoPFTauIsoTrDz",
recoPFTauIsoTrDz,
"recoPFTauIsoTrDz[NoRecoPFTausIso]/F");
205 HltTree->Branch(
"recoPFTauIsoTrPt",
recoPFTauIsoTrPt,
"recoPFTauIsoTrPt[NoRecoPFTausIso]/F");
209 HltTree->Branch(
"hltpftauSignalTrToPFTauMatch",
211 HltTree->Branch(
"HLTPFTauSignalTrDz",
HLTPFTauSignalTrDz,
"HLTPFTauSignalTrDz[NoHLTPFTausSignal]/F");
212 HltTree->Branch(
"HLTPFTauSignalTrPt",
HLTPFTauSignalTrPt,
"HLTPFTauSignalTrPt[NoHLTPFTausSignal]/F");
214 HltTree->Branch(
"NoHLTPFTausIso",&
noHLTPFTausIso,
"NoHLTPFTausIso/I");
215 HltTree->Branch(
"hltpftauIsoTrToPFTauMatch",
217 HltTree->Branch(
"HLTPFTauIsoTrDz",
HLTPFTauIsoTrDz,
"HLTPFTauIsoTrDz[NoHLTPFTausIso]/F");
218 HltTree->Branch(
"HLTPFTauIsoTrPt",
HLTPFTauIsoTrPt,
"HLTPFTauIsoTrPt[NoHLTPFTausIso]/F");
222 HltTree->Branch(
"NrecoJetGen",&
njetgen,
"NrecoJetGen/I");
223 HltTree->Branch(
"NrecoTowCal",&
ntowcal,
"NrecoTowCal/I");
226 HltTree->Branch(
"NrecoJetCal",&
nrjetcal,
"NrecoJetCal/I");
227 HltTree->Branch(
"recoJetCalPt",
jrcalpt,
"recoJetCalPt[NrecoJetCal]/F");
228 HltTree->Branch(
"recoJetCalPhi",
jrcalphi,
"recoJetCalPhi[NrecoJetCal]/F");
229 HltTree->Branch(
"recoJetCalEta",
jrcaleta,
"recoJetCalEta[NrecoJetCal]/F");
230 HltTree->Branch(
"recoJetCalE",
jrcale,
"recoJetCalE[NrecoJetCal]/F");
231 HltTree->Branch(
"recoJetCalEMF",
jrcalemf,
"recoJetCalEMF[NrecoJetCal]/F");
232 HltTree->Branch(
"recoJetCalN90",
jrcaln90,
"recoJetCalN90[NrecoJetCal]/F");
233 HltTree->Branch(
"recoJetCalN90hits",
jrcaln90hits,
"recoJetCalN90hits[NrecoJetCal]/F");
235 HltTree->Branch(
"NrecoJetCorCal",&
nrcorjetcal,
"NrecoJetCorCal/I");
236 HltTree->Branch(
"recoJetCorCalPt",
jrcorcalpt,
"recoJetCorCalPt[NrecoJetCorCal]/F");
237 HltTree->Branch(
"recoJetCorCalPhi",
jrcorcalphi,
"recoJetCorCalPhi[NrecoJetCorCal]/F");
238 HltTree->Branch(
"recoJetCorCalEta",
jrcorcaleta,
"recoJetCorCalEta[NrecoJetCorCal]/F");
239 HltTree->Branch(
"recoJetCorCalE",
jrcorcale,
"recoJetCorCalE[NrecoJetCorCal]/F");
240 HltTree->Branch(
"recoJetCorCalEMF",
jrcorcalemf,
"recoJetCorCalEMF[NrecoJetCorCal]/F");
241 HltTree->Branch(
"recoJetCorCalN90",
jrcorcaln90,
"recoJetCorCalN90[NrecoJetCorCal]/F");
242 HltTree->Branch(
"recoJetCorCalN90hits",
jrcorcaln90hits,
"recoJetCorCalN90hits[NrecoJetCorCal]/F");
245 HltTree->Branch(
"NohJetCal",&
nhjetcal,
"NohJetCal/I");
246 HltTree->Branch(
"ohJetCalPt",
jhcalpt,
"ohJetCalPt[NohJetCal]/F");
247 HltTree->Branch(
"ohJetCalPhi",
jhcalphi,
"ohJetCalPhi[NohJetCal]/F");
248 HltTree->Branch(
"ohJetCalEta",
jhcaleta,
"ohJetCalEta[NohJetCal]/F");
249 HltTree->Branch(
"ohJetCalE",
jhcale,
"ohJetCalE[NohJetCal]/F");
250 HltTree->Branch(
"ohJetCalEMF",
jhcalemf,
"ohJetCalEMF[NohJetCal]/F");
251 HltTree->Branch(
"ohJetCalN90",
jhcaln90,
"ohJetCalN90[NohJetCal]/F");
252 HltTree->Branch(
"ohJetCalN90hits",
jhcaln90hits,
"ohJetCalN90hits[NohJetCal]/F");
254 HltTree->Branch(
"NohJetCorCal",&
nhcorjetcal,
"NohJetCorCal/I");
255 HltTree->Branch(
"ohJetCorCalPt",
jhcorcalpt,
"ohJetCorCalPt[NohJetCorCal]/F");
256 HltTree->Branch(
"ohJetCorCalPhi",
jhcorcalphi,
"ohJetCorCalPhi[NohJetCorCal]/F");
257 HltTree->Branch(
"ohJetCorCalEta",
jhcorcaleta,
"ohJetCorCalEta[NohJetCorCal]/F");
258 HltTree->Branch(
"ohJetCorCalE",
jhcorcale,
"ohJetCorCalE[NohJetCorCal]/F");
259 HltTree->Branch(
"ohJetCorCalEMF",
jhcorcalemf,
"ohJetCorCalEMF[NohJetCorCal]/F");
260 HltTree->Branch(
"ohJetCorCalN90",
jhcorcaln90,
"ohJetCorCalN90[NohJetCorCal]/F");
261 HltTree->Branch(
"ohJetCorCalN90hits",
jhcorcaln90hits,
"ohJetCorCalN90hits[NohJetCorCal]/F");
264 HltTree->Branch(
"ohJetCorL1L2L3CalPt",
jhcorL1L2L3calpt,
"ohJetCorL1L2L3CalPt[NohJetCorL1L2L3Cal]/F");
265 HltTree->Branch(
"ohJetCorL1L2L3CalPhi",
jhcorL1L2L3calphi,
"ohJetCorL1L2L3CalPhi[NohJetCorL1L2L3Cal]/F");
266 HltTree->Branch(
"ohJetCorL1L2L3CalEta",
jhcorL1L2L3caleta,
"ohJetCorL1L2L3CalEta[NohJetCorL1L2L3Cal]/F");
267 HltTree->Branch(
"ohJetCorL1L2L3CalE",
jhcorL1L2L3cale,
"ohJetCorL1L2L3CalE[NohJetCorL1L2L3Cal]/F");
268 HltTree->Branch(
"ohJetCorL1L2L3CalEMF",
jhcorL1L2L3calemf,
"ohJetCorL1L2L3CalEMF[NohJetCorL1L2L3Cal]/F");
269 HltTree->Branch(
"ohJetCorL1L2L3CalN90",
jhcorL1L2L3caln90,
"ohJetCorL1L2L3CalN90[NohJetCorL1L2L3Cal]/F");
270 HltTree->Branch(
"ohJetCorL1L2L3CalN90hits",
jhcorL1L2L3caln90hits,
"ohJetCorL1L2L3CalN90hits[NohJetCorL1L2L3Cal]/F");
271 HltTree->Branch(
"rho",&
jrho,
"rho/D");
274 HltTree->Branch(
"recoJetGenPt",
jgenpt,
"recoJetGenPt[NrecoJetGen]/F");
275 HltTree->Branch(
"recoJetGenPhi",
jgenphi,
"recoJetGenPhi[NrecoJetGen]/F");
276 HltTree->Branch(
"recoJetGenEta",
jgeneta,
"recoJetGenEta[NrecoJetGen]/F");
277 HltTree->Branch(
"recoJetGenE",
jgene,
"recoJetGenE[NrecoJetGen]/F");
279 HltTree->Branch(
"recoTowEt",
towet,
"recoTowEt[NrecoTowCal]/F");
280 HltTree->Branch(
"recoTowEta",
toweta,
"recoTowEta[NrecoTowCal]/F");
281 HltTree->Branch(
"recoTowPhi",
towphi,
"recoTowPhi[NrecoTowCal]/F");
282 HltTree->Branch(
"recoTowE",
towen,
"recoTowE[NrecoTowCal]/F");
283 HltTree->Branch(
"recoTowEm",
towem,
"recoTowEm[NrecoTowCal]/F");
284 HltTree->Branch(
"recoTowHad",
towhd,
"recoTowHad[NrecoTowCal]/F");
285 HltTree->Branch(
"recoTowOE",
towoe,
"recoTowOE[NrecoTowCal]/F");
286 HltTree->Branch(
"recoTowHCalNoiseR45Upper",
towR45upper,
"recoTowHCalNoiseR45Upper[NrecoTowCal]/I");
287 HltTree->Branch(
"recoTowHCalNoiseR45Lower",
towR45lower,
"recoTowHCalNoiseR45Lower[NrecoTowCal]/I");
288 HltTree->Branch(
"recoTowHCalNoiseR45None",
towR45none,
"recoTowHCalNoiseR45None[NrecoTowCal]/I");
290 HltTree->Branch(
"recoMetCal",&
mcalmet,
"recoMetCal/F");
291 HltTree->Branch(
"recoMetCalPhi",&
mcalphi,
"recoMetCalPhi/F");
292 HltTree->Branch(
"recoMetCalSum",&
mcalsum,
"recoMetCalSum/F");
293 HltTree->Branch(
"recoMetGen",&
mgenmet,
"recoMetGen/F");
294 HltTree->Branch(
"recoMetGenPhi",&
mgenphi,
"recoMetGenPhi/F");
295 HltTree->Branch(
"recoMetGenSum",&
mgensum,
"recoMetGenSum/F");
296 HltTree->Branch(
"recoHTCal",&
htcalet,
"recoHTCal/F");
297 HltTree->Branch(
"recoHTCalPhi",&
htcalphi,
"recoHTCalPhi/F");
298 HltTree->Branch(
"recoHTCalSum",&
htcalsum,
"recoHTCalSum/F");
299 HltTree->Branch(
"recoMetPF", &
pfmet,
"recoMetPF/F");
300 HltTree->Branch(
"recoMetPFSum", &
pfsumet,
"recoMetPFSum/F");
301 HltTree->Branch(
"recoMetPFPhi", &
pfmetphi,
"recoMetPFPhi/F");
308 HltTree->Branch(
"NohTauL2",&
nohl2tau,
"NohTauL2/I");
309 HltTree->Branch(
"ohTauL2Pt",
l2tauPt,
"ohTauL2Pt[NohTauL2]/F");
310 HltTree->Branch(
"ohTauL2Eta",
l2tauEta,
"ohTauL2Eta[NohTauL2]/F");
311 HltTree->Branch(
"ohTauL2Phi",
l2tauPhi,
"ohTauL2Phi[NohTauL2]/F");
314 HltTree->Branch(
"NohTau",&
nohtau,
"NohTau/I");
315 HltTree->Branch(
"ohTauEta",
tauEta,
"ohTauEta[NohTau]/F");
316 HltTree->Branch(
"ohTauPhi",
tauPhi,
"ohTauPhi[NohTau]/F");
317 HltTree->Branch(
"ohTauPt",
tauPt,
"ohTauPt[NohTau]/F");
318 HltTree->Branch(
"ohTauEiso",
l2tauemiso,
"ohTauEiso[NohTau]/F");
319 HltTree->Branch(
"ohTauL25Tpt",
l25tauPt,
"ohTauL25Tpt[NohTau]/F");
320 HltTree->Branch(
"ohTauL3Tiso",
l3tautckiso,
"ohTauL3Tiso[NohTau]/I");
324 HltTree->Branch(
"NohpfTau",&
nohPFTau,
"NohpfTau/I");
325 HltTree->Branch(
"ohpfTauPt",
ohpfTauPt,
"ohpfTauPt[NohpfTau]/F");
326 HltTree->Branch(
"ohpfTauProngs",
ohpfTauProngs,
"ohpfTauProngs[NohpfTau]/I");
327 HltTree->Branch(
"ohpfTauEta",
ohpfTauEta,
"ohpfTauEta[NohpfTau]/F");
328 HltTree->Branch(
"ohpfTauPhi",
ohpfTauPhi,
"ohpfTauPhi[NohpfTau]/F");
329 HltTree->Branch(
"ohpfTauLeadTrackPt",
ohpfTauLeadTrackPt,
"ohpfTauLeadTrackPt[NohpfTau]/F");
330 HltTree->Branch(
"ohpfTauLeadTrackVtxZ",
ohpfTauLeadTrackVtxZ,
"ohpfTauLeadTrackVtxZ[NohpfTau]/F");
331 HltTree->Branch(
"ohpfTauLeadPionPt",
ohpfTauLeadPionPt,
"ohpfTauLeadPionPt[NohpfTau]/F");
332 HltTree->Branch(
"ohpfTauTrkIso",
ohpfTauTrkIso,
"ohpfTauTrkIso[NohpfTau]/F");
333 HltTree->Branch(
"ohpfTauGammaIso",
ohpfTauGammaIso,
"ohpfTauGammaIso[NohpfTau]/F");
334 HltTree->Branch(
"ohpfTauJetPt",
ohpfTauJetPt,
"ohpfTauJetPt[NohpfTau]/F");
339 HltTree->Branch(
"ohpfTauTightConePt",
ohpfTauTightConePt,
"ohpfTauTightConePt[NohpfTauTightCone]/F");
341 HltTree->Branch(
"ohpfTauTightConeEta",
ohpfTauTightConeEta,
"ohpfTauEta[NohpfTauTightCone]/F");
342 HltTree->Branch(
"ohpfTauTightConePhi",
ohpfTauTightConePhi,
"ohpfTauPhi[NohpfTauTightCone]/F");
345 HltTree->Branch(
"ohpfTauTightConeTrkIso",
ohpfTauTightConeTrkIso,
"ohpfTauTightConeTrkIso[NohpfTauTightCone]/F");
346 HltTree->Branch(
"ohpfTauTightConeGammaIso",
ohpfTauTightConeGammaIso,
"ohpfTauTightConeGammaIso[NohpfTauTightCone]/F");
347 HltTree->Branch(
"ohpfTauTightConeJetPt",
ohpfTauTightConeJetPt,
"ohpfTauTightConeJetPt[NohpfTauTightCone]/F");
351 HltTree->Branch(
"NRecoPFTau",&
nRecoPFTau,
"NRecoPFTau/I");
352 HltTree->Branch(
"recopfTauPt",
recopfTauPt,
"recopfTauPt[NRecoPFTau]/F");
353 HltTree->Branch(
"recopfTauEta",
recopfTauEta,
"recopfTauEta[NRecoPFTau]/F");
354 HltTree->Branch(
"recopfTauPhi",
recopfTauPhi,
"recopfTauPhi[NRecoPFTau]/F");
355 HltTree->Branch(
"recopfTauLeadTrackPt",
recopfTauLeadTrackPt,
"recopfTauLeadTrackPt[NRecoPFTau]/F");
356 HltTree->Branch(
"recopfTauLeadPionPt",
recopfTauLeadPionPt,
"recopfTauLeadPionPt[NRecoPFTau]/F");
357 HltTree->Branch(
"recopfTauTrkIso",
recopfTauTrkIso,
"recopfTauTrkIso[NRecoPFTau]/I");
358 HltTree->Branch(
"recopfTauGammaIso",
recopfTauGammaIso,
"recopfTauGammaIso[NRecoPFTau]/I");
359 HltTree->Branch(
"recopfTauJetPt",
recopfTauJetPt,
"recopfTauJetPt[NRecoPFTau]/F");
364 HltTree->Branch(
"recopfTauDiscrByIso",
recopfTauDiscrByIso,
"recopfTauDiscrByIso[NRecoPFTau]/F");
370 HltTree->Branch(
"pfHT",&
pfHT,
"pfHT/F");
371 HltTree->Branch(
"pfMHT",&
pfMHT,
"pfMHT/F");
372 HltTree->Branch(
"NohPFJet",&
nohPFJet,
"NohPFJet/I");
373 HltTree->Branch(
"pfJetPt",
pfJetPt,
"pfJetPt[NohPFJet]/F");
374 HltTree->Branch(
"pfJetE",
pfJetE,
"pfJetE[NohPFJet]/F");
375 HltTree->Branch(
"pfJetEta",
pfJetEta,
"pfJetEta[NohPFJet]/F");
376 HltTree->Branch(
"pfJetPhi",
pfJetPhi,
"pfJetPhi[NohPFJet]/F");
385 HltTree->Branch(
"nrpj",&
nrpj,
"nrpj/I");
386 HltTree->Branch(
"recopfJetpt",
jpfrecopt,
"recopfJetpt[nrpj]/F");
387 HltTree->Branch(
"recopfJete",
jpfrecoe,
"recopfJete[nrpj]/F");
388 HltTree->Branch(
"recopfJetphi",
jpfrecophi,
"recopfJetphi[nrpj]/F");
389 HltTree->Branch(
"recopfJeteta",
jpfrecoeta,
"recopfJeteta[nrpj]/F");
431 double thresholdForSavingTowers,
452 mycalojets=*rcalojets;
454 typedef reco::CaloJetCollection::const_iterator cjiter;
456 for ( cjiter
i=mycalojets.begin();
i!=mycalojets.end();
i++) {
476 mycalojets=*rcalocorjets;
478 typedef reco::CaloJetCollection::const_iterator cjiter;
480 for ( cjiter
i=mycalojets.begin();
i!=mycalojets.end();
i++) {
500 mycalojets=*ohcalojets;
502 typedef reco::CaloJetCollection::const_iterator cjiter;
504 for ( cjiter
i=mycalojets.begin();
i!=mycalojets.end();
i++) {
525 mycalocorjets=*ohcalocorjets;
527 typedef reco::CaloJetCollection::const_iterator ccorjiter;
529 for ( ccorjiter
i=mycalocorjets.begin();
i!=mycalocorjets.end();
i++) {
548 if (ohcalocorL1L2L3jets.
isValid()) {
550 mycalocorL1L2L3jets=*ohcalocorL1L2L3jets;
552 typedef reco::CaloJetCollection::const_iterator ccorL1L2L3jiter;
553 int jhcorL1L2L3cal=0;
554 for ( ccorL1L2L3jiter
i=mycalocorL1L2L3jets.begin();
i!=mycalocorL1L2L3jets.end();
i++) {
581 std::set<unsigned int> towersUpper;
582 std::set<unsigned int> towersLower;
583 std::set<unsigned int> towersNone;
585 bool towersUpperValid=
false;
586 bool towersLowerValid=
false;
587 bool towersNoneValid=
false;
588 if( caloTowersCleanerUpperR45.
isValid() ){
589 towersUpperValid =
true;
591 towersUpper.insert(cttopo->
denseIndex(tow->id()));
594 if( caloTowersCleanerLowerR45.
isValid() ){
595 towersLowerValid =
true;
597 towersLower.insert(cttopo->
denseIndex(tow->id()));
600 if( caloTowersCleanerNoR45.
isValid() ){
601 towersNoneValid =
true;
603 towersNone.insert(cttopo->
denseIndex(tow->id()));
610 if(tower->energy() > thresholdForSavingTowers)
612 towet[jtow] = tower->et();
613 toweta[jtow] = tower->eta();
614 towphi[jtow] = tower->phi();
615 towen[jtow] = tower->energy();
616 towem[jtow] = tower->emEnergy();
617 towhd[jtow] = tower->hadEnergy();
618 towoe[jtow] = tower->outerEnergy();
622 if(towersNoneValid) {
if(towersNone.find(cttopo->
denseIndex(tower->id())) == towersNone.end())
towR45none[jtow]=
true;
else towR45none[jtow]=
false;}
631 typedef reco::CaloMETCollection::const_iterator cmiter;
632 for ( cmiter
i=recmets->begin();
i!=recmets->end();
i++) {
640 typedef reco::PFMETCollection::const_iterator pfmetiter;
641 for( pfmetiter
i=pfmets->begin();
i!=pfmets->end();
i++) {
649 typedef reco::METCollection::const_iterator iter;
650 for ( iter
i=ht->begin();
i!=ht->end();
i++) {
663 typedef reco::GenJetCollection::const_iterator gjiter;
665 for ( gjiter
i=mygenjets.begin();
i!=mygenjets.end();
i++) {
671 jgene[jgen] =
i->energy();
681 typedef reco::GenMETCollection::const_iterator gmiter;
682 for ( gmiter
i=genmets->begin();
i!=genmets->end();
i++) {
698 for(reco::CaloJetCollection::const_iterator
i = l2taus.begin();
699 i!= l2taus.end(); ++
i){
713 typedef reco::HLTTauCollection::const_iterator tauit;
715 for(tauit
i=mytaujets.begin();
i!=mytaujets.end();
i++){
723 l25tauPt[itau] =
i->getL25LeadTrackPtValue();
740 typedef reco::PFTauCollection::const_iterator pftauit;
742 for(pftauit
i=taus.begin();
i!=taus.end();
i++){
748 ohpfTauJetPt[ipftau] =
i->pfTauTagInfoRef()->pfjetRef()->pt();
755 if( (
i->leadPFNeutralCand()).isNonnull())
760 if((
i->leadPFChargedHadrCand()).isNonnull()){
768 float maxPtTrkIso = 0;
769 for (
unsigned int iTrk = 0; iTrk <
i->isolationPFChargedHadrCands().size(); iTrk++)
771 if(
i->isolationPFChargedHadrCands()[iTrk]->pt() > maxPtTrkIso) maxPtTrkIso =
i->isolationPFChargedHadrCands()[iTrk]->pt();
773 if (
i->isolationPFChargedHadrCands()[iTrk]->trackRef().isNonnull()){
788 float maxPtGammaIso = 0;
789 for (
unsigned int iGamma = 0; iGamma <
i->isolationPFGammaCands().size(); iGamma++)
791 if(
i->isolationPFGammaCands()[iGamma]->pt() > maxPtGammaIso) maxPtGammaIso =
i->isolationPFGammaCands()[iGamma]->pt();
796 for (
unsigned int iTrk = 0; iTrk <
i->signalPFChargedHadrCands().size(); iTrk++)
798 if (
i->signalPFChargedHadrCands ()[iTrk]->trackRef().isNonnull()){
821 if(pfTausTightCone.
isValid()) {
827 typedef reco::PFTauCollection::const_iterator pftauit;
829 for(pftauit
i=taus.begin();
i!=taus.end();
i++){
838 if( (
i->leadPFNeutralCand()).isNonnull())
844 if((
i->leadPFChargedHadrCand()).isNonnull())
849 float maxPtTrkIso = 0;
850 for (
unsigned int iTrk = 0; iTrk <
i->isolationPFChargedHadrCands().size(); iTrk++)
852 if(
i->isolationPFChargedHadrCands()[iTrk]->pt() > maxPtTrkIso) maxPtTrkIso =
i->isolationPFChargedHadrCands()[iTrk]->pt();
856 float maxPtGammaIso = 0;
857 for (
unsigned int iGamma = 0; iGamma <
i->isolationPFGammaCands().size(); iGamma++)
859 if(
i->isolationPFGammaCands()[iGamma]->pt() > maxPtGammaIso) maxPtGammaIso =
i->isolationPFGammaCands()[iGamma]->pt();
870 float minTrkPt = minPtCH;
871 float minGammaPt = minPtGamma;
877 typedef reco::PFTauCollection::const_iterator pftauit;
880 for(pftauit
i=taus.begin();
i!=taus.end();
i++){
886 if( (
i->leadPFNeutralCand()).isNonnull())
892 if((
i->leadPFChargedHadrCand()).isNonnull())
898 for (
unsigned int iTrk = 0; iTrk <
i->isolationPFChargedHadrCands().size(); iTrk++)
900 if(
i->isolationPFChargedHadrCands()[iTrk]->pt() > minTrkPt) myTrks++;
901 if (
i->isolationPFChargedHadrCands()[iTrk]->trackRef().isNonnull()){
917 for (
unsigned int iGamma = 0; iGamma <
i->isolationPFGammaCands().size(); iGamma++)
919 if(
i->isolationPFGammaCands()[iGamma]->pt() > minGammaPt) myGammas++;
924 for (
unsigned int iTrk = 0; iTrk <
i->signalPFChargedHadrCands().size(); iTrk++)
926 if (
i->signalPFChargedHadrCands ()[iTrk]->trackRef().isNonnull()){
941 if(theRecoPFTauDiscrByTanCOnePercent.
isValid()){
943 if(theRecoPFTauDiscrByIsolation.
isValid()){
945 if(theRecoPFTauDiscrAgainstMuon.
isValid()){
947 if(theRecoPFTauDiscrAgainstElec.
isValid()){
949 if(theRecoPFTauDiscrByTanCHalfPercent.
isValid()){
951 if(theRecoPFTauDiscrByTanCQuarterPercent.
isValid()){
953 if(theRecoPFTauDiscrByTanCTenthPercent.
isValid()){
965 typedef reco::PFJetCollection::const_iterator pfJetit;
971 for(pfJetit
i=Jets.begin();
i!=Jets.end();
i++){
985 if (
i->pt() > 40. &&
abs(
i->eta())<3.0)
988 pfMHTx = pfMHTx +
i->px();
989 pfMHTy = pfMHTy +
i->py();
993 pfMHT =
sqrt(pfMHTx*pfMHTx + pfMHTy*pfMHTy);
999 nrpj = recoPFJets->size();
1002 typedef reco::PFJetCollection::const_iterator pfJetit;
1004 for(pfJetit
i=Jets.begin();
i!=Jets.end();
i++){
T getParameter(std::string const &) const
float * recopfTauDiscrAgainstElec
std::vector< PFTau > PFTauCollection
collection of PFTau objects
int * hltpftauIsoTrToPFTauMatch
float * ohpfTauTightConeLeadTrackPt
float * HLTPFTauSignalTrDz
float * ohpfTauTightConeTrkIso
float * ohpfTauTightConePt
int * jpfrecochargedMultiplicity
float * ohpfTauLeadTrackPt
float * recopfTauDiscrByTancQuarterPercent
std::vector< GenJet > GenJetCollection
collection of GenJet objects
float * pfJetchargedHadronFraction
float * jpfrecochargedHadronFraction
std::vector< CaloTower >::const_iterator const_iterator
float * recopfTauDiscrByIso
float * recopfTauLeadTrackPt
float * recopfTauDiscrByTancHalfPercent
void analyze(edm::Event const &iEvent, const edm::Handle< reco::CaloJetCollection > &ohjets, const edm::Handle< reco::CaloJetCollection > &ohcorjets, const edm::Handle< reco::CaloJetCollection > &ohcorL1L2L3jets, const edm::Handle< double > &rho, const edm::Handle< reco::CaloJetCollection > &recojets, const edm::Handle< reco::CaloJetCollection > &recocorjets, const edm::Handle< reco::GenJetCollection > &gjets, const edm::Handle< reco::CaloMETCollection > &rmets, const edm::Handle< reco::GenMETCollection > &gmets, const edm::Handle< reco::METCollection > &ht, const edm::Handle< reco::CaloJetCollection > &myHLTL2Tau, const edm::Handle< reco::HLTTauCollection > &myHLTTau, const edm::Handle< reco::PFTauCollection > &myHLTPFTau, const edm::Handle< reco::PFTauCollection > &myHLTPFTauTightCone, const edm::Handle< reco::PFJetCollection > &myHLTPFJets, const edm::Handle< reco::PFTauCollection > &myRecoPFTau, const edm::Handle< reco::PFTauDiscriminator > &theRecoPFTauDiscrByTanCOnePercent, const edm::Handle< reco::PFTauDiscriminator > &theRecoPFTauDiscrByTanCHalfPercent, const edm::Handle< reco::PFTauDiscriminator > &theRecoPFTauDiscrByTanCQuarterPercent, const edm::Handle< reco::PFTauDiscriminator > &theRecoPFTauDiscrByTanCTenthPercent, const edm::Handle< reco::PFTauDiscriminator > &theRecoPFTauDiscrByIsolation, const edm::Handle< reco::PFTauDiscriminator > &theRecoPFTauDiscrAgainstElec, const edm::Handle< reco::PFTauDiscriminator > &theRecoPFTauDiscrAgainstMuon, const edm::Handle< reco::PFJetCollection > &recoPFJets, const edm::Handle< CaloTowerCollection > &caloTowers, const edm::Handle< CaloTowerCollection > &caloTowersCleanerUpperR45, const edm::Handle< CaloTowerCollection > &caloTowersCleanerLowerR45, const edm::Handle< CaloTowerCollection > &caloTowersCleanerNoR45, const CaloTowerTopology *cttopo, const edm::Handle< reco::PFMETCollection > &pfmets, double thresholdForSavingTowers, double minPtCH, double minPtGamma, TTree *tree)
float * recoPFTauSignalTrPt
float * jhcorL1L2L3caleta
int * hltpftauSignalTrToPFTauMatch
float * ohpfTauTightConeLeadPionPt
float * ohpfTauTightConeJetPt
float * ohpfTauTightConeEta
float * jpfreconeutralHadronFraction
float * recopfTauLeadPionPt
reco::helper::JetIDHelper * jetID
Abs< T >::type abs(const T &t)
int * signalTrToPFTauMatch
float * ohpfTauTightConeGammaIso
float * recopfTauDiscrAgainstMuon
void setup(const edm::ParameterSet &pSet, TTree *tree, edm::ConsumesCollector &&iC)
std::vector< HLTTau > HLTTauCollection
collection of HLTTau objects
std::vector< std::string > getParameterNames() const
float * recopfTauDiscrByTancOnePercent
float * pfJetneutralMultiplicity
float * pfJetneutralHadronEnergyFraction
float * ohpfTauLeadPionPt
uint32_t denseIndex(const DetId &id) const
float * HLTPFTauSignalTrPt
float * jpfreconeutralEMFraction
float * jhcorL1L2L3caln90hits
int * jpfreconeutralMultiplicity
int * ohpfTauTightConeProngs
float * recoPFTauSignalTrDz
std::vector< PFJet > PFJetCollection
collection of PFJet objects
float * jhcorL1L2L3calemf
float * jhcorL1L2L3caln90
float * jpfrecochargedEMFraction
float * pfJetneutralEMFraction
float * ohpfTauTightConePhi
float * recopfTauDiscrByTancTenthPercent
float * jhcorL1L2L3calphi
float * pfJetchargedMultiplicity
float * pfJetchargedEMFraction
float * ohpfTauLeadTrackVtxZ
void calculate(const edm::Event &event, const reco::CaloJet &jet, const int iDbg=0)
std::vector< CaloJet > CaloJetCollection
collection of CaloJet objects