PandaRoot
PndEmcMultiWaveformToCalibratedDigi.h
Go to the documentation of this file.
1 //----------------------------------------------------------------------
2 // File and Version Information:
3 // $Id: Exp $
4 //
5 // Description:
6 // Class PndEmcMultiWaveformToCalibratedDigi. Module to take the hit list for the
7 // calorimeter and make ADC waveforms from them.
8 //
9 // Software developed for the BaBar Detector at the SLAC B-Factory.
10 // Adapted for the PANDA experiment at GSI
11 //
12 // Author List:
13 // Phil Strother Original Author
14 // Dima Melnichuk - adaption for PANDA
15 //
16 // Copyright Information:
17 // Copyright (C) 1996 Imperial College
18 //
19 //----------------------------------------------------------------------
20 //#pragma once
21 #ifndef PndEmcMultiWaveformToCalibratedDigi_H
22 #define PndEmcMultiWaveformToCalibratedDigi_H
23 
24 #include <PndPersistencyTask.h>
25 #include <string>
26 #include <map>
27 #include "TString.h"
28 //#include <vector>
29 
30 class PndEmcHit;
33 class PndEmcWaveform;
34 
35 class TClonesArray;
36 class PndEmcDigiPar;
37 class PndEmcRecoPar;
38 class PndEmcAbsPSA;
40 
48 {
49 
50 public:
51 
52  // Constructors
53 
54  PndEmcMultiWaveformToCalibratedDigi(Int_t verbose=0, Bool_t storedigis=kTRUE);
55 
56  // Destructor
57 
59 
61  virtual InitStatus Init();
62 
63  void SetCalibrationFile(const char* calibrationfilename){fCalibrationFileName = calibrationfilename;};
64 
66  virtual void Exec(Option_t* opt);
67 
68  void SetStorageOfData(Bool_t val); // Method to specify whether digis are stored or not.
69 
70  virtual void SetPSAAlgorithm(PndEmcAbsPSA *psa){fpsaAlgorithm=psa;}
71  virtual void SetPSAAlgorithmPMT(PndEmcAbsPSA *psa){fpsaAlgorithm_pmt=psa;}
72 
73 private:
74  void ReadCalibrationFile();
76  TClonesArray* fWaveformArray;
77 
79  TClonesArray* fDigiArray;
80 
81  Double_t fSampleRate;
82  Double_t fSampleRate_PMT;
83  Double_t fEnergyDigiThreshold;
84  Double_t fASIC_Shaping_int_time; //s
85  Double_t fPMT_Shaping_int_time; //s
86  Double_t fPMT_Shaping_diff_time; //s
87  Double_t fCrystal_time_constant; //s
88  Double_t fShashlyk_time_constant; //s
89  Int_t fNumber_of_samples_in_waveform;
90  Int_t fNumber_of_samples_in_waveform_pmt;
91 
92  //std::string fDigiPosMethod;// "surface" or "depth"
93  TString fDigiPosMethod;
94  Double_t fEmcDigiRescaleFactor;
95  Double_t fEmcDigiPositionDepthPWO;
96  Double_t fEmcDigiPositionDepthShashlyk;
97 
98  PndEmcAbsPulseshape* fPulseshape;
99  PndEmcAbsPulseshape* fPulseshape_pmt;
100  PndEmcAbsPSA *fpsaAlgorithm;
101  PndEmcAbsPSA *fpsaAlgorithm_pmt;
102 
103  PndEmcDigiPar* fDigiPar;
104  PndEmcRecoPar* fRecoPar;
106  virtual void SetParContainers();
107 
109  Int_t fVerbose;
110 
111  Bool_t fStoreDigis;
112 
113  Double_t fWfNormalisation; // Waveform normalisation constant
114  Double_t fWfNormalisation_pmt;
115  Double_t fWfNormalisation_proto192;
116 
117  std::map<Int_t,Double_t> fCalibrationMap;
118  std::map<Int_t,Double_t> fGainMap;
119  TString fCalibrationFileName;
120 
122 
123 
124 };
125 
126 #endif
127 
128 
129 
130 
131 
Module to take the hit list for the calorimeter and make ADC waveforms from them. ...
stores crystal index coordinates (x,y) or (theta,phi)
parameter set of Emc digitisation
Definition: PndEmcDigiPar.h:12
void SetCalibrationFile(const char *calibrationfilename)
represents a simulated waveform in an emc crystal
Class to hold multiple waveforms from one Emc Hit / ADC readout.
virtual void Exec(Option_t *opt)
Baseclass for pulseshapeanalysis ( featureextraction )
Definition: PndEmcAbsPSA.h:21
represents the deposited energy of one emc crystal from simulation
Definition: PndEmcHit.h:28
pulseshape interface
PndEmcMultiWaveformToCalibratedDigi(Int_t verbose=0, Bool_t storedigis=kTRUE)
Parameter set for Emc Reco.
Definition: PndEmcRecoPar.h:12