Analysis Software
Documentation for sPHENIX simulation software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
hcal_towerid.h
Go to the documentation of this file. Or view the newest version in sPHENIX GitHub for file hcal_towerid.h
1 // Tell emacs that this is a C++ source
2 // -*- C++ -*-.
3 #ifndef HCAL_TOWERID_H
4 #define HCAL_TOWERID_H
5 
6 #include <fun4all/SubsysReco.h>
7 //#include <cdbobjects/CDBTTree.h>
8 
9 #include <string>
10 #include <vector>
11 #include <TTree.h>
12 #include <TH1F.h>
13 #include <TH2F.h>
14 
15 class TTree;
16 class PHCompositeNode;
18 class TFile;
19 class RawCluster;
20 class TowerInfoContainer;
21 
22 class hcal_towerid : public SubsysReco
23 {
24  public:
25 
26  hcal_towerid(const std::string &name = "towerid.root", const std::string &cdbtreename_i = "test.root",const std::string &cdbtreename_o = "test2.root", float adccut_i = 250, float adccut_o = 250, float sigmas_lo = 1, float sigmas_hi = 4.5, float inner_f = 0.03, float outer_f = 0.03);
27 
28  ~hcal_towerid() override;
29 
35  int Init(PHCompositeNode *topNode) override;
36 
42  int InitRun(PHCompositeNode *topNode) override;
43 
47  int process_event(PHCompositeNode *topNode) override;
48 
50  int ResetEvent(PHCompositeNode *topNode) override;
51 
53  int EndRun(const int runnumber) override;
54 
56  int End(PHCompositeNode *topNode) override;
57 
59  int Reset(PHCompositeNode * /*topNode*/) override;
60 
61  void Print(const std::string &what = "ALL") const override;
62 
63 
64  private:
65 
66  TTree *T;
67  TTree *T2;
68  TFile *out;
69 
70 // CDBTTree *cdbttree;
71 
72  //Fun4AllHistoManager *hm = nullptr;
73  std::string Outfile = "commissioning.root";
74 
75  TH1F*Fspeci_i = new TH1F("Fspeci_i","Fspeci_i",0,1,1);
76  TH1F*Fspeci_o = new TH1F("Fspeci_o","Fspeci_o",0,1,1);
77 
78  TH1F*Fspec_i = new TH1F("Espec_i","Espec_i",0,1,1);
79  TH1F*Fspec_o = new TH1F("Fspec_i","Fspec_i",0,1,1);
80 
81  TH1F*Espec_i = new TH1F("Espec_i","Espec_i",0,1,1);
82  TH1F*Espec_o = new TH1F("Espec_o","Espec_o",0,1,1);
83 
86  float adccut_i;
87  float adccut_o;
88  float sigmas_lo;
89  float sigmas_hi;
90  float inner_f;
91  float outer_f;
92 
95  int itowerF[1536] = {0};
96  int otowerF[1536] = {0};
97 
98  float itowerE[1536] = {0};
99  float otowerE[1536] = {0};
100 
101  int ihottowers[1536] = {0};
102  int ohottowers[1536] = {0};
103  int ideadtowers[1536] = {0};
104  int odeadtowers[1536] = {0};
105 
106  int icoldtowers[1536] = {0};
107  int ocoldtowers[1536] = {0};
108 
109 int goodevents = 0;
110 };
111 
112 #endif