- Timestamp:
- Jan 25, 2017, 1:10:58 PM (8 years ago)
- Branches:
- ImprovedOutputFile, Timing, dual_readout, llp, master
- Children:
- d6ce231
- Parents:
- 5e728c7
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
modules/TrackPileUpSubtractor.cc
r5e728c7 r84733ae 53 53 //------------------------------------------------------------------------------ 54 54 55 TrackPileUpSubtractor::TrackPileUpSubtractor() : 56 fFormula(0) 55 TrackPileUpSubtractor::TrackPileUpSubtractor() 57 56 { 58 fFormula = new DelphesFormula;59 57 } 60 58 … … 63 61 TrackPileUpSubtractor::~TrackPileUpSubtractor() 64 62 { 65 if(fFormula) delete fFormula;66 63 } 67 64 … … 75 72 fItVertexInputArray = fVertexInputArray->MakeIterator(); 76 73 77 // read resolution formula in m 78 fFormula->Compile(GetString("ZVertexResolution", "0.001")); 74 fZVertexResolution = GetDouble("ZVertexResolution", 0.005)*1.0E3; 79 75 80 76 fPTMin = GetDouble("PTMin", 0.); … … 123 119 TObjArray *array; 124 120 Double_t z, zvtx=0; 125 Double_t pt, eta, phi, e;126 121 127 122 … … 149 144 { 150 145 particle = static_cast<Candidate*>(candidate->GetCandidates()->At(0)); 151 const TLorentzVector &candidateMomentum = particle->Momentum;152 153 eta = candidateMomentum.Eta();154 pt = candidateMomentum.Pt();155 phi = candidateMomentum.Phi();156 e = candidateMomentum.E();157 158 146 z = particle->Position.Z(); 159 147 … … 161 149 // assume perfect pile-up subtraction for tracks outside fZVertexResolution 162 150 163 if(candidate-> IsPU && TMath::Abs(z-zvtx) > fFormula->Eval(pt, eta, phi, e)* 1.0e3)151 if(candidate->Charge !=0 && TMath::Abs(z-zvtx) > fZVertexResolution) 164 152 { 165 153 candidate->IsRecoPU = 1;
Note:
See TracChangeset
for help on using the changeset viewer.