X-Git-Url: http://git.uio.no/git/?a=blobdiff_plain;f=MUON%2FrunDataReconstruction.C;h=6d0da1d3f4d79c946cb476676ee5ec89034f134c;hb=46c6c63143ebab83308f758b67883d2f8855885c;hp=abff02300881468f45b51f76732798aa0f1f46c6;hpb=cc7278485c00d0442bef5e365025c5559d9bf74f;p=u%2Fmrichter%2FAliRoot.git diff --git a/MUON/runDataReconstruction.C b/MUON/runDataReconstruction.C index abff0230088..6d0da1d3f4d 100644 --- a/MUON/runDataReconstruction.C +++ b/MUON/runDataReconstruction.C @@ -16,7 +16,7 @@ /* $Id: runReconstruction.C 23207 2007-12-20 09:59:20Z ivana $ */ /// \ingroup macros -/// \file runReconstruction.C +/// \file runDataReconstruction.C /// \brief Macro for running reconstruction /// /// Macro for running reconstruction on the cosmics run data. @@ -24,72 +24,50 @@ /// \author Laurent Aphecetche, Nicole Bastid, Bogdan Vulpescu, ... #if !defined(__CINT__) || defined(__MAKECINT__) -#include "AliMUONReconstructor.h" -#include "AliMUONRecoParam.h" -#include "AliRecoParam.h" #include "AliCDBManager.h" -#include "AliMagFMaps.h" -#include "AliTracker.h" #include "AliReconstruction.h" -#include #include -//#include +#include #endif -// Data file, OCDB on Grid -TString input="alien:///alice/data/2007/LHC07w/000014493/raw/07000014493001.10.root"; -TString ocdbPath = "alien://folder=/alice/data/2008/LHC08a/OCDB"; +void runDataReconstruction(const char* input = "raw://run124360", + const char* ocdbPath = "raw://", + const char* recoptions="SAVEDIGITS", + Int_t numberOfEvents=1000) +{ + AliCDBManager* man = AliCDBManager::Instance(); + man->SetDefaultStorage(ocdbPath); -// Data file, OCDB locally -//TString input="$ALICE_ROOT/MUON/test_out.100/raw.root"; -//TString ocdbPath = "local://$ALICE_ROOT"; + AliReconstruction rec; + + rec.SetRunReconstruction("MUON"); -TString caliboption1 = "NOGAIN"; -TString caliboption2 = "GAINCONSTANTCAPA"; -TString recoptions = "SAVEDIGITS"; -Int_t seed = 1234567; + rec.SetRunQA("MUON:ALL"); -void runDataReconstruction(Int_t calib = 1) -{ - TGrid::Connect("alien://"); + rec.SetQARefDefaultStorage("local://$ALICE_ROOT/QAref") ; - AliCDBManager* man = AliCDBManager::Instance(); - man->SetDefaultStorage(ocdbPath.Data()); - man->SetSpecificStorage("MUON/Calib/Mapping","local://$ALICE_ROOT"); - man->SetSpecificStorage("MUON/Calib/DDLStore","local://$ALICE_ROOT"); + rec.SetWriteESDfriend(kTRUE); + rec.SetWriteAlignmentData(); - gRandom->SetSeed(seed); - - AliMagFMaps* field = new AliMagFMaps("Maps","Maps", 1, 1., 10., AliMagFMaps::k5kG); - AliTracker::SetFieldMap(field, kFALSE); - AliReconstruction *MuonRec = new AliReconstruction(); - - - MuonRec->SetInput(input.Data()); - MuonRec->SetRunVertexFinder(kFALSE); - MuonRec->SetRunLocalReconstruction("MUON"); - MuonRec->SetRunTracking("MUON"); - MuonRec->SetFillESD(" "); - MuonRec->SetLoadAlignData("MUON"); - MuonRec->SetNumberOfEventsPerFile(1000); - MuonRec->SetOption("MUON",recoptions.Data()); - // MuonRec->SetEventRange(319,319); - MuonRec->SetWriteAOD(); - //MuonRec.SetEventRange(0,100); - AliMUONRecoParam *muonRecoParam = AliMUONRecoParam::GetLowFluxParam(); - muonRecoParam->CombineClusterTrackReco(kTRUE); - TString caliboption = caliboption1; - if ( calib == 2 ) caliboption = caliboption2; - muonRecoParam->SetCalibrationMode(caliboption.Data()); - //muonRecoParam->SetClusteringMode("PEAKFIT"); - //muonRecoParam->SetClusteringMode("PEAKCOG"); - muonRecoParam->Print("FULL"); - AliRecoParam::Instance()->RegisterRecoParam(muonRecoParam); - - MuonRec->Run(); - - delete MuonRec; + rec.SetInput(gSystem->ExpandPathName(input)); + + rec.SetUseTrackingErrorsForAlignment("ITS"); + + rec.SetCleanESD(kFALSE); + + rec.SetStopOnError(kFALSE); + + rec.SetOption("MUON",recoptions); + + rec.SetQAWriteExpert(AliQAv1::kMUON); + + if ( numberOfEvents > 0 ) + { + rec.SetEventRange(0,numberOfEvents); + } + + AliLog::Flush(); + rec.Run(); - //gObjectTable->Print(); }