206 |
|
edm::Handle<double> rho25Handle; |
207 |
|
iEvent.getByLabel(edm::InputTag("kt6PFJets25", "rho"),rho25Handle); |
208 |
|
auxInfo->puInfo.rho25 = *rho25Handle; |
209 |
+ |
edm::Handle<double> rho25HandleIso; |
210 |
+ |
iEvent.getByLabel(edm::InputTag("kt6PFJetsForIsolation", "rho"),rho25HandleIso); |
211 |
+ |
auxInfo->puInfo.rho25Iso = *rho25HandleIso; |
212 |
|
|
213 |
|
edm::Handle<double> rhoNeutralHandle; |
214 |
|
iEvent.getByLabel(edm::InputTag("kt6PFJetsCentralNeutral", "rho"),rhoNeutralHandle); |
224 |
|
std::vector< PileupSummaryInfo> pu = (*puHandle); |
225 |
|
for (std::vector<PileupSummaryInfo>::const_iterator it= pu.begin(); it!=pu.end(); ++it){ |
226 |
|
int bx = (*it).getBunchCrossing(); |
227 |
+ |
if(bx == 0) { auxInfo->puInfo.truePU = (*it).getTrueNumInteractions();} |
228 |
|
unsigned int num = (*it).getPU_NumInteractions(); |
229 |
|
// std::cout <<" PU PUSHING "<<bx<<" " <<num<<std::endl; |
230 |
|
auxInfo->puInfo.pus[bx] =num; |
391 |
|
|
392 |
|
/////// end generator block |
393 |
|
|
394 |
+ |
/// photon used in isolation |
395 |
+ |
edm::Handle<edm::View<reco::PFCandidate> > photonIsoH; |
396 |
+ |
iEvent.getByLabel("pfAllPhotons",photonIsoH); |
397 |
+ |
edm::View<reco::PFCandidate> photonsForIso = *photonIsoH; |
398 |
|
|
399 |
|
edm::Handle<edm::View<pat::Muon> > muonHandle; |
400 |
|
iEvent.getByLabel(muoLabel_,muonHandle); |
1365 |
|
} |
1366 |
|
|
1367 |
|
edm::Handle<edm::View<pat::MET> > metPFHandle; |
1368 |
< |
iEvent.getByLabel("patMETs",metPFHandle); |
1368 |
> |
iEvent.getByLabel("patMETsPFlow",metPFHandle); |
1369 |
|
edm::View<pat::MET> metsPF = *metPFHandle; |
1370 |
|
|
1371 |
|
if(metsPF.size()){ |
1503 |
|
ef.pfChaIso=elec->chargedHadronIso(); |
1504 |
|
ef.pfChaPUIso=elec->puChargedHadronIso();//userIso(5); |
1505 |
|
ef.pfPhoIso=elec->photonIso(); |
1506 |
+ |
ef.pfPhoIsoDoubleCounted=0; |
1507 |
+ |
|
1508 |
+ |
/* Check if there are photons sharing the super cluster*/ |
1509 |
+ |
for(size_t k=0;k<photonsForIso.size();k++) { |
1510 |
+ |
if(deltaR(elec->eta(),elec->phi(),photonsForIso[k].eta(),photonsForIso[k].phi()) < 0.05 && abs(photonsForIso[k].pt()-elec->pt())/(photonsForIso[k].pt()+elec->pt()) < 0.05 ) { |
1511 |
+ |
std::cout << "Double counting of supercluster!" << std::endl; |
1512 |
+ |
ef.pfPhoIsoDoubleCounted+=photonsForIso[k].pt(); |
1513 |
+ |
} |
1514 |
+ |
} |
1515 |
|
ef.pfNeuIso=elec->neutralHadronIso(); |
1516 |
|
|
1517 |
|
// |
1532 |
|
ef.HoE = elec->hadronicOverEm(); |
1533 |
|
ef.convDist = elec->convDist(); |
1534 |
|
ef.convDcot = elec->convDcot(); |
1535 |
< |
if(elec->gsfTrack().isNonnull()) ef.innerHits = elec->gsfTrack()->trackerExpectedHitsInner().numberOfHits(); |
1535 |
> |
if(elec->gsfTrack().isNonnull()) |
1536 |
> |
{ |
1537 |
> |
ef.innerHits = elec->gsfTrack()->trackerExpectedHitsInner().numberOfHits(); |
1538 |
> |
} |
1539 |
|
ef.isEB = elec->isEB(); |
1540 |
|
ef.isEE = elec->isEE(); |
1541 |
|
/* 2012 ELEID*/ |