fix AliHLTGlobalEsdConverterComponent
[u/mrichter/AliRoot.git] / VZERO / MakeVZERORecoParam.C
CommitLineData
ed90abb8 1void MakeVZERORecoParam(AliRecoParam::EventSpecie_t default=AliRecoParam::kLowMult) {
2//========================================================================
3//
4// Steering macro for VZERO reconstruction parameters
5//
6// Author: Brigitte Cheynis
7//
8//========================================================================
9
10 const char* macroname = "MakeVZERORecoParam.C";
11
12 // Activate CDB storage and load geometry from CDB
13 AliCDBManager* cdb = AliCDBManager::Instance();
14 if(!cdb->IsDefaultStorageSet()) cdb->SetDefaultStorage("local://OCDB");
15
16 TObjArray *recoParamArray = new TObjArray();
17
18 {
19 AliVZERORecoParam * vzeroRecoParam = new AliVZERORecoParam;
20 vzeroRecoParam->SetEventSpecie(AliRecoParam::kCosmic);
21 recoParamArray->AddLast(vzeroRecoParam);
22 }
23 {
24 AliVZERORecoParam * vzeroRecoParam = new AliVZERORecoParam;
c73e8189 25 // the following two settings are needed to high lumi runs in 2011
26 vzeroRecoParam->SetStartClock(9);
27 vzeroRecoParam->SetEndClock(11);
ddbd5d79 28 vzeroRecoParam->SetNPreClocks(1);
29 vzeroRecoParam->SetNPostClocks(1);
ed90abb8 30 vzeroRecoParam->SetEventSpecie(AliRecoParam::kLowMult);
31 recoParamArray->AddLast(vzeroRecoParam);
32 }
33 {
34 AliVZERORecoParam * vzeroRecoParam = new AliVZERORecoParam;
f65d440b 35 vzeroRecoParam->SetStartClock(9);
36 vzeroRecoParam->SetEndClock(11);
53ad561b 37 vzeroRecoParam->SetNPreClocks(6);
ed90abb8 38 vzeroRecoParam->SetEventSpecie(AliRecoParam::kHighMult);
39 recoParamArray->AddLast(vzeroRecoParam);
40 }
41
42 // Set the default
43 Bool_t defaultIsSet = kFALSE;
44 for(Int_t i =0; i < recoParamArray->GetEntriesFast(); i++) {
45 AliDetectorRecoParam *param = (AliDetectorRecoParam *)recoParamArray->UncheckedAt(i);
46 if (!param) continue;
47 if (default & param->GetEventSpecie()) {
48 param->SetAsDefault();
49 defaultIsSet = kTRUE;
50 }
51 }
52
53 if (!defaultIsSet) {
54 Error(macroname,"The default reconstruction parameters are not set! Exiting...");
55 return;
56 }
57
58 // save in CDB storage
59 AliCDBMetaData *md= new AliCDBMetaData();
60 md->SetResponsible("Brigitte Cheynis");
61 md->SetComment("Reconstruction parameters for VZERO");
62 md->SetAliRootVersion(gSystem->Getenv("ARVERSION"));
63 md->SetBeamPeriod(0);
64 AliCDBId id("VZERO/Calib/RecoParam",0,AliCDBRunRange::Infinity());
65 cdb->GetDefaultStorage()->Put(recoParamArray,id, md);
66
67 return;
68}