Adding rec.C for test TPC data
[u/mrichter/AliRoot.git] / TPC / macros / testTPC / rec.C
CommitLineData
d1ad7a9c 1void rec(const char *filename="data.root")\r
2{\r
3 gSystem->Load("libXrdClient.so");
4 gSystem->Load("libNetX.so");
5 //\r
6 // First version of the reconstruction\r
7 // script for the FDR'07\r
8\r
9 // Set the CDB storage location\r
10 // AliLog::SetModuleDebugLevel("STEER",2);\r
11 AliCDBManager * man = AliCDBManager::Instance();\r
12 //man->SetDefaultStorage("alien://folder=/alice/data/2007/LHC07w/OCDB/");\r
13 man->SetDefaultStorage("/data/test2007/OCDB");\r
14 man->SetSpecificStorage("GRP/GRP/Data","local://$ALICE_ROOT");\r
15 man->SetSpecificStorage("ITS/Calib/DDLMapSDD","local://$ALICE_ROOT");\r
16 man->SetSpecificStorage("MUON/Calib/Mapping","local://$ALICE_ROOT");\r
17 man->SetSpecificStorage("MUON/Calib/DDLStore","local://$ALICE_ROOT");\r
18\r
19 // TPC settings\r
20 AliLog::SetClassDebugLevel("AliTPCclustererMI",2);\r
21 AliTPCRecoParam * tpcRecoParam = AliTPCRecoParam::GetCosmicTestParam(kTRUE);\r
22 tpcRecoParam->SetTimeInterval(60,940);\r
23 tpcRecoParam->Dump();\r
24 AliTPCReconstructor::SetRecoParam(tpcRecoParam);\r
25 AliTPCReconstructor::SetStreamLevel(1);\r
26\r
27 // PHOS settings\r
28 AliPHOSRecoParam* recEmc = new AliPHOSRecoParamEmc();\r
29 recEmc->SetSubtractPedestals(kTRUE);\r
30 recEmc->SetMinE(0.05);\r
31 recEmc->SetClusteringThreshold(0.10);\r
32 AliPHOSReconstructor::SetRecoParamEmc(recEmc);\r
33\r
34 // T0 settings\r
35 AliLog::SetModuleDebugLevel("T0", 10);\r
36\r
37 // MUON settings\r
38 AliLog::SetClassDebugLevel("AliMUONRawStreamTracker",3);\r
39 \r
40 // Tracking settings\r
41 // AliMagFMaps* field = new AliMagFMaps("Maps","Maps", 2, 1., 10., 1);\r
42 AliMagFMaps* field = new AliMagFMaps("Maps","Maps", 2, 0., 10., 2);\r
43 AliTracker::SetFieldMap(field,1);\r
44\r
45 // AliReconstruction settings\r
46 AliReconstruction rec;\r
47 rec.SetUniformFieldTracking(kFALSE);\r
48 rec.SetWriteESDfriend(kTRUE);\r
49 rec.SetWriteAlignmentData();\r
50 rec.SetInput(filename);\r
51 //
52 //rec.SetRunLocalReconstruction("");\r
53 rec.SetRunReconstruction("TPC");\r
54 rec.SetFillESD("TPC");
55 rec.SetRunVertexFinder(kFALSE);
56 rec.SetRunQA(kFALSE);
57 //
58 //rec.SetEventRange(1,5);\r
59\r
60 // In case some detectors have to be switched off...\r
61 // rec.SetRunLocalReconstruction("ALL");\r
62 // rec.SetRunTracking("ALL");\r
63 // rec.SetFillESD("ALL");\r
64 // Disable vertex finder for the moment\r
65 // rec.SetRunVertexFinder(kFALSE);\r
66\r
67 // To be enabled if some equipment IDs are not set correctly by DAQ\r
68 // rec.SetEquipmentIdMap("EquipmentIdMap.data");\r
69\r
70 // Detector options if any\r
71 rec.SetOption("MUON","SAVEDIGITS");\r
72 rec.SetOption("TPC","OldRCUFormat");\r
73 rec.SetOption("PHOS","OldRCUFormat");\r
74\r
75 // To be enabled when CTP readout starts\r
76 rec.SetFillTriggerESD(kFALSE);\r
77\r
78 // all events in one single file\r
79 rec.SetNumberOfEventsPerFile(-1);\r
80\r
81 // switch off cleanESD\r
82 rec.SetCleanESD(kFALSE);\r
83\r
84 //AliLog::SetGlobalDebugLevel(2);\r
85 rec.Run();\r
86\r
87 cout << "-----------------------------------------------------------------" << endl;\r
88 cout << "-----------------------------------------------------------------" << endl;\r
89 cout << "--------- Reconstruction Completed. Start merging QAs -----------" << endl;\r
90 cout << "-----------------------------------------------------------------" << endl;\r
91 cout << "-----------------------------------------------------------------" << endl;\r
92 AliQADataMakerSteer qas;\r
93 qas.Merge();\r
94}\r