]> git.uio.no Git - u/mrichter/AliRoot.git/blame - TPC/recTPC.C
(Marian)
[u/mrichter/AliRoot.git] / TPC / recTPC.C
CommitLineData
53cc7be4 1//
2// example macro for reconstruction of the TPC raw data
3//
4// The path to the Calibration parameters is for the moment hard-wired in the code
5// Taken from /afs/
6//
7//
8
f3895d52 9void recTPC(Int_t type, const char *filename="data.root")
53cc7be4 10{
194b0609 11 //
12 // Set path to calibration data
13 //
530474cc 14 // type variable = 0 - cosmic test
15 // = 1 - laser test
53cc7be4 16 AliCDBManager * man = AliCDBManager::Instance();
17 man->SetDefaultStorage("local://$ALICE_ROOT");
18 man->SetRun(0);
53cc7be4 19 man->SetSpecificStorage("TPC","local:///afs/cern.ch/user/m/mivanov/public/Calib");
194b0609 20 //
21 // Set reconstruction parameters
22 //
23 AliLog::SetClassDebugLevel("AliTPCclustererMI",2);
f5d176d8 24 AliTPCRecoParam * tpcRecoParam = 0;
4f543b2f 25 if (type==0) tpcRecoParam = AliTPCRecoParam::GetCosmicTestParam(kTRUE);
26 if (type>0) tpcRecoParam = AliTPCRecoParam::GetLaserTestParam(kTRUE);
27 tpcRecoParam->Dump();
194b0609 28 AliTPCReconstructor::SetRecoParam(tpcRecoParam);
29 AliTPCReconstructor::SetStreamLevel(1);
30 //
31 //
32 //
53cc7be4 33 AliReconstruction rec;
34 rec.SetSpecificStorage("TPC","local:///afs/cern.ch/user/m/mivanov/public/Calib");
35 rec.SetLoadAlignData("");
36 rec.SetWriteESDfriend(kTRUE);
37 rec.SetInput(filename);
38 rec.SetEquipmentIdMap("EquipmentIdMap.data");
39 rec.SetRunReconstruction("TPC");
40 rec.SetOption("TPC","PedestalSubtraction OldRCUFormat");
41 // rec.SetRunLocalReconstruction("");
42 // rec.SetRunTracking("TPC");
43 rec.SetFillESD("TPC");
44 rec.SetFillTriggerESD(kFALSE);
45 rec.SetRunVertexFinder(kFALSE);
46 AliMagFMaps* field = new AliMagFMaps("Maps","Maps", 2, 1., 10., 1);
47 AliTracker::SetFieldMap(field,1);
53cc7be4 48 rec.SetWriteAlignmentData(kTRUE);
49 rec.Run();
50}
51
f3895d52 52void recTracking(Int_t type, const char *filename="data.root", Int_t nevents=1)
53cc7be4 53{
194b0609 54 //
55 // Set path to calibration data
56 //
53cc7be4 57 AliCDBManager * man = AliCDBManager::Instance();
58 man->SetDefaultStorage("local://$ALICE_ROOT");
59 man->SetRun(0);
53cc7be4 60 man->SetSpecificStorage("TPC","local:///afs/cern.ch/user/m/mivanov/public/Calib");
194b0609 61 //
62 // Set reconstruction parameters
63 //
64 AliLog::SetClassDebugLevel("AliTPCclustererMI",2);
f5d176d8 65
66 AliTPCRecoParam * tpcRecoParam = 0;
4f543b2f 67 if (type==0) tpcRecoParam = AliTPCRecoParam::GetCosmicTestParam(kTRUE);
68 if (type>0) tpcRecoParam = AliTPCRecoParam::GetLaserTestParam(kTRUE);
530474cc 69
194b0609 70 AliTPCReconstructor::SetRecoParam(tpcRecoParam);
71 AliTPCReconstructor::SetStreamLevel(1);
72
73 //
74 //
75 //
53cc7be4 76 AliReconstruction rec;
77 //rec.SetSpecificStorage("TPC","local:///afs/cern.ch/user/m/mivanov/public/Calib");
78 rec.SetLoadAlignData("");
79 rec.SetWriteESDfriend(kTRUE);
80 rec.SetInput(filename);
81 rec.SetEquipmentIdMap("EquipmentIdMap.data");
82 //rec.SetRunReconstruction("TPC");
83 rec.SetOption("TPC","PedestalSubtraction OldRCUFormat");
84 rec.SetRunLocalReconstruction("");
85 rec.SetRunTracking("TPC");
86 rec.SetFillESD("TPC");
87 rec.SetFillTriggerESD(kFALSE);
88 rec.SetRunVertexFinder(kFALSE);
89 AliMagFMaps* field = new AliMagFMaps("Maps","Maps", 2, 1., 10., 1);
90 AliTracker::SetFieldMap(field,1);
53cc7be4 91 rec.SetWriteAlignmentData(kTRUE);
92 rec.Run(0,nevents);
93}
94
95