]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - PMD/AliPMDClusterFinder.h
Gsatt replaces
[u/mrichter/AliRoot.git] / PMD / AliPMDClusterFinder.h
index d7eb4c61c32d2de7a24696fc321d6d2fe16c5061..5c8b04ba1f5a71448b8a97cf873feb62238ed85c 100644 (file)
@@ -1,5 +1,7 @@
-#ifndef PMDClusterFinder_H
-#define PMDClusterFinder_H
+#ifndef ALIPMDCLUSTERFINDER_H
+#define ALIPMDCLUSTERFINDER_H
+/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
+ * See cxx source for full Copyright notice                               */
 //-----------------------------------------------------//
 //                                                     //
 //  Date   : August 05 2003                            //
 //                                                     //
 //-----------------------------------------------------//
 
-#include <Riostream.h>
-#include <stdlib.h>
-#include <math.h>
-#include <TMath.h>
-#include <vector>
-#include <algorithm>
-
 class TClonesArray;
 class TFile;
-class TObjArray;
 class TTree;
-class TNtuple;
 
 class AliLoader;
 class AliRunLoader;
-class AliRun;
-class AliDetector;
-class AliHeader;
+class AliRawReader;
+class AliPMDCalibData;
+class AliPMDPedestal;
+class AliPMDHotData;
+class AliPMDNoiseCut;
+class AliPMDddlinfoData;
+class AliPMDRecoParam;
+
+class AliPMDClusterFinder : public TObject
+{
+
+ public:
 
-class AliPMDdigit;
-class AliPMDClustering;
-class AliPMDContainer;
-class AliPMDcluster;
-class AliPMDrecpoint;
+  AliPMDClusterFinder();
+  AliPMDClusterFinder(AliRunLoader* runLoader);
+  AliPMDClusterFinder(const AliPMDClusterFinder &finder);  // copy constructor
+  AliPMDClusterFinder &operator=(const AliPMDClusterFinder &finder); // assignment op
+  virtual ~AliPMDClusterFinder();
 
-using namespace std;
+  void Digits2RecPoints(TTree *digitsTree, TTree *clustersTree,Int_t gRecoMode);
+  void Digits2RecPoints(AliRawReader *rawReader, TTree *clustersTree,Int_t gRecoMode);
 
-class AliPMDClusterFinder
-{
- protected:
-  AliRunLoader *fRunLoader;
-  AliRun       *gAlice;
-  AliDetector  *PMD;      /* Get pointers to Alice detectors 
-                            and Hits containers */
-  AliLoader    *pmdloader;
+  void AddRecPoint(Int_t idet, Int_t ismn, Float_t * clusdata);
+  void AddRecHit(Int_t celldataX, Int_t celldataY, Int_t celldataTr,
+                Int_t celldataPid, Float_t celldataAdc);
+  void ResetCellADC();
+  void ResetRecpoint();
+  void ResetRechit();
+  void Load();
+  void LoadClusters();
+  void UnLoad();
+  void UnLoadClusters();
+
+  AliPMDCalibData    *GetCalibGain() const;
+  AliPMDPedestal     *GetCalibPed() const;
+  AliPMDHotData      *GetCalibHot() const;
+  AliPMDNoiseCut     *GetNoiseCut() const;
+  AliPMDddlinfoData  *GetDdlinfoData() const;
 
-  TTree        *treeD;
-  TTree        *treeR;
+ protected:
+  AliRunLoader *fRunLoader; // Pointer to Run Loader
+  AliLoader    *fPMDLoader; // Pointer to specific detector loader
 
-  TClonesArray *fDigits;
-  TClonesArray *fRecpoints;
+  AliPMDCalibData    *fCalibGain;  //! Gain calibration data
+  AliPMDPedestal     *fCalibPed;   //! Pedestal calibration data
+  AliPMDHotData      *fCalibHot;   //! Hot data
+  AliPMDNoiseCut     *fNoiseCut;   //! Noise cut
+  AliPMDddlinfoData  *fDdlinfo;    //! ddl info data
 
-  Int_t fNpoint;
-  Int_t fDetNo;
+  const AliPMDRecoParam *fRecoParam; // reconstruction parameter
 
-  static const Int_t fTotSM = 27;
-  static const Int_t fNCell = 72;
-  Float_t fCPV[fTotSM][fNCell][fNCell];
-  Float_t fPMD[fTotSM][fNCell][fNCell];
+  TTree        *fTreeD;     // Digits tree
+  TTree        *fTreeR;     // Reconstructed points
 
- public:
+  TClonesArray *fDigits;    // List of digits
+  TClonesArray *fRecpoints; // List of reconstructed points
+  TClonesArray *fRechits;   // List of cells associated with rec points
 
-  AliPMDClusterFinder();
-  virtual ~AliPMDClusterFinder();
+  Int_t   fNpoint;          // 
+  Int_t   fNhit;            // 
+  Int_t   fDetNo;           // Detector Number (0:PRE, 1:CPV)
 
-  void OpengAliceFile(char * /* galice.root */, Option_t * /* option */);
 
-  void Digits2RecPoints(Int_t /* ievt */);
-  void AddRecPoint(Float_t * /* clusdata */);
-  void ResetCellADC();
-  void ResetRecpoint();
-  void UnLoad(Option_t * /* option */);
+  static const Int_t fgkRow = 48; // Total number of rows in one unitmodule
+  static const Int_t fgkCol = 96; // Total number of cols in one unitmodule
+  Double_t fCellADC[fgkRow][fgkCol]; // Array containing individual cell ADC
+  Int_t    fCellTrack[fgkRow][fgkCol]; // Array containing individual cell tr
+  Int_t    fCellPid[fgkRow][fgkCol]; // Array containing individual cell pid
 
-  ClassDef(AliPMDClusterFinder,1)
+  ClassDef(AliPMDClusterFinder,19) // 19 by satyajit
 };
 #endif