]>
Commit | Line | Data |
---|---|---|
cc727848 | 1 | /************************************************************************** |
2 | * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * | |
3 | * * | |
4 | * Author: The ALICE Off-line Project. * | |
5 | * Contributors are mentioned in the code where appropriate. * | |
6 | * * | |
7 | * Permission to use, copy, modify and distribute this software and its * | |
8 | * documentation strictly for non-commercial purposes is hereby granted * | |
9 | * without fee, provided that the above copyright notice appears in all * | |
10 | * copies and that both the copyright notice and this permission notice * | |
11 | * appear in the supporting documentation. The authors make no claims * | |
12 | * about the suitability of this software for any purpose. It is * | |
13 | * provided "as is" without express or implied warranty. * | |
14 | **************************************************************************/ | |
15 | ||
16 | /* $Id: runReconstruction.C 23207 2007-12-20 09:59:20Z ivana $ */ | |
17 | ||
18 | /// \ingroup macros | |
58681b6e | 19 | /// \file runDataReconstruction.C |
cc727848 | 20 | /// \brief Macro for running reconstruction |
21 | /// | |
22 | /// Macro for running reconstruction on the cosmics run data. | |
23 | /// | |
24 | /// \author Laurent Aphecetche, Nicole Bastid, Bogdan Vulpescu, ... | |
25 | ||
26 | #if !defined(__CINT__) || defined(__MAKECINT__) | |
27 | #include "AliMUONReconstructor.h" | |
28 | #include "AliMUONRecoParam.h" | |
29 | #include "AliRecoParam.h" | |
30 | #include "AliCDBManager.h" | |
31 | #include "AliMagFMaps.h" | |
32 | #include "AliTracker.h" | |
33 | #include "AliReconstruction.h" | |
34 | #include <TRandom.h> | |
35 | #include <TGrid.h> | |
36 | //#include <TObjectTable.h> | |
37 | #endif | |
38 | ||
39 | // Data file, OCDB on Grid | |
0e894e58 | 40 | TString input="alien:///alice/data/2008/LHC08a/000024841/raw/08000024841010.10.root"; |
41 | //TString input="alien:///alice/data/2008/LHC08a/000021931/raw/08000021931001.50.root"; | |
cc727848 | 42 | TString ocdbPath = "alien://folder=/alice/data/2008/LHC08a/OCDB"; |
43 | ||
44 | // Data file, OCDB locally | |
45 | //TString input="$ALICE_ROOT/MUON/test_out.100/raw.root"; | |
46 | //TString ocdbPath = "local://$ALICE_ROOT"; | |
47 | ||
48 | TString caliboption1 = "NOGAIN"; | |
49 | TString caliboption2 = "GAINCONSTANTCAPA"; | |
50 | TString recoptions = "SAVEDIGITS"; | |
51 | Int_t seed = 1234567; | |
52 | ||
53 | void runDataReconstruction(Int_t calib = 1) | |
54 | { | |
55 | TGrid::Connect("alien://"); | |
0e894e58 | 56 | |
cc727848 | 57 | AliCDBManager* man = AliCDBManager::Instance(); |
58 | man->SetDefaultStorage(ocdbPath.Data()); | |
294be350 | 59 | //man->SetSpecificStorage("MUON/Calib/Mapping","local://$ALICE_ROOT"); |
60 | //man->SetSpecificStorage("MUON/Calib/DDLStore","local://$ALICE_ROOT"); | |
a0bf7089 | 61 | //man->SetSpecificStorage("MUON/Calib/Gains","local://$ALICE_ROOT"); |
0e894e58 | 62 | |
cc727848 | 63 | gRandom->SetSeed(seed); |
64 | ||
0e894e58 | 65 | // no magnetic field --> factor (4th parameter) = 0 |
66 | AliMagFMaps* field = new AliMagFMaps("Maps","Maps", 1, 0., 10., AliMagFMaps::k5kG); | |
cc727848 | 67 | AliTracker::SetFieldMap(field, kFALSE); |
68 | AliReconstruction *MuonRec = new AliReconstruction(); | |
0e894e58 | 69 | |
70 | ||
cc727848 | 71 | MuonRec->SetInput(input.Data()); |
72 | MuonRec->SetRunVertexFinder(kFALSE); | |
73 | MuonRec->SetRunLocalReconstruction("MUON"); | |
74 | MuonRec->SetRunTracking("MUON"); | |
75 | MuonRec->SetFillESD(" "); | |
76 | MuonRec->SetLoadAlignData("MUON"); | |
77 | MuonRec->SetNumberOfEventsPerFile(1000); | |
78 | MuonRec->SetOption("MUON",recoptions.Data()); | |
79 | // MuonRec->SetEventRange(319,319); | |
80 | MuonRec->SetWriteAOD(); | |
81 | //MuonRec.SetEventRange(0,100); | |
0e894e58 | 82 | AliMUONRecoParam *muonRecoParam = AliMUONRecoParam::GetCosmicParam(); |
83 | muonRecoParam->BypassSt45(kTRUE); | |
84 | muonRecoParam->RequestStation(2,kFALSE); | |
cc727848 | 85 | TString caliboption = caliboption1; |
86 | if ( calib == 2 ) caliboption = caliboption2; | |
87 | muonRecoParam->SetCalibrationMode(caliboption.Data()); | |
88 | //muonRecoParam->SetClusteringMode("PEAKFIT"); | |
89 | //muonRecoParam->SetClusteringMode("PEAKCOG"); | |
90 | muonRecoParam->Print("FULL"); | |
91 | AliRecoParam::Instance()->RegisterRecoParam(muonRecoParam); | |
92 | ||
93 | MuonRec->Run(); | |
94 | ||
95 | delete MuonRec; | |
96 | ||
97 | //gObjectTable->Print(); | |
98 | } | |
99 |