]> git.uio.no Git - u/mrichter/AliRoot.git/blob - PWGPP/CalibMacros/CPass0/recCPass0.C
Steering macros and scripts: updated and merged with alien versions (after testing...
[u/mrichter/AliRoot.git] / PWGPP / CalibMacros / CPass0 / recCPass0.C
1 /*
2    rec.C to be used for pass0
3    - reconstruction of raw data
4    - QA information switched off
5    - store all friends
6    - default OCDB storage set to "raw://"
7
8    Example:
9    aliroot -b -q 'recCPass0.C("raw.root",100)'
10 */
11
12 void recCPass0(const char *filename="raw.root",Int_t nevents=-1, const char *ocdb="raw://", const char* options="?Trigger=kCalibBarrel")
13 {
14   // Load some system libs for Grid and monitoring
15   // Set the CDB storage location
16   AliCDBManager * man = AliCDBManager::Instance();
17   man->SetDefaultStorage(ocdb);
18   // Reconstruction settings
19   AliReconstruction rec;
20   // Upload CDB entries from the snapshot (local root file) if snapshot exist
21   if (gSystem->AccessPathName("OCDB.root", kFileExists)==0) {        
22     //rec.SetFromCDBSnapshot("OCDB.root");
23     rec.SetCDBSnapshotMode("OCDB.root");
24   }
25   // All friends
26   rec.SetFractionFriends(1.0);
27
28  // AliReconstruction settings - hardwired MB trigger for calibration
29
30   TString newfilename = filename;
31   newfilename += options;
32   rec.SetInput(newfilename.Data());
33
34   // Set protection against too many events in a chunk (should not happen)
35   if (nevents>0) rec.SetEventRange(0,nevents);
36
37   // Remove recpoints after each event
38   rec.SetDeleteRecPoints("TPC TRD ITS"); 
39   //
40
41
42   // Switch off the V0 finder - saves time!
43   //  rec.SetRunMultFinder(kFALSE);
44   rec.SetRunV0Finder(kFALSE); 
45
46   //
47   // QA options - all QA is off
48   //
49   rec.SetRunQA(":");
50   rec.SetRunGlobalQA(kFALSE);
51
52   // AliReconstruction settings
53   rec.SetWriteESDfriend(kTRUE);
54   rec.SetWriteAlignmentData();
55   rec.SetUseTrackingErrorsForAlignment("ITS");
56   rec.SetRunReconstruction("ALL");
57   rec.SetFillESD("ALL");
58   rec.SetCleanESD(kFALSE);
59
60   // Specific reco params for ZDC (why isn't this automatic?)
61 //  rec.SetRecoParam("ZDC",AliZDCRecoParamPbPb::GetHighFluxParam(2760));
62
63   //Ignore SetStopOnError
64   rec.SetStopOnError(kFALSE);
65
66   AliLog::Flush();
67   rec.Run();
68 }
69