Analysis Software
Documentation for sPHENIX simulation software
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
JetSeedCount.h
Go to the documentation of this file. Or view the newest version in sPHENIX GitHub for file JetSeedCount.h
1 // Tell emacs that this is a C++ source
2 // -*- C++ -*-.
3 #ifndef JETSEEDCOUNT_H
4 #define JETSEEDCOUNT_H
5 
6 #include <fun4all/SubsysReco.h>
7 #include <g4jets/Jetv1.h>
8 
9 #include <string>
10 #include <vector>
11 
12 class PHCompositeNode;
13 class TTree;
14 class JetSeedCount : public SubsysReco
15 {
16  public:
17 
18  JetSeedCount(const std::string &recojetname = "AntiKt_Tower_r04",
19  const std::string &truthjetname = "AntiKt_Truth_r04",
20  const std::string &outputfilename = "myjetanalysis.root");
21 
22  ~JetSeedCount() override;
23 
24  void
25  setEtaRange(double low, double high)
26  {
27  m_etaRange.first = low;
28  m_etaRange.second = high;
29  }
30  void
31  setPtRange(double low, double high)
32  {
33  m_ptRange.first = low;
34  m_ptRange.second = high;
35  }
36 
37  int Init(PHCompositeNode *topNode) override;
38 
44  int InitRun(PHCompositeNode *topNode) override;
45 
49  int process_event(PHCompositeNode *topNode) override;
50 
52  int ResetEvent(PHCompositeNode *topNode) override;
53 
55  int EndRun(const int runnumber) override;
56 
58  int End(PHCompositeNode *topNode) override;
59 
61  int Reset(PHCompositeNode * /*topNode*/) override;
62 
63  void Print(const std::string &what = "ALL") const override;
64 
65  private:
69  std::pair<double, double> m_etaRange;
70  std::pair<double, double> m_ptRange;
71  std::vector<int> m_centrality;
72  std::vector<int> m_centrality_diff;
73 
74  int m_event = 0;
77  std::vector<int> m_raw_counts;
78  std::vector<int> m_sub_counts;
79  std::vector<double> m_rawenergy;
80  std::vector<double> m_subenergy;
81  std::vector<double> m_rawcent;
82  std::vector<double> m_subcent;
83 };
84 
85 #endif // JETSEEDCOUNT_H