Fork me on GitHub

Changeset e8abecd in git for modules/Isolation.cc


Ignore:
Timestamp:
Jun 30, 2015, 4:25:20 PM (9 years ago)
Author:
Michele Selvaggi <michele.selvaggi@…>
Branches:
ImprovedOutputFile, Timing, dual_readout, llp, master
Children:
8b13e78
Parents:
c627b07
Message:

remove lepton veto bug from Isolation

File:
1 edited

Legend:

Unmodified
Added
Removed
  • modules/Isolation.cc

    rc627b07 re8abecd  
    109109  fUsePTSum = GetBool("UsePTSum", false);
    110110
    111   fVetoLeptons = GetBool("VetoLeptons", true); 
    112  
    113111  fClassifier->fPTMin = GetDouble("PTMin", 0.5);
    114 
    115112
    116113  // import input array(s)
     
    197194
    198195      if(candidateMomentum.DeltaR(isolationMomentum) <= fDeltaRMax &&
    199          candidate->GetUniqueID() != isolation->GetUniqueID() &&
    200          ( !fVetoLeptons || (TMath::Abs(candidate->PID) != 11 && (TMath::Abs(candidate->PID) != 13)) ) )
     196         candidate->GetUniqueID() != isolation->GetUniqueID())
    201197      {
    202      
    203198        sumAllParticles += isolationMomentum.Pt();
    204199        if(isolation->Charge !=0)
     
    207202          if(isolation->IsRecoPU != 0) sumChargedPU += isolationMomentum.Pt();
    208203        }
    209  
    210         else sumNeutral += isolationMomentum.Pt();
    211  
     204        else
     205        {
     206          sumNeutral += isolationMomentum.Pt();
     207        }
    212208        ++counter;
    213209      }
     
    228224    }
    229225
    230        
    231226     // correct sum for pile-up contamination
    232227    sumDBeta = sumCharged + TMath::Max(sumNeutral-0.5*sumChargedPU,0.0);
     
    242237    candidate->SumPt = sumAllParticles;
    243238
    244     if((fUsePTSum && sumDBeta > fPTSumMax) || ratioDBeta > fPTRatioMax) continue;
     239    if((fUsePTSum && sumDBeta > fPTSumMax) || (!fUsePTSum && ratioDBeta > fPTRatioMax)) continue;
    245240    fOutputArray->Add(candidate);
    246241  }
Note: See TracChangeset for help on using the changeset viewer.