4 Run this macro for cluster finder and track follower
5 (see steering class AliLevel3).
6 In argument path, you have to provide the path to the directory
7 where the data files should be located. In case of reading from a rootfile, you have to
8 make a symbolic link "digitfile.root", which points to the rootfile containing AliROOT
9 digits tree and a symbolic link "alirunfile.root" pointing to a file containing
10 the ALIROOT geometry (TPC param). For NEWIO, make sure that the
11 file TPC.Digits.root is in the path (symlink)!
13 RUN with ALIROOT (not ROOT) if using root files.
17 #include "AliL3Logger.h"
18 #include "AliL3FileHandler.h"
19 #include "AliL3DigitData.h"
20 #include "AliL3Transform.h"
21 #include "AliLevel3.h"
30 void runtracker(Int_t minslice=0,Int_t maxslice=35,Char_t* path="./",Int_t nevent=1,Char_t *opath="./tracker/")
32 //Set your configuration here:
33 AliLevel3::EFileType filetype=AliLevel3::kRoot; //Input is RLE binary files or rootfile.
34 Bool_t pileup=kFALSE; //Assume input is pileup event = non RLE binary files.
35 Bool_t nonvertex = kFALSE; //Set this to true if a second nonvertex contrained tracking pass should be performed.
36 Int_t npatches = 1; //Options; 1, 2 and 6.
38 Char_t trackparams[] = "SetTrackingParameters_4000bf04.C"; //Set this to correspond
39 //with mult. and BField
42 //for aliroot the path should point to a file
43 //containing the tpc geometry called alirunfile.root
44 Bool_t isinit=AliL3Transform::Init(path,(filetype!=AliLevel3::kBinary));
46 cerr << "Could not create transform settings, please check log for error messages!" << endl;
50 for(Int_t ev=0; ev<nevent; ev++)
53 if(filetype==AliLevel3::kBinary)
58 if(filetype==AliLevel3::kRaw)
59 sprintf(fname,"%s/raw.root",path);
61 sprintf(fname,"%s/digitfile.root",path);
62 a = new AliLevel3(fname);
65 a->Init(path,filetype,npatches);
68 gROOT->LoadMacro(trackparams);
69 SetTrackingParameters(a);
70 #else /* compiled for 4000 and 0.4 */
71 Int_t phi_segments,eta_segments,trackletlength,tracklength;
72 Int_t rowscopetracklet,rowscopetrack;
73 Double_t min_pt_fit,maxangle,goodDist,hitChi2Cut,xyerror,zerror;
74 Double_t goodHitChi2,trackChi2Cut,maxphi,maxeta;
76 phi_segments = 50; //devide the space into phi_segments and eta_segments
77 eta_segments = 100; //to access the search of points to that area!
78 trackletlength = 3; //number of hits a tracklet has to have
79 tracklength = 10; //number of hits a track has to have
80 rowscopetracklet = 2; //search range of rows for a tracklet
81 rowscopetrack = 10; //search range of rows for a track
83 maxangle = 0.1745; //AliL3Transform::Deg2Rad(10);
84 //maximum angle for the three point look ahead
85 goodDist = 5; //threshold distance between two hits when building tracklets
86 maxphi=0.1; //maximum phi difference for neighboring hits
87 maxeta=0.1; //maximum eta difference for neighboring hits
88 hitChi2Cut = 20; //maximum chi2 of added hit to track
89 goodHitChi2 = 5; //stop looking for next hit to add if chi2 is less than goodHitChi2
90 trackChi2Cut = 10; //maximum chi2 for track after final fit
94 a->SetClusterFinderParam(xyerror,zerror,kTRUE);
95 a->SetTrackerParam(phi_segments,eta_segments,trackletlength,tracklength,
96 rowscopetracklet,rowscopetrack,
97 min_pt_fit,maxangle,goodDist,hitChi2Cut,
98 goodHitChi2,trackChi2Cut,50,maxphi,maxeta,kTRUE);
102 //Set parameters for nonvertextracking
103 a->SetTrackerParam(phi_segments,eta_segments,trackletlength,tracklength,
104 rowscopetracklet,rowscopetrack,
105 min_pt_fit,maxangle,goodDist,hitChi2Cut,
106 goodHitChi2,trackChi2Cut,50,maxphi,maxeta,kFALSE);
112 //a->DoRoi(); /*do region of interest*/
113 //a->DoMc(); /*do monte carlo identification*/
116 a->DoNonVertexTracking(); /*2 tracking passes, last without vertex contraint.*/
118 a->WriteFiles(opath); /*enable output*/
119 a->ProcessEvent(minslice,maxslice);
121 sprintf(bname,"benchmark_tracker_%d",ev);