AliHMPIDRecoParam is updated with RunTypes:
authordibari <dibari@f7af4fe6-9843-0410-8265-dc069ae4e863>
Wed, 16 Sep 2009 16:20:56 +0000 (16:20 +0000)
committerdibari <dibari@f7af4fe6-9843-0410-8265-dc069ae4e863>
Wed, 16 Sep 2009 16:20:56 +0000 (16:20 +0000)
LowFlux, HighFlux, Cosmics (calibration is not needed)
and macro to create HMPID recoparams is added.
AliHMPIDTracker and Recon are updated to use the new recoparams.
Relative items in Planning will be closed

HMPID/MakeHMPIDRecoParam.C [new file with mode: 0644]

diff --git a/HMPID/MakeHMPIDRecoParam.C b/HMPID/MakeHMPIDRecoParam.C
new file mode 100644 (file)
index 0000000..f4a8b57
--- /dev/null
@@ -0,0 +1,59 @@
+void MakeHMPIDRecoParam(AliRecoParam::EventSpecie_t default=AliRecoParam::kLowMult)
+{
+  //
+  // Create HMPID Reco Parameters in OCDB
+  //  
+  AliCDBManager* man = AliCDBManager::Instance();
+  if(!man->IsDefaultStorageSet()) man->SetDefaultStorage("local://$ALICE_ROOT/OCDB");
+  
+  TObjArray *recoParamArray = new TObjArray();
+  
+  {
+         AliHMPIDRecoParam* hmpRecoParam = AliHMPIDRecoParam::GetLowFluxParam();
+         hmpRecoParam->SetEventSpecie(AliRecoParam::kLowMult);
+          hmpRecoParam->SetAsDefault();
+         recoParamArray->AddLast(hmpRecoParam);
+          hmpRecoParam->PrintParameters();
+  }
+  {
+         AliHMPIDRecoParam* hmpRecoParam = AliHMPIDRecoParam::GetHighFluxParam();
+         hmpRecoParam->SetEventSpecie(AliRecoParam::kHighMult);
+         recoParamArray->AddLast(hmpRecoParam);
+          hmpRecoParam->PrintParameters();
+
+  }
+  {
+         AliHMPIDRecoParam* hmpRecoParam = AliHMPIDRecoParam::GetCosmicParam();
+         hmpRecoParam->SetEventSpecie(AliRecoParam::kCosmic);
+         recoParamArray->AddLast(hmpRecoParam);
+          hmpRecoParam->PrintParameters();
+  }
+  
+  // Set the default
+  Bool_t defaultIsSet = kFALSE;
+  for(Int_t i =0; i < recoParamArray->GetEntriesFast(); i++) {
+    AliDetectorRecoParam *param = (AliDetectorRecoParam *)recoParamArray->UncheckedAt(i);
+    if (!param) continue;
+    if (default & param->GetEventSpecie()) {
+      param->SetAsDefault();
+      defaultIsSet = kTRUE;
+    }
+  }
+  if (!defaultIsSet) {
+    Error("The default reconstruction parameters are not set! Exiting...");
+    return;
+  }
+  
+  
+  
+  AliCDBMetaData *md= new AliCDBMetaData();
+  md->SetResponsible("Domenico DiBari");
+  md->SetComment("Reconstruction parameters of HMPID");
+  md->SetAliRootVersion(gSystem->Getenv("ARVERSION"));
+  md->SetBeamPeriod(0);
+  AliCDBId id("HMPID/Calib/RecoParam",0,AliCDBRunRange::Infinity());
+  man->GetDefaultStorage()->Put(recoParamArray,id, md);
+  
+  return;
+}