ECCE @ EIC Software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
FarForwardEvaluator.h
Go to the documentation of this file. Or view the newest version in sPHENIX GitHub for file FarForwardEvaluator.h
1 #ifndef G4EVAL_FARFORWARDEVALUATOR_H
2 #define G4EVAL_FARFORWARDEVALUATOR_H
3 
4 //===============================================
8 //===============================================
9 #include <fstream>
10 
11 #include <TSystem.h>
12 
13 #include <fun4all/SubsysReco.h>
14 
16 
17 #include <set>
18 #include <string>
19 #include "TH1.h"
20 #include "TH2.h"
21 
22 class CaloEvalStack;
23 class PHCompositeNode;
24 class TFile;
25 class TNtuple;
26 class TTree;
27 
28 
29 template <class T>
30 T GetParameterFromFile( std::string filename, std::string param );
31 
32 
41 
43 {
44  public:
45  FarForwardEvaluator(const std::string &name = "FARFORWARDEVALUATOR",
46  const std::string &ffrname = "FFR",
47  const std::string &filename = "g4eval_ffr.root",
48  const std::string &ip_str = "IP6");
49  ~FarForwardEvaluator() override{};
50 
51  int Init(PHCompositeNode *topNode) override;
52  int process_event(PHCompositeNode *topNode) override;
53  int End(PHCompositeNode *topNode) override;
54 
55  private:
56  std::string _ffrname;
57  std::string _ip_str;
58 
59  // TFile *outfile;
60  // std::string outfilename;
61 
62  TNtuple *g4hitntuple;
63  TNtuple *g4b0hitntuple; // added by Sasha Bylinkin
64  TNtuple *g4rphitntuple; // added by Sasha Bylinkin
65  //TNtuple *clusterntuple;
66 
67  TH2F *h2_ZDC_XY;
69 
70  TH2F *h2_B0_XY;
71 
72  TH2F *h2_RP_XY;
73 
74  std::vector<TH2F*> h2_RP_layers_XY;
75  std::vector<TH2F*> h2_RP_virtlayers_XY;
76 
78 
79  unsigned int _ievent;
80 
81  //Added by Barak
82  unsigned int _towerID_debug;
85  float _eta_debug;
86  float _phi_debug;
87  float _e_debug;
88  float _x_debug;
89  float _y_debug;
90  float _z_debug;
91 
92  std::set<int> _truth_trace_embed_flags;
93  //float _truth_e_threshold;
94  //float _reco_e_threshold;
95 
96  // CaloEvalStack *_caloevalstack;
97 
98  //----------------------------------
99  // evaluator output ntuples
100 
101  //bool _strict;
102 
107 
108  TNtuple *_ntp_gpoint;
109  TNtuple *_ntp_gshower;
110  TNtuple *_ntp_tower;
111  TTree *_tower_debug; //Added by Barak
112  TNtuple *_ntp_cluster;
113 
114  int ZDC_hit;
116 
117  // evaluator output file
118  std::string _filename;
119  TFile *_tfile;
120 
121  // subroutines
125 
127  TH1F *h1_E_dep;
128  TH1F *h1_B0_E_dep;
129  TH1F *h1_B0_E;
130  TH1F *h1_B0_E_abs;
131  TH1F *h1_RP_E_dep;
132  TH1F *h1_RP_E_abs;
133 };
134 
135 #endif // G4EVAL_FARFORWARDEVALUATOR_H