StRoot  1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
StFgtQAMaker.h
1 
10 /* -------------------------------------------------------------------------
11  * $Log: StFgtQAMaker.h,v $
12  * Revision 1.11 2015/08/29 03:37:26 perev
13  * __
14  *
15  * Revision 1.10 2014/03/05 19:10:16 akio
16  * added getting StFgtCollection from dataset called FGTCOLLECTION made from MuDST
17  *
18  * Revision 1.9 2013/03/15 20:07:41 akio
19  * *** empty log message ***
20  *
21  * Revision 1.8 2013/03/14 13:45:56 akio
22  * A lot of changes
23  *
24  * Revision 1.7 2013/03/07 22:46:45 akio
25  * added track and timing per apvboard
26  *
27  * Revision 1.6 2013/03/03 07:41:00 akio
28  * adding nsigma hist
29  *
30  * Revision 1.5 2013/03/03 04:58:14 akio
31  * reduce # of traces, and fixes some histo ranges
32  *
33  * Revision 1.4 2013/02/21 15:16:18 akio
34  * update
35  *
36  * Revision 1.3 2013/02/16 14:25:55 akio
37  * *** empty log message ***
38  *
39  * Revision 1.2 2013/02/06 21:17:18 akio
40  * some adjustments & adding macro
41  *
42  * Revision 1.1 2013/02/06 17:43:19 akio
43  * new unified QA maker
44  *
45  * Revision 1.1 2013/02/05 21:08:01 akio
46  * *** empty log message ***
47  *
48  * -------------------------------------------------------------------------
49  */
50 
51 #ifndef StFgtQAMaker_hh
52 #define StFgtQAMaker_hh
53 
54 #include "TH1F.h"
55 #include "TH2F.h"
56 #include "TGraph.h"
57 #include "TText.h"
58 #include "TCanvas.h"
59 #include "TString.h"
60 
61 #include "StMaker.h"
62 #include "StEnumerations.h"
63 #include "StRoot/StFgtDbMaker/StFgtDbMaker.h"
64 #include "StRoot/StFgtDbMaker/StFgtDb.h"
65 class StFgtHit;
66 class StFgtCollection;
67 
68 class StFgtQAMaker : public StMaker {
69 public:
70 
71  StFgtQAMaker(const Char_t *name="fgtqa"); // constructor
72  ~StFgtQAMaker() {} // destructor
73 
74  Int_t Init(); // called once for initilization
75  Int_t InitRun(Int_t runnum); // called once per run
76  Int_t Make(); // invoked for every event
77  Int_t Finish(); // called once at the end
78 
79  inline void setRunNumber(Int_t v) {mRunNumber=v;}
80 
81  virtual const char *GetCVS() const {
82  static const char cvs[]="Tag $Name: $ $Id: StFgtQAMaker.h,v 1.11 2015/08/29 03:37:26 perev Exp $ built " __DATE__ " " __TIME__ ;
83  return cvs;
84  };
85 
86 protected:
87  void bookHist();
88  void fillHist();
89  void saveHist();
90  void saveTrace();
91  void pulseFit(StFgtHit* cluster);
92  void textDump();
93  void dip();
94 
95 private:
96  StFgtCollection* fgtCollectionPtr;
97 
98  Int_t mEventCounter;
99  Int_t mRunNumber;
100  StFgtDb* mDb;
101  Int_t mNTimeBin;
102 
103  static const int NHist=10;
104  static const int N1dHist=12;
105  static const int N2dHist=4;
106  static const int NTrkHist=6;
107  TH1F *hist0[NHist];
108  TH1F *hist1[kFgtNumDiscs][kFgtNumQuads][N1dHist];
109  TH2F *hist2[kFgtNumDiscs][N2dHist];
110  TH1F *histTrk[kFgtNumQuads][NTrkHist];
111  TH1F *histDip[2];
112 
113  TCanvas* mCanvas[7];
114  static const int MAXTRACE=100;
115  int mNTrace[kFgtNumDiscs][kFgtNumQuads];
116  int mNTrace2[kFgtNumRdos][kFgtNumArms][kFgtMaxApvId];
117  float mSigmaCut;
118  float mAdcCut;
119 
120  ClassDef(StFgtQAMaker,0)
121 };
122 #endif
Int_t Finish()
A typical Analysis Class.
Definition: StFgtQAMaker.h:68