Recontruction parameters class with a different name (AliHMPIDRecoParamV1), to allow...
authorgvolpe <gvolpe@f7af4fe6-9843-0410-8265-dc069ae4e863>
Sun, 29 Nov 2009 17:14:27 +0000 (17:14 +0000)
committergvolpe <gvolpe@f7af4fe6-9843-0410-8265-dc069ae4e863>
Sun, 29 Nov 2009 17:14:27 +0000 (17:14 +0000)
HMPID/AliHMPIDRecoParamV1.cxx [new file with mode: 0644]
HMPID/AliHMPIDRecoParamV1.h [new file with mode: 0644]
HMPID/AliHMPIDReconstructor.cxx
HMPID/AliHMPIDReconstructor.h
HMPID/AliHMPIDTracker.cxx
HMPID/AliHMPIDTracker.h
HMPID/HMPIDrecLinkDef.h
HMPID/Hconfig.C
HMPID/MakeHMPIDRecoParam.C
HMPID/MakeHMPIDRecoParamV1.C [new file with mode: 0644]
HMPID/libHMPIDrec.pkg

diff --git a/HMPID/AliHMPIDRecoParamV1.cxx b/HMPID/AliHMPIDRecoParamV1.cxx
new file mode 100644 (file)
index 0000000..51e4061
--- /dev/null
@@ -0,0 +1,160 @@
+/**************************************************************************
+ * Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
+ *                                                                        *
+ * Author: The ALICE Off-line Project.                                    *
+ * Contributors are mentioned in the code where appropriate.              *
+ *                                                                        *
+ * Permission to use, copy, modify and distribute this software and its   *
+ * documentation strictly for non-commercial purposes is hereby granted   *
+ * without fee, provided that the above copyright notice appears in all   *
+ * copies and that both the copyright notice and this permission notice   *
+ * appear in the supporting documentation. The authors make no claims     *
+ * about the suitability of this software for any purpose. It is          *
+ * provided "as is" without express or implied warranty.                  *
+ **************************************************************************/
+
+
+///////////////////////////////////////////////////////////////////////////////
+//                                                                           //
+// Class to set HMPID reconstruction parameters (normal, HTA, UserCut ...    //
+//                                                                           //  
+//                                                                           //
+///////////////////////////////////////////////////////////////////////////////
+//
+//Email: domenico.dibari@ba.infn.it
+//
+#include "AliLog.h"
+#include "AliHMPIDRecoParamV1.h"
+#include "AliHMPIDParam.h"
+
+ClassImp(AliHMPIDRecoParamV1)
+
+//_____________________________________________________________________________
+AliHMPIDRecoParamV1::AliHMPIDRecoParamV1():AliDetectorRecoParam(),   
+  fHmpRecoMode(kTRUE),fHmpFixedDistCut(kTRUE),
+  fHmpTrackMatchingDist(1.0)
+{
+  //
+  // ctor
+  //
+  for(Int_t iCh=AliHMPIDParam::kMinCh;iCh<=AliHMPIDParam::kMaxCh;iCh++) fHmpUserCut[iCh]=3;
+  for(Int_t iPol=0;iPol<5;iPol++) fHmpTrackMatchingDistParas[iPol]=0;
+}
+//++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+AliHMPIDRecoParamV1::AliHMPIDRecoParamV1(const AliHMPIDRecoParamV1 &p):AliDetectorRecoParam(p),   
+    fHmpRecoMode(kTRUE),fHmpFixedDistCut(kTRUE),
+    fHmpTrackMatchingDist(1.0)
+{ 
+   //copy Ctor
+
+   fHmpRecoMode= p.fHmpRecoMode;
+   fHmpFixedDistCut=p.fHmpFixedDistCut;
+   for(Int_t iCh=AliHMPIDParam::kMinCh;iCh<=AliHMPIDParam::kMaxCh;iCh++) fHmpUserCut[iCh]=p.fHmpUserCut[iCh];
+   fHmpTrackMatchingDist=p.fHmpTrackMatchingDist;
+   for(Int_t iPol=0;iPol<5;iPol++) fHmpTrackMatchingDistParas[iPol]=p.fHmpTrackMatchingDistParas[iPol];
+}
+
+//++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+AliHMPIDRecoParamV1& AliHMPIDRecoParamV1::operator=(const AliHMPIDRecoParamV1 &p)
+{
+//
+// assign. operator
+//
+  AliDetectorRecoParam::operator=(p);
+  this->fHmpRecoMode= p.fHmpRecoMode;
+  this->fHmpFixedDistCut=p.fHmpFixedDistCut;
+  for(Int_t iCh=AliHMPIDParam::kMinCh;iCh<=AliHMPIDParam::kMaxCh;iCh++) this->fHmpUserCut[iCh] = p.fHmpUserCut[iCh];   
+  this->fHmpTrackMatchingDist=p.fHmpTrackMatchingDist;
+  for(Int_t iPol=0;iPol<5;iPol++) this->fHmpTrackMatchingDistParas[iPol]=p.fHmpTrackMatchingDistParas[iPol];
+  return *this;
+}
+//++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+AliHMPIDRecoParamV1::~AliHMPIDRecoParamV1() 
+{
+  //
+  // dtor
+  //  
+}
+//++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+AliHMPIDRecoParamV1 *AliHMPIDRecoParamV1::GetLowFluxParam(){
+  //
+  // Set HMPID Reco Params for Low Flux environment
+  //
+  AliHMPIDRecoParamV1 *hmpParam = new AliHMPIDRecoParamV1;
+  hmpParam->fHmpRecoMode = kTRUE;                                                     //kTRUE = normal reco. kFLASE = HTA
+  hmpParam->fHmpUserCut[0] = 3;                                                       //HMPID Module 0 User DAQ Sigma cut
+  hmpParam->fHmpUserCut[1] = 3;                                                       //HMPID Module 1 User DAQ Sigma cut
+  hmpParam->fHmpUserCut[2] = 3;                                                       //HMPID Module 2 User DAQ Sigma cut
+  hmpParam->fHmpUserCut[3] = 3;                                                       //HMPID Module 3 User DAQ Sigma cut
+  hmpParam->fHmpUserCut[4] = 3;                                                       //HMPID Module 4 User DAQ Sigma cut
+  hmpParam->fHmpUserCut[5] = 3;                                                       //HMPID Module 5 User DAQ Sigma cut
+  hmpParam->fHmpUserCut[6] = 3;                                                       //HMPID Module 6 User DAQ Sigma cut
+  hmpParam->fHmpFixedDistCut=kTRUE;                                                   //HMPID fixed (kTRUE) or parameterized distance cut (kFALSE)
+  hmpParam->fHmpTrackMatchingDist = 3.0;                                              //HMPID Track Matching distance cut
+  for(Int_t iPol=0;iPol<5;iPol++) hmpParam->fHmpTrackMatchingDistParas[iPol]=1;       //Prevision for momentum dependen track matching
+  hmpParam->SetName("HMP Low Flux");
+  hmpParam->SetTitle("HMP Low Flux");
+  return hmpParam;
+    
+}
+//++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+AliHMPIDRecoParamV1 *AliHMPIDRecoParamV1::GetHighFluxParam(){
+  //
+  // Set HMPID Reco Params for Low Flux environment
+  //
+  AliHMPIDRecoParamV1 *hmpParam = new AliHMPIDRecoParamV1;
+  hmpParam->fHmpRecoMode = kTRUE;                                                       //kTRUE = normal reco. kFLASE = HTA
+  hmpParam->fHmpUserCut[0] = 3;                                                         //HMPID Module 0 User DAQ Sigma cut
+  hmpParam->fHmpUserCut[1] = 3;                                                         //HMPID Module 1 User DAQ Sigma cut
+  hmpParam->fHmpUserCut[2] = 3;                                                         //HMPID Module 2 User DAQ Sigma cut
+  hmpParam->fHmpUserCut[3] = 3;                                                         //HMPID Module 3 User DAQ Sigma cut
+  hmpParam->fHmpUserCut[4] = 3;                                                         //HMPID Module 4 User DAQ Sigma cut
+  hmpParam->fHmpUserCut[5] = 3;                                                         //HMPID Module 5 User DAQ Sigma cut
+  hmpParam->fHmpUserCut[6] = 3;                                                         //HMPID Module 6 User DAQ Sigma cut
+  hmpParam->fHmpFixedDistCut=kTRUE;                                                     //HMPID fixed (kTRUE) or parameterized distance cut (kFALSE)
+  hmpParam->fHmpTrackMatchingDist = 1.0;                                                //HMPID Track Matching distance cut
+  for(Int_t iPol=0;iPol<5;iPol++) hmpParam->fHmpTrackMatchingDistParas[iPol]=1;         //Prevision for momentum dependen track matching
+  hmpParam->SetName("HMP High Flux");
+  hmpParam->SetTitle("HMP High Flux");
+  return hmpParam;
+    
+}
+//++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+AliHMPIDRecoParamV1 *AliHMPIDRecoParamV1::GetCosmicParam(){
+  //
+  // Set HMPID Reco Params for Low Flux environment
+  //
+  AliHMPIDRecoParamV1 *hmpParam = new AliHMPIDRecoParamV1;
+  hmpParam->fHmpRecoMode = kTRUE;                                                                   //kTRUE = normal reco. kFLASE = HTA
+  hmpParam->fHmpUserCut[0] = 3;                                                                     //HMPID Module 0 User DAQ Sigma cut
+  hmpParam->fHmpUserCut[1] = 3;                                                                     //HMPID Module 1 User DAQ Sigma cut
+  hmpParam->fHmpUserCut[2] = 3;                                                                     //HMPID Module 2 User DAQ Sigma cut
+  hmpParam->fHmpUserCut[3] = 3;                                                                     //HMPID Module 3 User DAQ Sigma cut
+  hmpParam->fHmpUserCut[4] = 3;                                                                     //HMPID Module 4 User DAQ Sigma cut
+  hmpParam->fHmpUserCut[5] = 3;                                                                     //HMPID Module 5 User DAQ Sigma cut
+  hmpParam->fHmpUserCut[6] = 3;                                                                     //HMPID Module 6 User DAQ Sigma cut
+  hmpParam->fHmpFixedDistCut=kTRUE;                                                                 //HMPID fixed (kTRUE) or parameterized distance cut (kFALSE)
+  hmpParam->fHmpTrackMatchingDist = 4.0;                                                            //HMPID Track Matching distance cut
+  for(Int_t iPol=0;iPol<5;iPol++) hmpParam->fHmpTrackMatchingDistParas[iPol]=1;                     //Prevision for momentum dependen track matching
+  hmpParam->SetName("HMP Cosmic ");
+  hmpParam->SetTitle("HMP Cosmic");
+  return hmpParam;
+    
+}
+//++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+void AliHMPIDRecoParamV1::PrintParameters() const
+{
+  //
+  // Printing of the used HMPID reconstruction parameters
+  //
+   AliInfo(Form("%s",AliHMPIDRecoParamV1::GetName()));
+   AliInfo(Form("IsDefault: %d",AliHMPIDRecoParamV1::IsDefault()));
+   AliInfo(Form(" Running HMPID Reco: %d (1=Standard, 0=HTA)",fHmpRecoMode));
+   AliInfo(Form(" Is track matching distance fixed (1) or momentum dependent (0): %d",fHmpFixedDistCut));
+   AliInfo(Form(" HMPID track matching distance cut: %.3lf",fHmpTrackMatchingDist));
+   for(Int_t iCh=AliHMPIDParam::kMinCh;iCh<=AliHMPIDParam::kMaxCh;iCh++)
+    AliInfo(Form(" HMPID Chamber: %d User DAQ Sigma cut: %d",iCh,fHmpUserCut[iCh]));
+   for(Int_t iPol=0;iPol<5;iPol++) 
+     AliInfo(Form(" HMPID momentum dependent distnce parameters: param[%d]=%lf",iPol,fHmpTrackMatchingDistParas[iPol]));
+  
+}
diff --git a/HMPID/AliHMPIDRecoParamV1.h b/HMPID/AliHMPIDRecoParamV1.h
new file mode 100644 (file)
index 0000000..13cd723
--- /dev/null
@@ -0,0 +1,58 @@
+#ifndef ALIHMPIDRECOPARAMV1_H
+#define ALIHMPIDRECOPARAMV1_H
+/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
+ * See cxx source for full Copyright notice                               */
+
+///////////////////////////////////////////////////////////////////////////////
+//                                                                           //
+// Class to set HMPID reconstruction parameters (normal, HTA, UserCut ...    //
+//                                                                           //
+// This class is introduced as a copy of teh AliHMPIDRecoParam to solve      //
+// the problem occured in v4-17-Rev-18                                       //
+//                                                                           //
+//                                                                           //
+///////////////////////////////////////////////////////////////////////////////
+
+#include "AliDetectorRecoParam.h"
+
+class AliHMPIDRecoParamV1 : public AliDetectorRecoParam
+{
+ public: 
+  
+  AliHMPIDRecoParamV1();                                                                                           //ctor
+  AliHMPIDRecoParamV1(const AliHMPIDRecoParamV1 &p);                                                               //copy ctor 
+  AliHMPIDRecoParamV1& operator=(const AliHMPIDRecoParamV1 &p);                                                    // ass. op.
+  virtual ~AliHMPIDRecoParamV1();                                                                                  //dtor
+
+  
+  static AliHMPIDRecoParamV1 *GetLowFluxParam();                                                                   // reco params for low flux env.
+  static AliHMPIDRecoParamV1 *GetHighFluxParam();                                                                  // reco params for high flux env. 
+  static AliHMPIDRecoParamV1 *GetCosmicParam();                                                                    // reco params for cosmic  
+    
+  Bool_t   GetHmpRecoMode(            )        const            { return fHmpRecoMode;          }                  //kTRUE = normal tracking reco, kFALSE = HTA     
+  void     SetHmpRecoMode(Bool_t recoMode)                       { fHmpRecoMode=recoMode;        }                 //kTRUE = normal tracking reco, kFALSE = HTA   
+  Int_t    GetHmpUserCut(Int_t iCh)            const             { return fHmpUserCut[iCh];      }                 //user cut for the 7 chambers
+  void     SetHmpUserCut(Int_t iChamb,Int_t ucCh)     { fHmpUserCut[iChamb]=ucCh; Printf("fUserCut[%d]=%d",iChamb,ucCh);    }       //set user cut (DAQ Sigma) for a given chamber
+  Bool_t   IsFixedDistCut()                    const             { return fHmpFixedDistCut;      }                  //if kTRUE the track matching  distance is a fix number, if kFALSE the distance depends on momentum
+  void     SetIsFixedDistCut(Bool_t isFix)                       { fHmpFixedDistCut=isFix;       }                  //Change from fix distance cut to parameterized
+  Double_t GetHmpTrackMatchingDist()           const             { return fHmpTrackMatchingDist; }                  //Get distance between the MIP cluster
+  void     SetHmpTrackMatchingDist(Double_t dist)                { fHmpTrackMatchingDist=dist;   }                  //Set distance between the MIP cluster
+  Double_t GetHmpTrackMatchingDistParam(Int_t par) const         {return fHmpTrackMatchingDistParas[par];}          //Prevision to get  momentum dependen track matching parameters
+  void     SetHmpTrackMatchingDistParam(Int_t par, Double_t val) {fHmpTrackMatchingDistParas[par]=val;}             //Prevision to set  momentum dependen track matching parameters
+
+  virtual void PrintParameters() const;
+  
+  protected:
+   
+  Bool_t   fHmpRecoMode;                                    //kTRUE = normal tracking reco, kFALSE = HTA
+  Int_t    fHmpUserCut[7];                                  //user cut for the 7 chambers
+  Bool_t   fHmpFixedDistCut;                                //if kTRUE the track matching  distance is a fix number, if kFALSE the distance depends on momentum
+  Double_t fHmpTrackMatchingDist;                           //distance between the MIP cluster
+  Double_t fHmpTrackMatchingDistParas[5];                   //Prevision for momentum dependen track matching
+  
+
+  ClassDef(AliHMPIDRecoParamV1, 0) 
+};
+#endif
+
index b5262d9..3af7d04 100644 (file)
 #include <AliRawReader.h>          //Reconstruct() for raw digits
 #include <AliLog.h>                //
 #include "AliHMPIDRawStream.h"     //ConvertDigits()
-#include "AliHMPIDRecoParam.h"     //ctor
+#include "AliHMPIDRecoParamV1.h"   //ctor
 
 ClassImp(AliHMPIDReconstructor)
 
-//AliHMPIDRecoParam* AliHMPIDReconstructor::fgkRecoParam =0;  // 
 //++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 AliHMPIDReconstructor::AliHMPIDReconstructor():AliReconstructor(),fUserCut(0),fDaqSig(0),fDig(0),fClu(0)
 {
@@ -56,14 +55,14 @@ AliHMPIDReconstructor::AliHMPIDReconstructor():AliReconstructor(),fUserCut(0),fD
    if(AliHMPIDReconstructor::GetRecoParam()) {
     for(Int_t iCh=AliHMPIDParam::kMinCh;iCh<=AliHMPIDParam::kMaxCh;iCh++) {
       fUserCut[iCh] = AliHMPIDReconstructor::GetRecoParam()->GetHmpUserCut(iCh);
-      AliDebug(1,Form("UserCut successfully loaded (from RecoParam) for chamber %i -> %i ",iCh,fUserCut[iCh]));
+      AliDebug(1,Form("UserCut successfully loaded (from AliHMPIDRecoParamV1) for chamber %i -> %i ",iCh,fUserCut[iCh]));
     }
   }
   else {
     for(Int_t iCh=AliHMPIDParam::kMinCh;iCh<=AliHMPIDParam::kMaxCh;iCh++) {
       fUserCut[iCh] = 3;                                                                             // minimal requirement for sigma cut
       AliDebug(1,Form("UserCut loaded from defaults for chamber %i -> %i ",iCh,fUserCut[iCh]));
-      AliDebug(1,Form("Cannot get AliHMPIDRecoParam!"));
+      AliDebug(1,Form("Cannot get AliHMPIDRecoParamV1!"));
       }
     }
 
index 29351e9..96a368e 100644 (file)
@@ -8,7 +8,7 @@
 #include <AliReconstructor.h>        //base class
 #include "AliHMPIDTracker.h"         //CreateTracker()
 #include "AliHMPIDDigit.h"           //Dig2Clu(), UseDig()
-#include "AliHMPIDRecoParam.h"
+#include "AliHMPIDRecoParamV1.h"
 #include <TMatrixF.h>                //UseDig()
 #include <TClonesArray.h>            //UseDig()
 #include <TObjArray.h>               //SigConv()
@@ -36,7 +36,7 @@ public:
   static        void           FormClu (AliHMPIDCluster *pClu,AliHMPIDDigit *pDig,TClonesArray *pDigLst,TMatrixF *pPadMap);//cluster formation recursive algorithm
   static inline AliHMPIDDigit* UseDig  (Int_t padX,Int_t padY,                    TClonesArray *pDigLst,TMatrixF *pDigMap);//use this pad's digit to form a cluster
   inline Bool_t                IsDigSurvive(AliHMPIDDigit *pDig                                                     )const;//check for sigma cut
-  static const AliHMPIDRecoParam* GetRecoParam() { return dynamic_cast<const AliHMPIDRecoParam*>(AliReconstructor::GetRecoParam(5)); }  //5 is the HMPID detector code
+  static const AliHMPIDRecoParamV1* GetRecoParam() { return dynamic_cast<const AliHMPIDRecoParamV1*>(AliReconstructor::GetRecoParam(5)); }  //5 is the HMPID detector code
  
   protected:
   Int_t     *fUserCut;                 // n sigmas for pedestals decided by the User for each chamber(if in OCDB)
index a2897b0..c72f071 100644 (file)
@@ -4,7 +4,7 @@
 #include "AliHMPIDParam.h"       //GetTrackPoint(),PropagateBack()
 #include "AliHMPIDPid.h"         //Recon(),reconHTA()
 #include "AliHMPIDRecon.h"       //Recon()
-#include "AliHMPIDRecoParam.h"   //Recon()
+#include "AliHMPIDRecoParamV1.h"   //Recon()
 #include "AliHMPIDReconstructor.h"//Recon()
 #include "AliHMPIDReconHTA.h"    //ReconHTA()
 #include <AliESDEvent.h>         //PropagateBack(),Recon()  
@@ -15,7 +15,6 @@
 #include <AliAlignObj.h>         //GetTrackPoint()
 #include <AliCDBManager.h>       //PropageteBack()
 #include <AliCDBEntry.h>         //PropageteBack()
-#include "AliHMPIDRecoParam.h"   //Recon()
 //.
 // HMPID base class fo tracking
 //.
@@ -214,7 +213,6 @@ Int_t AliHMPIDTracker::Recon(AliESDEvent *pEsd,TObjArray *pClus,TObjArray *pNmea
 
     if(AliHMPIDReconstructor::GetRecoParam())                                                 //retrieve distance cut
     {
-      AliHMPIDReconstructor::GetRecoParam()->PrintParameters();
       if(AliHMPIDReconstructor::GetRecoParam()->IsFixedDistCut()==kTRUE)                      //distance cut is fixed number
       { 
         distCut=AliHMPIDReconstructor::GetRecoParam()->GetHmpTrackMatchingDist();
index 5132a93..46a2a12 100644 (file)
@@ -13,7 +13,7 @@
 class AliESDEvent;      //Recon()     
 class AliESDtrack;      //IntTrkCha()
 class AliHMPIDtrack;
-class AliHMPIDRecoParam;
+class AliHMPIDRecoParamV1;
 
 class AliHMPIDTracker : public AliTracker
 {
index c2e3683..1dd794a 100644 (file)
@@ -9,6 +9,7 @@
 #pragma link C++ class  AliHMPIDRecon+;
 #pragma link C++ class  AliHMPIDPid+;
 #pragma link C++ class  AliHMPIDRecoParam+;
+#pragma link C++ class  AliHMPIDRecoParamV1+;
 #pragma link C++ class  AliHMPIDReconHTA+;
 #pragma link C++ class  AliHMPIDQADataMakerRec+;
 
index 9249879..f90cb42 100644 (file)
@@ -529,7 +529,7 @@ void HmpConfig::GuiBatch(TGHorizontalFrame *pMainF)
     new TGRadioButton(fCluBG,  "Clusters CORE"   ,kAll    );  
     new TGRadioButton(fCluBG,  "Clusters HMPID"  ,kHmp    );   
 
-    new TGCheckButton(fTrkBG,  "Apply RecoParam" ,kRecoPar);  
+    new TGCheckButton(fTrkBG,  "Apply RecoParamV1" ,kRecoPar);  
 
     new TGCheckButton(fTrkBG,  "Load Align data" ,kAln    );  
     new TGCheckButton(fTrkBG,  "Prim vertex"     ,kVtx    );  
@@ -691,7 +691,7 @@ void HmpConfig::WriteBatch()
     //---------------------------------------------
     if     (fTrkBG->GetButton(kRecoPar)->GetState())
       { 
-         fprintf(fp,"  AliHMPIDRecoParam *hmpidRecoParam=AliHMPIDReconstructor::GetRecoParam();    //Get the HMPID reco param\n"); 
+         fprintf(fp,"  AliHMPIDRecoParamV1 *hmpidRecoParam=AliHMPIDReconstructor::GetRecoParam();    //Get the HMPID reco param\n"); 
          fprintf(fp,"  hmpidRecoParam->SetHmpUserCut(0,4);                                            //eg cut for UserCutSigma (Values: ch0)\n");
          fprintf(fp,"  hmpidRecoParam->SetHmpUserCut(1,4);                                            //eg cut for UserCutSigma (Values: ch1)\n");
          fprintf(fp,"  hmpidRecoParam->SetHmpUserCut(2,4);                                            //eg cut for UserCutSigma (Values: ch2)\n");
index f4a8b57..b75fa35 100644 (file)
@@ -6,54 +6,17 @@ void MakeHMPIDRecoParam(AliRecoParam::EventSpecie_t default=AliRecoParam::kLowMu
   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;
-  }
-  
-  
+  TObject *recoParamArray = new TObject();
   
   AliCDBMetaData *md= new AliCDBMetaData();
   md->SetResponsible("Domenico DiBari");
-  md->SetComment("Reconstruction parameters of HMPID");
+  md->SetComment("Reconstruction parameters of HMPID, v1");
   md->SetAliRootVersion(gSystem->Getenv("ARVERSION"));
   md->SetBeamPeriod(0);
   AliCDBId id("HMPID/Calib/RecoParam",0,AliCDBRunRange::Infinity());
   man->GetDefaultStorage()->Put(recoParamArray,id, md);
   
+  
+  
   return;
 }
diff --git a/HMPID/MakeHMPIDRecoParamV1.C b/HMPID/MakeHMPIDRecoParamV1.C
new file mode 100644 (file)
index 0000000..45c3b45
--- /dev/null
@@ -0,0 +1,57 @@
+void MakeHMPIDRecoParamV1(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();
+  
+  {
+         AliHMPIDRecoParamV1* hmpRecoParam = AliHMPIDRecoParamV1::GetLowFluxParam();
+         hmpRecoParam->SetEventSpecie(AliRecoParam::kLowMult);
+          hmpRecoParam->SetAsDefault();
+         recoParamArray->AddLast(hmpRecoParam);
+          hmpRecoParam->PrintParameters();
+  }
+  {
+         AliHMPIDRecoParamV1* hmpRecoParam = AliHMPIDRecoParamV1::GetHighFluxParam();
+         hmpRecoParam->SetEventSpecie(AliRecoParam::kHighMult);
+         recoParamArray->AddLast(hmpRecoParam);
+          hmpRecoParam->PrintParameters();
+
+  }
+  {
+         AliHMPIDRecoParamV1* hmpRecoParam = AliHMPIDRecoParamV1::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, v1");
+  md->SetAliRootVersion(gSystem->Getenv("ARVERSION"));
+  md->SetBeamPeriod(0);
+  AliCDBId id("HMPID/Calib/RecoParam",0,AliCDBRunRange::Infinity());
+  man->GetDefaultStorage()->Put(recoParamArray,id, md);
+  
+  return;
+}
index 93fda77..607f236 100644 (file)
@@ -1,6 +1,6 @@
 #-*- Mode: Makefile -*-
 SRCS:=  AliHMPIDReconstructor.cxx AliHMPIDtrack.cxx AliHMPIDTracker.cxx \
-        AliHMPIDRecon.cxx AliHMPIDRecoParam.cxx       \
+        AliHMPIDRecon.cxx AliHMPIDRecoParam.cxx   AliHMPIDRecoParamV1.cxx       \
         AliHMPIDReconHTA.cxx AliHMPIDPid.cxx \
                AliHMPIDQADataMakerRec.cxx