- Timestamp:
- Apr 17, 2014, 10:54:17 AM (11 years ago)
- Location:
- trunk
- Files:
-
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/classes/DelphesClasses.cc
r1368 r1372 112 112 Position(0.0, 0.0, 0.0, 0.0), 113 113 Dxy(0),SDxy(0),Xd(0),Yd(0),Zd(0), 114 Tau1(0.0), Tau2(0.0), Tau3(0.0), Tau4(0.0), Tau5(0.0), 114 Tau1(0.0), Tau2(0.0), Tau3(0.0), Tau4(0.0), Tau5(0.0), 115 115 Area(0.0, 0.0, 0.0, 0.0), 116 116 NCharged(0), … … 241 241 object.Tau4 = Tau4; 242 242 object.Tau5 = Tau5; 243 243 244 244 object.fFactory = fFactory; 245 245 object.fArray = 0; … … 303 303 Tau4 = 0.0; 304 304 Tau5 = 0.0; 305 305 306 306 fArray = 0; 307 307 } -
trunk/classes/DelphesClasses.h
r1368 r1372 107 107 Int_t IsPU; // 0 or 1 for particles from pile-up interactions 108 108 109 110 109 Int_t M1; // particle 1st mother | hepevt.jmohep[number][0] - 1 111 110 Int_t M2; // particle 2nd mother | hepevt.jmohep[number][1] - 1 … … 299 298 300 299 Float_t EhadOverEem; // ratio of the hadronic versus electromagnetic energy deposited in the calorimeter 301 302 TRefArray Constituents; // references to constituents303 TRefArray Particles; // references to generated particles304 305 static CompBase *fgCompare; //!306 const CompBase *GetCompare() const { return fgCompare; }307 308 TLorentzVector P4();309 300 310 301 // -- PileUpJetID variables --- … … 319 310 320 311 // -- Nsubjettiness variables --- 321 322 Float_t Tau1; 323 Float_t Tau2; 324 Float_t Tau3; 325 Float_t Tau4; 326 Float_t Tau5; 312 313 Float_t Tau1; 314 Float_t Tau2; 315 Float_t Tau3; 316 Float_t Tau4; 317 Float_t Tau5; 318 319 TRefArray Constituents; // references to constituents 320 TRefArray Particles; // references to generated particles 321 322 static CompBase *fgCompare; //! 323 const CompBase *GetCompare() const { return fgCompare; } 324 325 TLorentzVector P4(); 327 326 328 327 ClassDef(Jet, 2) … … 355 354 Float_t ZOuter; // track position (z component) at the tracker edge 356 355 Float_t TOuter; // track position (z component) at the tracker edge 357 356 358 357 Float_t Dxy; // track signed transverse impact parameter 359 358 Float_t SDxy; // signed error on the track signed transverse impact parameter … … 369 368 TLorentzVector P4(); 370 369 371 ClassDef(Track, 1)370 ClassDef(Track, 2) 372 371 }; 373 372 … … 456 455 457 456 TLorentzVector Momentum, Position, Area; 458 459 Float_t Dxy; 460 Float_t SDxy; 461 Float_t Xd; 462 Float_t Yd; 463 Float_t Zd; 457 458 Float_t Dxy; 459 Float_t SDxy; 460 Float_t Xd; 461 Float_t Yd; 462 Float_t Zd; 464 463 465 464 // PileUpJetID variables … … 472 471 Float_t PTD; 473 472 Float_t FracPt[5]; 474 473 475 474 // -- Nsubjettiness variables --- 476 477 Float_t Tau1; 478 Float_t Tau2; 479 Float_t Tau3; 480 Float_t Tau4; 481 Float_t Tau5; 482 475 476 Float_t Tau[5]; 477 483 478 static CompBase *fgCompare; //! 484 479 const CompBase *GetCompare() const { return fgCompare; } … … 499 494 void SetFactory(DelphesFactory *factory) { fFactory = factory; } 500 495 501 ClassDef(Candidate, 1)496 ClassDef(Candidate, 2) 502 497 }; 503 498 -
trunk/modules/FastJetFinder.cc
r1368 r1372 47 47 #include "fastjet/plugins/CDFCones/fastjet/CDFJetCluPlugin.hh" 48 48 49 #include "fastjet/contribs/Nsubjettiness/Nsubjettiness.hh" 49 #include "fastjet/contribs/Nsubjettiness/Nsubjettiness.hh" 50 50 #include "fastjet/contribs/Nsubjettiness/Njettiness.hh" 51 51 #include "fastjet/contribs/Nsubjettiness/NjettinessPlugin.hh" … … 76 76 void FastJetFinder::Init() 77 77 { 78 78 79 79 JetDefinition::Plugin *plugin = NULL; 80 80 JetDefinition::Recombiner *recomb = NULL; 81 81 NjettinessPlugin *njet_plugin = NULL; 82 82 83 83 // read eta ranges 84 84 … … 110 110 111 111 //-- N(sub)jettiness parameters -- 112 112 113 113 fComputeNsubjettiness = GetBool("ComputeNsubjettiness", false); 114 114 fBeta = GetDouble("Beta", 1.0); 115 115 fAxisMode = GetInt("AxisMode", 1); 116 fRcutOff = GetDouble("RcutOff", 0.8); // used only if Njettiness is used as jet clustering algo (case 8)117 fN = GetInt("N", 2); // used only if Njettiness is used as jet clustering algo (case 8)118 116 fRcutOff = GetDouble("RcutOff", 0.8); // used only if Njettiness is used as jet clustering algo (case 8) 117 fN = GetInt("N", 2); // used only if Njettiness is used as jet clustering algo (case 8) 118 119 119 // --- Jet Area Parameters --- 120 120 fAreaAlgorithm = GetInt("AreaAlgorithm", 0); 121 121 fComputeRho = GetBool("ComputeRho", false); 122 122 123 123 // - ghost based areas - 124 124 fGhostEtaMax = GetDouble("GhostEtaMax", 5.0); … … 128 128 fPtScatter = GetDouble("PtScatter", 0.1); 129 129 fMeanGhostPt = GetDouble("MeanGhostPt", 1.0E-100); 130 130 131 131 // - voronoi based areas - 132 132 fEffectiveRfact = GetDouble("EffectiveRfact", 1.0); … … 188 188 break; 189 189 } 190 191 190 192 191 fPlugin = plugin; 193 192 fRecomb = recomb; 194 193 fNjettinessPlugin = njet_plugin; 195 194 196 195 ClusterSequence::print_banner(); 197 196 … … 299 298 inputList.clear(); 300 299 inputList = sequence->constituents(*itOutputList); 301 300 302 301 for(itInputList = inputList.begin(); itInputList != inputList.end(); ++itInputList) 303 302 { … … 308 307 if(deta > detaMax) detaMax = deta; 309 308 if(dphi > dphiMax) dphiMax = dphi; 310 309 311 310 time += TMath::Sqrt(constituent->Momentum.E())*(constituent->Position.T()); 312 311 weightTime += TMath::Sqrt(constituent->Momentum.E()); 313 312 314 313 candidate->AddCandidate(constituent); 315 314 } 316 315 317 316 avTime = time/weightTime; 318 317 … … 325 324 326 325 // --- compute N-subjettiness with N = 1,2,3,4,5 ---- 327 326 328 327 if(fComputeNsubjettiness) 329 328 { 330 329 Njettiness::AxesMode axisMode; 331 332 if (fAxisMode == 1) axisMode = Njettiness::wta_kt_axes; 333 if (fAxisMode == 2) axisMode = Njettiness::onepass_wta_kt_axes; 334 if (fAxisMode == 3) axisMode = Njettiness::kt_axes; 335 if (fAxisMode == 4) axisMode = Njettiness::onepass_kt_axes; 336 330 331 switch(fAxisMode) 332 { 333 default: 334 case 1: 335 axisMode = Njettiness::wta_kt_axes; 336 break; 337 case 2: 338 axisMode = Njettiness::onepass_wta_kt_axes; 339 break; 340 case 3: 341 axisMode = Njettiness::kt_axes; 342 break; 343 case 4: 344 axisMode = Njettiness::onepass_kt_axes; 345 break; 346 } 347 337 348 Njettiness::MeasureMode measureMode = Njettiness::unnormalized_measure; 338 349 339 350 Nsubjettiness nSub1(1, axisMode, measureMode, fBeta); 340 351 Nsubjettiness nSub2(2, axisMode, measureMode, fBeta); 341 Nsubjettiness nSub3(3, axisMode, measureMode, fBeta); 342 Nsubjettiness nSub4(4, axisMode, measureMode, fBeta); 343 Nsubjettiness nSub5(5, axisMode, measureMode, fBeta); 344 345 candidate -> Tau1= nSub1(*itOutputList);346 candidate -> Tau2= nSub2(*itOutputList);347 candidate -> Tau3= nSub3(*itOutputList);348 candidate -> Tau4= nSub4(*itOutputList);349 candidate -> Tau5= nSub5(*itOutputList);352 Nsubjettiness nSub3(3, axisMode, measureMode, fBeta); 353 Nsubjettiness nSub4(4, axisMode, measureMode, fBeta); 354 Nsubjettiness nSub5(5, axisMode, measureMode, fBeta); 355 356 candidate->Tau[0] = nSub1(*itOutputList); 357 candidate->Tau[1] = nSub2(*itOutputList); 358 candidate->Tau[2] = nSub3(*itOutputList); 359 candidate->Tau[3] = nSub4(*itOutputList); 360 candidate->Tau[4] = nSub5(*itOutputList); 350 361 } 351 362 -
trunk/modules/FastJetFinder.h
r1368 r1372 43 43 void *fRecomb; //! 44 44 void *fNjettinessPlugin; //! 45 45 46 46 fastjet::JetDefinition *fDefinition; //! 47 47 … … 59 59 60 60 //-- N (sub)jettiness parameters -- 61 61 62 62 Bool_t fComputeNsubjettiness; 63 63 Double_t fBeta; 64 64 Int_t fAxisMode; 65 Double_t fRcutOff; 65 Double_t fRcutOff; 66 66 Int_t fN ; 67 67 68 68 // --- FastJet Area method -------- 69 69 -
trunk/modules/ImpactParameterSmearing.cc
r1367 r1372 121 121 122 122 ddxy = gRandom->Gaus(0,fFormula->Eval(pt, eta)); 123 ddz 123 ddz = gRandom->Gaus(0,fFormula->Eval(pt, eta)); 124 124 125 125 //fill smeared values in candidate … … 127 127 128 128 candidate = static_cast<Candidate*>(candidate->Clone()); 129 candidate ->Xd = xd;130 candidate ->Yd = yd;131 candidate ->Zd = zd;129 candidate->Xd = xd; 130 candidate->Yd = yd; 131 candidate->Zd = zd; 132 132 133 candidate ->Dxy = dxy;134 candidate ->SDxy = ddxy;133 candidate->Dxy = dxy; 134 candidate->SDxy = ddxy; 135 135 136 136 candidate->AddCandidate(mother); 137 137 fOutputArray->Add(candidate); 138 139 140 141 138 } 142 139 } -
trunk/modules/TrackCountingBTagging.cc
r1367 r1372 2 2 /** \class TrackCountingBTagging 3 3 * 4 * b tagging algorithm based on counting tracks with large impact parameterDetermines origin of jet,4 * b-tagging algorithm based on counting tracks with large impact parameter 5 5 * 6 6 * $Date: 2014-03-27 12:39:14 +0200 (Fri, 27 March 2014) $ … … 25 25 #include "TLorentzVector.h" 26 26 27 #include <algorithm> 27 #include <algorithm> 28 28 #include <stdexcept> 29 29 #include <iostream> … … 31 31 32 32 using namespace std; 33 34 33 35 34 //------------------------------------------------------------------------------ … … 50 49 void TrackCountingBTagging::Init() 51 50 { 52 53 51 fBitNumber = GetInt("BitNumber", 0); 54 52 55 53 fPtMin = GetDouble("TrackPtMin", 1.0); 56 54 fDeltaR = GetDouble("DeltaR", 0.3); 57 55 fIPmax = GetDouble("TrackIPMax", 2.0); 58 56 59 57 fSigMin = GetDouble("SigMin", 6.5); 60 fNtracks = GetInt("Ntracks", 3); 61 58 fNtracks = GetInt("Ntracks", 3); 59 62 60 // import input array(s) 63 61 64 62 fTrackInputArray = ImportArray(GetString("TrackInputArray", "Calorimeter/eflowTracks")); 65 63 fItTrackInputArray = fTrackInputArray->MakeIterator(); 66 64 67 65 fJetInputArray = ImportArray(GetString("JetInputArray", "FastJetFinder/jets")); 68 66 fItJetInputArray = fJetInputArray->MakeIterator(); … … 82 80 { 83 81 Candidate *jet, *track; 84 82 85 83 Double_t jpx, jpy; 86 84 Double_t dr, tpx, tpy, tpt; 87 85 Double_t xd, yd, dxy, ddxy, ip, sip; 88 86 89 87 Int_t sign; 90 88 91 89 Int_t count; 92 90 93 91 // loop over all input jets 94 92 fItJetInputArray->Reset(); … … 98 96 jpx = jetMomentum.Px(); 99 97 jpy = jetMomentum.Py(); 100 98 101 99 // loop over all input tracks 102 100 fItTrackInputArray->Reset(); … … 104 102 while((track = static_cast<Candidate*>(fItTrackInputArray->Next()))) 105 103 { 106 const TLorentzVector &trkMomentum = track->Momentum; 107 108 dr = jetMomentum.DeltaR(trkMomentum); 109 110 tpt = trkMomentum.Pt(); 111 tpx = trkMomentum.Px(); 112 tpy = trkMomentum.Py(); 113 114 xd = track->Xd; 115 yd = track->Yd; 116 dxy = TMath::Abs(track->Dxy); 117 ddxy = track->SDxy; 118 119 if( tpt < fPtMin ) continue; 120 if( dr > fDeltaR ) continue; 121 if( dxy > fIPmax ) continue; 122 123 sign = ( jpx*xd + jpy*yd > 0.0 ) ? 1 : -1; 124 125 ip = sign*dxy; 126 sip = ip / TMath::Abs(ddxy); 127 128 if( sip > fSigMin ) count++; 129 104 const TLorentzVector &trkMomentum = track->Momentum; 105 106 dr = jetMomentum.DeltaR(trkMomentum); 107 108 tpt = trkMomentum.Pt(); 109 tpx = trkMomentum.Px(); 110 tpy = trkMomentum.Py(); 111 112 xd = track->Xd; 113 yd = track->Yd; 114 dxy = TMath::Abs(track->Dxy); 115 ddxy = track->SDxy; 116 117 if(tpt < fPtMin) continue; 118 if(dr > fDeltaR) continue; 119 if(dxy > fIPmax) continue; 120 121 sign = (jpx*xd + jpy*yd > 0.0) ? 1 : -1; 122 123 ip = sign*dxy; 124 sip = ip / TMath::Abs(ddxy); 125 126 if(sip > fSigMin) count++; 130 127 } 131 128 132 129 // set BTag flag to true if count >= Ntracks 133 jet->BTag |= ( count >= fNtracks) << fBitNumber;130 jet->BTag |= (count >= fNtracks) << fBitNumber; 134 131 } 135 132 } -
trunk/modules/TrackCountingBTagging.h
r1367 r1372 4 4 /** \class TrackCountingBTagging 5 5 * 6 * b tagging algorithm based on counting tracks with large impact parameter6 * b-tagging algorithm based on counting tracks with large impact parameter 7 7 * 8 8 * $Date: 2014-03-27 12:39:14 +0200 (Fri, 27 March 2014) $ … … 35 35 36 36 Int_t fBitNumber; 37 37 38 38 Double_t fPtMin; 39 39 Double_t fDeltaR; … … 41 41 Double_t fSigMin; 42 42 Int_t fNtracks; 43 43 44 44 TIterator *fItTrackInputArray; //! 45 45 TIterator *fItJetInputArray; //! … … 47 47 const TObjArray *fTrackInputArray; //! 48 48 const TObjArray *fJetInputArray; //! 49 49 50 50 ClassDef(TrackCountingBTagging, 1) 51 51 }; -
trunk/modules/TreeWriter.cc
r1368 r1372 280 280 entry->Dxy = candidate->Dxy; 281 281 entry->SDxy = candidate->SDxy ; 282 entry->Xd = candidate ->Xd;283 entry->Yd = candidate ->Yd;284 entry->Zd = candidate ->Zd;282 entry->Xd = candidate->Xd; 283 entry->Yd = candidate->Yd; 284 entry->Zd = candidate->Zd; 285 285 286 286 const TLorentzVector &momentum = candidate->Momentum; … … 473 473 474 474 entry->T = position.T()*1.0E-3/c_light; 475 476 // cout<<entry->PT<<","<<entry->T<<endl;477 475 478 476 entry->Charge = candidate->Charge; … … 557 555 //--- N-subjettiness variables ---- 558 556 559 entry->Tau1 = candidate->Tau 1;560 entry->Tau2 = candidate->Tau 2;561 entry->Tau3 = candidate->Tau 3;562 entry->Tau4 = candidate->Tau 4;563 entry->Tau5 = candidate->Tau 5;557 entry->Tau1 = candidate->Tau[0]; 558 entry->Tau2 = candidate->Tau[1]; 559 entry->Tau3 = candidate->Tau[2]; 560 entry->Tau4 = candidate->Tau[3]; 561 entry->Tau5 = candidate->Tau[4]; 564 562 565 563 FillParticles(candidate, &entry->Particles);
Note:
See TracChangeset
for help on using the changeset viewer.