File indexing completed on 2025-08-05 08:11:14
0001 #ifndef RANDOMCONEANA_H
0002 #define RANDOMCONEANA_H
0003
0004 #include <fun4all/SubsysReco.h>
0005 #include <calotrigger/TriggerAnalyzer.h>
0006 #include <vector>
0007 #include <ffarawobjects/Gl1Packet.h>
0008 #include <ffarawobjects/Gl1Packetv1.h>
0009 #include <ffarawobjects/Gl1Packetv2.h>
0010 #include <calobase/TowerInfoContainer.h>
0011 #include <calobase/TowerInfoContainerv1.h>
0012 #include <calobase/TowerInfoContainerv2.h>
0013 #include <calobase/TowerInfoContainerv3.h>
0014 #include <calobase/TowerInfo.h>
0015 #include <calobase/TowerInfov1.h>
0016 #include <calobase/TowerInfov2.h>
0017 #include <calobase/TowerInfov3.h>
0018
0019 #include "TTree.h"
0020 #include "TFile.h"
0021 #include "TVector3.h"
0022
0023 class TVector3;
0024 class TH1D;
0025 class TProfile;
0026 class PHCompositeNode;
0027 class TowerInfoContainer;
0028 class Fun4AllHistoManager;
0029 class TRandom;
0030 class TriggerAnalyzer;
0031 class RandomConeAna : public SubsysReco
0032 {
0033 public:
0034
0035 RandomConeAna(const std::string &name = "RandomConeAna", const std::string &outfilename = "histos_random.root");
0036
0037 virtual ~RandomConeAna();
0038
0039 int Init(PHCompositeNode *topNode) override;
0040
0041 int InitRun(PHCompositeNode *topNode) override;
0042
0043 int process_event(PHCompositeNode *topNode) override;
0044
0045 void GetNodes (PHCompositeNode *topNode);
0046
0047 int ResetEvent(PHCompositeNode *topNode) override;
0048
0049 int EndRun(const int runnumber) override;
0050
0051 int End(PHCompositeNode *topNode) override;
0052
0053 int Reset(PHCompositeNode * ) override;
0054
0055 void SetVerbosity(int verbo) ;
0056 void SetTrigger(const std::string trigger) {_trigger = trigger;}
0057 void SetIsSim(bool use) {isSim = use;}
0058 private:
0059 TriggerAnalyzer *triggeranalyzer{nullptr};
0060 void reset_tree_vars();
0061
0062 int _verbosity;
0063
0064 std::string m_mb_triggerlist[2];
0065 Fun4AllHistoManager *hm{nullptr};
0066
0067 std::string _trigger;
0068 std::string _foutname;
0069 std::string _nodename;
0070 std::string m_calo_nodename;
0071 int _i_event;
0072 bool isSim{0};
0073
0074 TowerInfo *_tower;
0075 TowerInfoContainer* _towers;
0076
0077 TH1D *h_random_et{nullptr};
0078 TH1D *h_random_emcalre_et{nullptr};
0079 TH1D *h_random_emcal_et{nullptr};
0080 TH1D *h_random_hcalout_et{nullptr};
0081 TH1D *h_random_hcalin_et{nullptr};
0082
0083 TProfile *hp_random_emcalre_fraction{nullptr};
0084 TProfile *hp_random_emcal_fraction{nullptr};
0085 TProfile *hp_random_hcalin_fraction{nullptr};
0086 TProfile *hp_random_hcalout_fraction{nullptr};
0087
0088 TRandom *rdm{nullptr};
0089
0090 };
0091
0092 #endif