File indexing completed on 2025-08-05 08:15:16
0001
0002
0003
0004
0005
0006
0007
0008 #ifndef __FastTrackingEval_H__
0009 #define __FastTrackingEval_H__
0010
0011 #include <fun4all/SubsysReco.h>
0012 #include <string>
0013
0014
0015 class PHCompositeNode;
0016 class PHG4TruthInfoContainer;
0017 class SvtxClusterMap;
0018 class SvtxTrackMap;
0019 class TFile;
0020 class TTree;
0021 class TH2D;
0022
0023
0024
0025 class FastTrackingEval: public SubsysReco
0026 {
0027 public:
0028
0029 FastTrackingEval(const std::string &name="FastTrackingEval",
0030 const std::string &filename = "g4eval.root",
0031 const std::string &trackmapname = "SvtxTrackMap");
0032
0033
0034 int Init(PHCompositeNode *);
0035
0036
0037 int process_event(PHCompositeNode *);
0038
0039
0040 int End(PHCompositeNode *);
0041
0042
0043 void set_filename(const char* file)
0044 { if(file) _outfile_name = file; }
0045
0046
0047 enum Flag
0048 {
0049
0050 NONE = 0,
0051 };
0052
0053
0054
0055 void set_flag(const Flag& flag, const bool& value)
0056 {
0057 if(value) _flags |= flag;
0058 else _flags &= (~flag);
0059 }
0060
0061
0062 void fill_tree(PHCompositeNode*);
0063 void reset_variables();
0064
0065 private:
0066
0067 std::string _outfile_name;
0068
0069
0070 std::string _trackmapname;
0071
0072
0073 int _event;
0074
0075
0076 int GetNodes(PHCompositeNode *);
0077
0078
0079 unsigned int _flags;
0080
0081
0082 TTree* _eval_tree_tracks;
0083 int event;
0084
0085 int gtrackID;
0086 int gflavor;
0087 float gpx;
0088 float gpy;
0089 float gpz;
0090 float gpt;
0091 float gp;
0092 float gtheta;
0093 float geta;
0094 float gphi;
0095 float gvx;
0096 float gvy;
0097 float gvz;
0098
0099
0100 int trackID;
0101 int charge;
0102 int nhits;
0103 float px;
0104 float py;
0105 float pz;
0106 float pt;
0107 float p;
0108 float theta;
0109 float eta;
0110 float phi;
0111 float dca2d;
0112
0113
0114 TH2D* _h2d_Delta_mom_vs_truth_mom;
0115 TH2D* _h2d_Delta_mom_vs_truth_eta;
0116
0117
0118 PHG4TruthInfoContainer* _truth_container;
0119 SvtxTrackMap* _trackmap;
0120
0121 };
0122
0123 #endif