File indexing completed on 2025-08-05 08:17:57
0001 #ifndef G4EVAL_PHG4DSTCOMPRESSRECO_H
0002 #define G4EVAL_PHG4DSTCOMPRESSRECO_H
0003
0004 #include <fun4all/SubsysReco.h>
0005
0006 #include <set>
0007 #include <string>
0008
0009 class PHCompositeNode;
0010
0011 class PHG4CellContainer;
0012 class PHG4HitContainer;
0013 class SvtxPHG4ParticleMap;
0014 class PHG4ParticleSvtxMap;
0015 class PHG4TruthInfoContainer;
0016
0017 class RawTowerContainer;
0018
0019 class PHG4DstCompressReco : public SubsysReco
0020 {
0021 public:
0022 PHG4DstCompressReco(const std::string &name = "PHG4DstCompressReco");
0023 ~PHG4DstCompressReco() override {}
0024
0025
0026 int InitRun(PHCompositeNode *topNode) override;
0027
0028
0029 int process_event(PHCompositeNode *topNode) override;
0030
0031 void AddHitContainer(const std::string &name) { _compress_g4hit_names.insert(name); }
0032 void AddCellContainer(const std::string &name) { _compress_g4cell_names.insert(name); }
0033 void AddTowerContainer(const std::string &name) { _compress_tower_names.insert(name); }
0034
0035 void KeepRecoTrackMatchedParticles(bool b = true) { m_keepRecoTrackMatchedParticles = b; }
0036
0037 private:
0038 void SearchG4HitNodes(PHCompositeNode *topNode);
0039
0040
0041
0042 bool m_keepRecoTrackMatchedParticles = false;
0043
0044 PHG4TruthInfoContainer *_truth_info = nullptr;
0045 PHG4ParticleSvtxMap *_truthRecoMap = nullptr;
0046 SvtxPHG4ParticleMap *_recoTruthMap = nullptr;
0047 std::set<std::string> _compress_g4hit_names;
0048 std::set<std::string> _compress_g4cell_names;
0049 std::set<std::string> _compress_tower_names;
0050
0051 std::set<PHG4CellContainer *> _g4cells;
0052 std::set<PHG4HitContainer *> _g4hits;
0053 std::set<PHG4HitContainer *> _keep_g4hits;
0054
0055 std::set<RawTowerContainer *> _towers;
0056 };
0057
0058 #endif