Changes in / [cb46568:3b99510] in git
- Files:
-
- 4 deleted
- 9 edited
Legend:
- Unmodified
- Added
- Removed
-
Makefile
rcb46568 r3b99510 316 316 modules/EnergySmearing.h \ 317 317 modules/MomentumSmearing.h \ 318 modules/TrackSmearing.h \319 318 modules/ImpactParameterSmearing.h \ 320 319 modules/TimeSmearing.h \ … … 339 338 modules/StatusPidFilter.h \ 340 339 modules/PdgCodeFilter.h \ 341 modules/BeamSpotFilter.h \342 340 modules/Cloner.h \ 343 341 modules/Weighter.h \ … … 548 546 classes/DelphesFactory.h \ 549 547 classes/DelphesFormula.h 550 tmp/modules/BeamSpotFilter.$(ObjSuf): \551 modules/BeamSpotFilter.$(SrcSuf) \552 modules/BeamSpotFilter.h \553 classes/DelphesClasses.h \554 classes/DelphesFactory.h \555 classes/DelphesFormula.h \556 external/ExRootAnalysis/ExRootResult.h \557 external/ExRootAnalysis/ExRootFilter.h \558 external/ExRootAnalysis/ExRootClassifier.h559 548 tmp/modules/Calorimeter.$(ObjSuf): \ 560 549 modules/Calorimeter.$(SrcSuf) \ … … 841 830 modules/TrackPileUpSubtractor.$(SrcSuf) \ 842 831 modules/TrackPileUpSubtractor.h \ 843 classes/DelphesClasses.h \844 classes/DelphesFactory.h \845 classes/DelphesFormula.h \846 external/ExRootAnalysis/ExRootResult.h \847 external/ExRootAnalysis/ExRootFilter.h \848 external/ExRootAnalysis/ExRootClassifier.h849 tmp/modules/TrackSmearing.$(ObjSuf): \850 modules/TrackSmearing.$(SrcSuf) \851 modules/TrackSmearing.h \852 832 classes/DelphesClasses.h \ 853 833 classes/DelphesFactory.h \ … … 935 915 tmp/modules/AngularSmearing.$(ObjSuf) \ 936 916 tmp/modules/BTagging.$(ObjSuf) \ 937 tmp/modules/BeamSpotFilter.$(ObjSuf) \938 917 tmp/modules/Calorimeter.$(ObjSuf) \ 939 918 tmp/modules/Cloner.$(ObjSuf) \ … … 967 946 tmp/modules/TrackCountingTauTagging.$(ObjSuf) \ 968 947 tmp/modules/TrackPileUpSubtractor.$(ObjSuf) \ 969 tmp/modules/TrackSmearing.$(ObjSuf) \970 948 tmp/modules/TreeWriter.$(ObjSuf) \ 971 949 tmp/modules/UniqueObjectFinder.$(ObjSuf) \ … … 1567 1545 tmp/external/tcl/tclVar.$(ObjSuf) 1568 1546 1569 modules/TrackSmearing.h: \1570 classes/DelphesModule.h1571 @touch $@1572 1573 1547 external/fastjet/ClusterSequence.hh: \ 1574 1548 external/fastjet/PseudoJet.hh \ … … 2003 1977 2004 1978 modules/FastJetFinder.h: \ 2005 classes/DelphesModule.h2006 @touch $@2007 2008 modules/BeamSpotFilter.h: \2009 1979 classes/DelphesModule.h 2010 1980 @touch $@ -
classes/DelphesClasses.cc
rcb46568 r3b99510 127 127 Momentum(0.0, 0.0, 0.0, 0.0), 128 128 Position(0.0, 0.0, 0.0, 0.0), 129 InitialPosition(0.0, 0.0, 0.0, 0.0),130 129 Area(0.0, 0.0, 0.0, 0.0), 131 L(0), 132 D0(0), ErrorD0(0), 133 DZ(0), ErrorDZ(0), 134 P(0), ErrorP(0), 135 PT(0), ErrorPT(0), 136 CtgTheta(0), ErrorCtgTheta(0), 137 Phi(0), ErrorPhi(0), 138 Xd(0), Yd(0), Zd(0), 130 Dxy(0), SDxy(0), Xd(0), Yd(0), Zd(0), 139 131 TrackResolution(0), 140 132 NCharged(0), … … 270 262 object.Momentum = Momentum; 271 263 object.Position = Position; 272 object.InitialPosition = Position;273 264 object.Area = Area; 274 object.L = L; 275 object.D0 = D0; 276 object.ErrorD0 = ErrorD0; 277 object.DZ = DZ; 278 object.ErrorDZ = ErrorDZ; 279 object.P = P; 280 object.ErrorP = ErrorP; 281 object.PT = PT; 282 object.ErrorPT = ErrorPT; 283 object.CtgTheta = CtgTheta ; 284 object.ErrorCtgTheta = ErrorCtgTheta; 285 object.Phi = Phi; 286 object.ErrorPhi = ErrorPhi; 265 object.Dxy = Dxy; 266 object.SDxy = SDxy; 287 267 object.Xd = Xd; 288 268 object.Yd = Yd; … … 383 363 Momentum.SetXYZT(0.0, 0.0, 0.0, 0.0); 384 364 Position.SetXYZT(0.0, 0.0, 0.0, 0.0); 385 InitialPosition.SetXYZT(0.0, 0.0, 0.0, 0.0);386 365 Area.SetXYZT(0.0, 0.0, 0.0, 0.0); 387 L = 0.0; 388 D0 = 0.0; 389 ErrorD0 = 0.0; 390 DZ = 0.0; 391 ErrorDZ = 0.0; 392 P =0.0; 393 ErrorP =0.0; 394 PT = 0.0; 395 ErrorPT = 0.0; 396 CtgTheta = 0.0; 397 ErrorCtgTheta = 0.0; 398 Phi = 0.0; 399 ErrorPhi = 0.0; 366 Dxy = 0.0; 367 SDxy = 0.0; 400 368 Xd = 0.0; 401 369 Yd = 0.0; -
classes/DelphesClasses.h
rcb46568 r3b99510 415 415 Float_t TOuter; // track position (z component) at the tracker edge 416 416 417 Float_t D 0; // track signed transverse impact parameter418 Float_t ErrorD0; // signed error on the track signed transverse impact parameter417 Float_t Dxy; // track signed transverse impact parameter 418 Float_t SDxy; // signed error on the track signed transverse impact parameter 419 419 Float_t Xd; // X coordinate of point of closest approach to vertex 420 420 Float_t Yd; // Y coordinate of point of closest approach to vertex … … 526 526 Float_t DeltaPhi; 527 527 528 TLorentzVector Momentum, Position, InitialPosition, Area; 529 530 Float_t L; // path length 531 Float_t D0; 532 Float_t ErrorD0; 533 Float_t DZ; 534 Float_t ErrorDZ; 535 Float_t P; 536 Float_t ErrorP; 537 Float_t PT; 538 Float_t ErrorPT; 539 Float_t CtgTheta; 540 Float_t ErrorCtgTheta; 541 Float_t Phi; 542 Float_t ErrorPhi; 543 528 TLorentzVector Momentum, Position, Area; 529 530 Float_t Dxy; 531 Float_t SDxy; 544 532 Float_t Xd; 545 533 Float_t Yd; -
modules/ImpactParameterSmearing.cc
rcb46568 r3b99510 96 96 { 97 97 Candidate *candidate, *particle, *mother; 98 Double_t xd, yd, zd, d 0, sx, sy, sz, dd0;98 Double_t xd, yd, zd, dxy, sx, sy, sz, ddxy; 99 99 Double_t pt, eta, px, py, phi, e; 100 100 … … 103 103 { 104 104 105 // take momentum before smearing (otherwise apply double smearing on d 0)105 // take momentum before smearing (otherwise apply double smearing on dxy) 106 106 particle = static_cast<Candidate*>(candidate->GetCandidates()->At(0)); 107 107 … … 131 131 132 132 // calculate impact parameter (after-smearing) 133 d 0= (xd*py - yd*px)/pt;133 dxy = (xd*py - yd*px)/pt; 134 134 135 dd 0= gRandom->Gaus(0.0, fFormula->Eval(pt, eta, phi, e));135 ddxy = gRandom->Gaus(0.0, fFormula->Eval(pt, eta, phi, e)); 136 136 137 137 // fill smeared values in candidate … … 143 143 candidate->Zd = zd; 144 144 145 candidate->D 0 = d0;146 candidate-> ErrorD0 = dd0;145 candidate->Dxy = dxy; 146 candidate->SDxy = ddxy; 147 147 148 148 candidate->AddCandidate(mother); -
modules/ModulesLinkDef.h
rcb46568 r3b99510 35 35 #include "modules/EnergySmearing.h" 36 36 #include "modules/MomentumSmearing.h" 37 #include "modules/TrackSmearing.h"38 37 #include "modules/ImpactParameterSmearing.h" 39 38 #include "modules/TimeSmearing.h" … … 58 57 #include "modules/StatusPidFilter.h" 59 58 #include "modules/PdgCodeFilter.h" 60 #include "modules/BeamSpotFilter.h"61 59 #include "modules/Cloner.h" 62 60 #include "modules/Weighter.h" … … 81 79 #pragma link C++ class EnergySmearing+; 82 80 #pragma link C++ class MomentumSmearing+; 83 #pragma link C++ class TrackSmearing+;84 81 #pragma link C++ class ImpactParameterSmearing+; 85 82 #pragma link C++ class TimeSmearing+; … … 104 101 #pragma link C++ class StatusPidFilter+; 105 102 #pragma link C++ class PdgCodeFilter+; 106 #pragma link C++ class BeamSpotFilter+;107 103 #pragma link C++ class Cloner+; 108 104 #pragma link C++ class Weighter+; -
modules/ParticlePropagator.cc
rcb46568 r3b99510 66 66 { 67 67 } 68 69 68 70 69 //------------------------------------------------------------------------------ … … 92 91 fItInputArray = fInputArray->MakeIterator(); 93 92 94 // import beamspot95 96 fBeamSpotInputArray = ImportArray(GetString("BeamSpotInputArray", "BeamSpotFilter/beamSpotParticle"));97 98 93 // create output arrays 99 94 … … 116 111 { 117 112 Candidate *candidate, *mother; 118 TLorentzVector candidatePosition, candidateMomentum , beamSpotPosition;113 TLorentzVector candidatePosition, candidateMomentum; 119 114 Double_t px, py, pz, pt, pt2, e, q; 120 115 Double_t x, y, z, t, r, phi; … … 125 120 Double_t tmp, discr, discr2; 126 121 Double_t delta, gammam, omega, asinrho; 127 Double_t rcu, rc2, xd, yd, zd; 128 Double_t l, d0, dz, p, ctgTheta, phip, etap, alpha; 129 Double_t bsx, bsy, bsz; 130 122 Double_t rcu, rc2, dxy, xd, yd, zd; 123 131 124 const Double_t c_light = 2.99792458E8; 132 133 if (!fBeamSpotInputArray->GetSize () || !fBeamSpotInputArray->At(0)) 134 beamSpotPosition.SetXYZT(0.0, 0.0, 0.0, 0.0); 135 else 136 { 137 Candidate &beamSpotCandidate = *((Candidate *) fBeamSpotInputArray->At(0)); 138 beamSpotPosition = beamSpotCandidate.Position; 139 } 140 125 141 126 fItInputArray->Reset(); 142 127 while((candidate = static_cast<Candidate*>(fItInputArray->Next()))) … … 147 132 y = candidatePosition.Y()*1.0E-3; 148 133 z = candidatePosition.Z()*1.0E-3; 149 150 bsx = beamSpotPosition.X()*1.0E-3;151 bsy = beamSpotPosition.Y()*1.0E-3;152 bsz = beamSpotPosition.Z()*1.0E-3;153 154 134 q = candidate->Charge; 155 135 … … 201 181 y_t = y + py*t; 202 182 z_t = z + pz*t; 203 204 l = TMath::Sqrt( (x_t - x)*(x_t - x) + (y_t - y)*(y_t - y) + (z_t - z)*(z_t - z));205 183 206 184 mother = candidate; … … 208 186 209 187 candidate->Position.SetXYZT(x_t*1.0E3, y_t*1.0E3, z_t*1.0E3, candidatePosition.T() + t*e*1.0E3); 210 candidate->L = l*1.0E3; 211 188 212 189 candidate->Momentum = candidateMomentum; 213 190 candidate->AddCandidate(mother); … … 261 238 yd = (rc2 > 0.0) ? yd / rc2 : -999; 262 239 zd = z + (TMath::Sqrt(xd*xd + yd*yd) - TMath::Sqrt(x*x + y*y))*pz/pt; 263 264 // use perigee momentum rather than original particle 265 // momentum, since the orignal particle momentum isn't known 266 267 px = TMath::Sign(1.0,r) * pt * (-y_c / r_c); 268 py = TMath::Sign(1.0,r) * pt * (x_c / r_c); 269 etap = candidateMomentum.Eta(); 270 phip = TMath::ATan2(py, px); 271 272 candidateMomentum.SetPtEtaPhiE(pt, etap, phip, candidateMomentum.E()); 273 274 // calculate additional track parameters (correct for beamspot position) 275 276 d0 = ( (x - bsx) * py - (y - bsy) * px) / pt; 277 dz = z - ((x - bsx) * px + (py - bsy) * py) / pt * (pz / pt); 278 p = candidateMomentum.P(); 279 ctgTheta = 1.0 / TMath::Tan (candidateMomentum.Theta ()); 280 240 241 // calculate impact paramater 242 dxy = (xd*py - yd*px)/pt; 243 281 244 // 3. time evaluation t = TMath::Min(t_r, t_z) 282 245 // t_r : time to exit from the sides … … 324 287 r_t = TMath::Hypot(x_t, y_t); 325 288 326 327 // compute path length for an helix328 329 alpha = pz*1.0E9 / c_light / gammam;330 l = t * TMath::Sqrt(alpha*alpha + r*r*omega*omega);331 332 289 if(r_t > 0.0) 333 290 { … … 338 295 339 296 candidate->Momentum = candidateMomentum; 340 341 candidate->L = l*1.0E3; 342 candidate->D0 = d0*1.0E3; 343 candidate->DZ = dz*1.0E3; 344 candidate->P = p; 345 candidate->PT = pt; 346 candidate->CtgTheta = ctgTheta; 347 candidate->Phi = phi; 348 349 candidate->Xd = xd*1.0E3; 297 candidate->Dxy = dxy*1.0E3; 298 candidate->Xd = xd*1.0E3; 350 299 candidate->Yd = yd*1.0E3; 351 300 candidate->Zd = zd*1.0E3; -
modules/ParticlePropagator.h
rcb46568 r3b99510 35 35 class TClonesArray; 36 36 class TIterator; 37 class TLorentzVector;38 37 39 38 class ParticlePropagator: public DelphesModule … … 56 55 57 56 const TObjArray *fInputArray; //! 58 const TObjArray *fBeamSpotInputArray; //!59 57 60 58 TObjArray *fOutputArray; //! -
modules/TrackCountingBTagging.cc
rcb46568 r3b99510 96 96 97 97 Double_t jpx, jpy; 98 Double_t dr, tp t;99 Double_t xd, yd, d 0, dd0, ip, sip;98 Double_t dr, tpx, tpy, tpt; 99 Double_t xd, yd, dxy, ddxy, ip, sip; 100 100 101 101 Int_t sign; … … 117 117 { 118 118 const TLorentzVector &trkMomentum = track->Momentum; 119 119 120 120 dr = jetMomentum.DeltaR(trkMomentum); 121 121 122 tpt = trkMomentum.Pt(); 123 tpx = trkMomentum.Px(); 124 tpy = trkMomentum.Py(); 125 122 126 xd = track->Xd; 123 127 yd = track->Yd; 124 d 0= TMath::Hypot(xd, yd);125 dd 0 = track->ErrorD0;128 dxy = TMath::Hypot(xd, yd); 129 ddxy = track->SDxy; 126 130 127 131 if(tpt < fPtMin) continue; 128 132 if(dr > fDeltaR) continue; 129 if(d 0> fIPmax) continue;133 if(dxy > fIPmax) continue; 130 134 131 135 sign = (jpx*xd + jpy*yd > 0.0) ? 1 : -1; 132 136 133 ip = sign*d 0;134 sip = ip / TMath::Abs(dd 0);137 ip = sign*dxy; 138 sip = ip / TMath::Abs(ddxy); 135 139 136 140 if(sip > fSigMin) count++; -
modules/TreeWriter.cc
rcb46568 r3b99510 292 292 entry->TOuter = position.T()*1.0E-3/c_light; 293 293 294 entry->D 0 = candidate->D0;295 entry-> ErrorD0 = candidate->ErrorD0;294 entry->Dxy = candidate->Dxy; 295 entry->SDxy = candidate->SDxy ; 296 296 entry->Xd = candidate->Xd; 297 297 entry->Yd = candidate->Yd;
Note:
See TracChangeset
for help on using the changeset viewer.