]> git.uio.no Git - u/mrichter/AliRoot.git/blob - TPC/recTPC.C
ATO-18, ATO-19, PWGPP-102, ALIROOT-5603 - Separate dNdx:bg MC parameterization and...
[u/mrichter/AliRoot.git] / TPC / recTPC.C
1 /// \file recTPC.C
2 /// \brief 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 void recTPC(Int_t type, const char *filename="data.root")
8 {
9   //
10   // Set path to calibration data
11   //
12   // type variable = 0 - cosmic test
13   //               = 1 - laser test   
14   AliCDBManager * man = AliCDBManager::Instance();
15   man->SetDefaultStorage("local://$ALICE_ROOT/OCDB");
16   //man->SetRun(0);
17   //man->SetSpecificStorage("TPC/*/*","local:///afs/cern.ch/user/m/mivanov/public/Calib");
18   //
19   // Set reconstruction parameters
20   //
21   AliLog::SetClassDebugLevel("AliTPCclusterer",2);
22   AliTPCRecoParam * tpcRecoParam = 0;
23   if (type==0)  tpcRecoParam = AliTPCRecoParam::GetCosmicTestParam(kTRUE);
24   if (type>0)  tpcRecoParam = AliTPCRecoParam::GetLaserTestParam(kTRUE);
25   tpcRecoParam->Dump();
26   AliTPCReconstructor::SetRecoParam(tpcRecoParam);
27   AliTPCReconstructor::SetStreamLevel(1);
28   //
29   //
30   //
31   AliReconstruction rec;  
32   rec.SetDefaultStorage("local://$ALICE_ROOT/OCDB");
33   rec.SetSpecificStorage("TPC/*/*","local:///afs/cern.ch/user/m/mivanov/public/Calib");
34   rec.SetLoadAlignData("");
35   rec.SetWriteESDfriend(kTRUE);
36   rec.SetInput(filename);
37   rec.SetEquipmentIdMap("EquipmentIdMap.data");
38   rec.SetRunReconstruction("TPC");
39   rec.SetOption("TPC","PedestalSubtraction");
40   //  rec.SetRunLocalReconstruction("");
41   //  rec.SetRunTracking("TPC");
42   rec.SetFillESD("TPC");
43   rec.SetFillTriggerESD(kFALSE);
44   rec.SetRunVertexFinder(kFALSE);
45   rec.SetWriteAlignmentData(kTRUE);
46   rec.Run();
47 }
48
49 void recTracking(Int_t type, const char *filename="data.root")
50 {
51   //
52   // Set path to calibration data
53   //
54   AliCDBManager * man = AliCDBManager::Instance();
55   man->SetDefaultStorage("local://$ALICE_ROOT/OCDB");
56   man->SetRun(0);
57   man->SetSpecificStorage("TPC/*/*","local:///afs/cern.ch/user/m/mivanov/public/Calib");
58   //
59   // Set reconstruction parameters
60   //
61   AliLog::SetClassDebugLevel("AliTPCclusterer",2);
62
63   AliTPCRecoParam * tpcRecoParam = 0;
64   if (type==0)  tpcRecoParam = AliTPCRecoParam::GetCosmicTestParam(kTRUE);
65   if (type>0)  tpcRecoParam = AliTPCRecoParam::GetLaserTestParam(kTRUE);
66
67   AliTPCReconstructor::SetRecoParam(tpcRecoParam);
68   AliTPCReconstructor::SetStreamLevel(1);
69
70   //
71   //
72   //
73   AliReconstruction rec;
74   rec.SetSpecificStorage("TPC/*/*","local:///afs/cern.ch/user/m/mivanov/public/Calib");
75   rec.SetLoadAlignData("");
76   rec.SetWriteESDfriend(kTRUE);
77   rec.SetInput(filename);
78   rec.SetEquipmentIdMap("EquipmentIdMap.data");
79   //rec.SetRunReconstruction("TPC");
80   rec.SetOption("TPC","PedestalSubtraction");
81   rec.SetRunLocalReconstruction("");
82   rec.SetRunTracking("TPC");
83   rec.SetFillESD("TPC");
84   rec.SetFillTriggerESD(kFALSE);
85   rec.SetRunVertexFinder(kFALSE);
86   rec.SetWriteAlignmentData(kTRUE);
87   rec.Run(0);
88 }
89
90