ATLAS Offline Software
Loading...
Searching...
No Matches
FPGATrackSimMergeOutputsAlg.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3*/
4
5
6#ifndef FPGATrackSim_MERGEOUTPUTSALG_H
7#define FPGATrackSim_MERGEOUTPUTSALG_H
8
9
11#include "GaudiKernel/ToolHandle.h"
12//#include "FPGATrackSimObjects/FPGATrackSimLogicalEventInputHeader.h"
13//#include "FPGATrackSimObjects/FPGATrackSimLogicalEventOutputHeader.h"
14//#include "FPGATrackSimObjects/FPGATrackSimTrack.h"
17
18#include <vector>
19
20class TFile;
21class TTree;
26
28public:
29 FPGATrackSimMergeOutputsAlg (const std::string& name, ISvcLocator* pSvcLocator);
31 virtual StatusCode initialize() override;
32 virtual StatusCode execute() override;
33 virtual StatusCode finalize() override;
34
35private:
36
37 const static unsigned N=1280;
38
39 Gaudi::Property<std::vector<std::string>> m_inpaths {this, "InFileNames", {"."}, "input file paths"};
40
41 std::vector<TFile*> m_files; // vector of pointers to files
42 std::vector<std::vector<TTree*>> m_trees; // vector of ttrees, first vector over the input files, second over the regions
43 std::vector<std::vector<FPGATrackSimLogicalEventOutputHeader*>> m_eventOutputHeaders; //vector of output headers from above trees
44
45 FPGATrackSimLogicalEventInputHeader *m_dataprep = nullptr; // data prep header, we only need one!
46 TTree *m_dataprep_tree = nullptr; // data prep ttree, we only need one!
47
48 // output track collection
49 SG::WriteHandleKey<FPGATrackSimTrackCollection> m_FPGATrackKey{this, "FPGATrackSimTracks","FPGATracks","FPGATrackSim Tracks key"};
50 SG::WriteHandleKey<FPGATrackSimHitCollection> m_FPGAHitKey{this, "FPGATrackSimHitKey","FPGAHits", "FPGATrackSim Hits key"};
51 ToolHandle<FPGATrackSimOverlapRemovalTool> m_overlapRemovalTool {this, "OverlapRemoval", "FPGATrackSimOverlapRemovalTool/FPGATrackSimOverlapRemovalTool_Last", "Last inter-region overlap removal tool"};
52
53 double m_evtloop = 0; // for counting, make a double because will be for division
54 unsigned long m_alltracks = 0;
55 unsigned long m_tracksPassOR = 0;
56};
57
58#endif // FPGATrackSim_MERGEOUTPUTSALG_H
AthAlgorithm(const std::string &name, ISvcLocator *pSvcLocator)
Constructor with parameters:
std::vector< std::vector< FPGATrackSimLogicalEventOutputHeader * > > m_eventOutputHeaders
ToolHandle< FPGATrackSimOverlapRemovalTool > m_overlapRemovalTool
virtual StatusCode finalize() override
virtual StatusCode initialize() override
FPGATrackSimLogicalEventInputHeader * m_dataprep
FPGATrackSimMergeOutputsAlg(const std::string &name, ISvcLocator *pSvcLocator)
SG::WriteHandleKey< FPGATrackSimHitCollection > m_FPGAHitKey
Gaudi::Property< std::vector< std::string > > m_inpaths
virtual StatusCode execute() override
std::vector< std::vector< TTree * > > m_trees
SG::WriteHandleKey< FPGATrackSimTrackCollection > m_FPGATrackKey
Remove (mark) duplicate tracks This tool takes FPGATrackSimTrack as input and mark their status of pa...
Property holding a SG store/key/clid from which a WriteHandle is made.