Extacting the OCDB in a separate module. The detectors have write permission in the...
[u/mrichter/AliRoot.git] / TPC / macros / recMag5.C
CommitLineData
2e5f5ec6 1void recMag5(const char *filename="data.root")
2{
3 /////////////////////////////////////////////////////////////////////////////////////////
4 //
5 // First version of the reconstruction
6 // script for the FDR'08
7
8 // Set the CDB storage location
9 // AliLog::SetModuleDebugLevel("STEER",2);
10 AliCDBManager * man = AliCDBManager::Instance();
11 // man->SetDefaultStorage("local://LocalCDB");
12 man->SetDefaultStorage("alien://folder=/alice/data/2008/LHC08b/OCDB/");
13 //man->SetDefaultStorage("local:///data/OCDB");
14
15 // Files that we can not read from alien...solved
162637e4 16 // man->SetSpecificStorage("ITS/Calib/MapsAnodeSDD","local://$ALICE_ROOT/OCDB");
17 // man->SetSpecificStorage("ITS/Calib/MapsTimeSDD","local://$ALICE_ROOT/OCDB");
18 // man->SetSpecificStorage("TPC/Calib/ExB","local://$ALICE_ROOT/OCDB");
2e5f5ec6 19
20 // Objects not found if using LHC07w database...solved
21 // man->SetSpecificStorage("ITS/Calib/MapsAnodeSDD","local:///afs/cern.ch/user/c/cheshkov/public/OCDB");
162637e4 22 // man->SetSpecificStorage("GRP/GRP/Data","local://$ALICE_ROOT/OCDB");
23 // man->SetSpecificStorage("ITS/Calib/DDLMapSDD","local://$ALICE_ROOT/OCDB");
24 // man->SetSpecificStorage("MUON/Calib/Mapping","local://$ALICE_ROOT/OCDB");
25 // man->SetSpecificStorage("MUON/Calib/DDLStore","local://$ALICE_ROOT/OCDB");
2e5f5ec6 26
27 AliITSRecoParam * itsRecoParam = AliITSRecoParam::GetCosmicTestParam();
28 itsRecoParam->SetFactorSAWindowSizes(20);
29 itsRecoParam->SetClusterErrorsParam(2);
30 itsRecoParam->SetFindV0s(kFALSE);
31 itsRecoParam->SetAddVirtualClustersInDeadZone(kFALSE);
32 itsRecoParam->SetUseAmplitudeInfo(kFALSE);
33 // In case we want to switch off a layer
34 // itsRecoParam->SetLayerToSkip(<N>);
35 // itsRecoParam->SetLayerToSkip(4);
36 // itsRecoParam->SetLayerToSkip(5);
37 itsRecoParam->SetLayerToSkip(2);
38 itsRecoParam->SetLayerToSkip(3);
39 itsRecoParam->SetClusterMisalError(1.0); // [cm]
40 itsRecoParam->SetSAUseAllClusters();
41 AliITSReconstructor::SetRecoParam(itsRecoParam);
42
43 // TPC settings
44 AliLog::SetClassDebugLevel("AliTPCclustererMI",2);
45 AliTPCRecoParam * tpcRecoParam = AliTPCRecoParam::GetCosmicTestParam(kFALSE);
46 Double_t sysError[5]={0.3,3, 0.3/150., 3./150.,0.3/(150*150.)};
47 tpcRecoParam->SetSystematicError(sysError);
48 tpcRecoParam->SetTimeInterval(60,940);
49 tpcRecoParam->Dump();
50 AliTPCReconstructor::SetRecoParam(tpcRecoParam);
51 AliTPCReconstructor::SetStreamLevel(10);
52
53
54 // TRD setting
55 AliTRDrawStreamBase::SetRawStreamVersion("TB");
56
57 // PHOS settings
58 AliPHOSRecoParam* recEmc = new AliPHOSRecoParamEmc();
59 recEmc->SetSubtractPedestals(kTRUE);
60 recEmc->SetMinE(0.05);
61 recEmc->SetClusteringThreshold(0.10);
62 AliPHOSReconstructor::SetRecoParamEmc(recEmc);
63
64 // T0 settings
65 AliLog::SetModuleDebugLevel("T0", 10);
66
67 // MUON settings
68 AliLog::SetClassDebugLevel("AliMUONRawStreamTracker",3);
69 AliMUONRecoParam *muonRecoParam = AliMUONRecoParam::GetLowFluxParam();
70 muonRecoParam->CombineClusterTrackReco(kTRUE);
71 muonRecoParam->SetCalibrationMode("NOGAIN");
72 //muonRecoParam->SetClusteringMode("PEAKFIT");
73 //muonRecoParam->SetClusteringMode("PEAKCOG");
74 muonRecoParam->Print("FULL");
75 AliRecoParam::Instance()->RegisterRecoParam(muonRecoParam);
76
77 // Tracking settings
2e5f5ec6 78 Double_t mostProbPt=0.35;
79 AliExternalTrackParam::SetMostProbablePt(mostProbPt);
80
81 // AliReconstruction settings
82 AliReconstruction rec;
83 rec.SetUniformFieldTracking(kFALSE);
84 rec.SetWriteESDfriend(kTRUE);
85 rec.SetWriteAlignmentData();
86 rec.SetInput(filename);
87 rec.SetRunReconstruction("ALL");
88 rec.SetUseTrackingErrorsForAlignment("ITS");
89
90 // In case some detectors have to be switched off...
91 // rec.SetRunLocalReconstruction("ALL");
92 // rec.SetRunTracking("ALL");
93 // rec.SetFillESD("ALL");
94 // Enable vertex finder - it is needed for cosmic track reco
95 rec.SetRunVertexFinder(kFALSE);
96
97 // To be enabled if some equipment IDs are not set correctly by DAQ
98 // rec.SetEquipmentIdMap("EquipmentIdMap.data");
99
100 // Detector options if any
101 // rec.SetOption("ITS","cosmics,onlyITS");
102 //rec.SetOption("ITS","cosmics,MI");
103 rec.SetOption("ITS","cosmics");
104 rec.SetOption("MUON","SAVEDIGITS");
105 rec.SetOption("TPC","OldRCUFormat");
106 rec.SetOption("PHOS","OldRCUFormat");
107 rec.SetOption("T0","cosmic");
108
109 // To be enabled when CTP readout starts
110 rec.SetFillTriggerESD(kFALSE);
111
112 // all events in one single file
113 rec.SetNumberOfEventsPerFile(-1);
114
115 // switch off cleanESD
116 rec.SetCleanESD(kFALSE);
117
118 // AliLog::SetGlobalDebugLevel(2);
119
120 rec.SetRunQA(kFALSE);
121 AliLog::Flush();
122 //TPC addition
123 rec.SetRunReconstruction("ITS TPC");
124 rec.SetFillESD("ITS TPC");
125 //rec.SetEventRange(0,40);
126 // filter logs
127 AliLog::SetClassDebugLevel("AliTPCRawStream",-5);
128 AliLog::SetClassDebugLevel("AliRawReaderDate",-5);
129 AliLog::SetClassDebugLevel("AliTPCAltroMapping",-5);
130 AliLog::SetModuleDebugLevel("RAW",-5);
131 //
132 rec.Run();
133
134 //cout << "-----------------------------------------------------------------" << endl;
135 //cout << "-----------------------------------------------------------------" << endl;
136 //cout << "--------- Reconstruction Completed. Start merging QAs -----------" << endl;
137 //cout << "-----------------------------------------------------------------" << endl;
138 //cout << "-----------------------------------------------------------------" << endl;
139 //AliQADataMakerSteer qas;
140 //qas.Merge();
141 // exit(10);
142}