ATLAS Offline Software
FPGATrackSimActsTrackInspectionTool.h
Go to the documentation of this file.
1 // Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
2 
3 #ifndef FPGATRACKSIMACTSTRACKINSPECTIONTOOL_H
4 #define FPGATRACKSIMACTSTRACKINSPECTIONTOOL_H
5 
8 
9 
10 #include <deque>
11 #include <memory>
12 #include <map>
13 #include <vector>
14 #include <string>
15 
16 namespace FPGATrackSim {
18  public:
19 
20  ActsTrackInspectionTool(const std::string&, const std::string&, const IInterface*);
21  virtual ~ActsTrackInspectionTool() = default;
22 
23  virtual StatusCode initialize() override;
24 
25  struct FpgaActsTrack {
26  struct Measurement {
27  unsigned long identifier;
28  std::string type; // "Pixel" or "Strip"
30  double x = 0;
31  double y = 0;
32  double z = 0;
33  } coordinates = {};
34  // Acts flags
35  bool measurementFlag = false;
36  bool outlierFlag = false;
37  bool holeFlag = false;
38  bool materialFlag = false;
39  bool sharedHitFlag = false;
40  };
41  Acts::BoundVector parameters = {};
42  std::deque<std::unique_ptr<Measurement>> trackMeasurements;
43  };
44 
45  // Typedef within the class
46  using fpgaActsEventTracks = std::vector<std::unique_ptr<FpgaActsTrack>>;
47 
48  fpgaActsEventTracks getActsTracks (const ActsTrk::TrackContainer& tracksContainer) const;
49  std::string getPrintoutActsEventTracks(const fpgaActsEventTracks& tracks) const;
50  std::string getPrintoutStatistics(const std::map<std::string, std::map<uint32_t,std::vector<uint32_t>> >& tracksForAllEvents) const;
51  private:
52  mutable std::vector<std::unique_ptr<FpgaActsTrack>> m_actsTracks ATLAS_THREAD_SAFE;
53  };
54 }
55 
56 //typedef for all acts tracks of one event
58 
59 #endif
FPGATrackSim::ActsTrackInspectionTool::initialize
virtual StatusCode initialize() override
Definition: FPGATrackSimActsTrackInspectionTool.cxx:13
FPGATrackSim::ActsTrackInspectionTool::FpgaActsTrack::Measurement::sharedHitFlag
bool sharedHitFlag
Definition: FPGATrackSimActsTrackInspectionTool.h:39
ActsTrk::TrackContainer
Definition: TrackContainer.h:31
xAOD::uint32_t
setEventNumber uint32_t
Definition: EventInfo_v1.cxx:127
FPGATrackSim::ActsTrackInspectionTool::FpgaActsTrack::Measurement::measurementFlag
bool measurementFlag
Definition: FPGATrackSimActsTrackInspectionTool.h:35
FPGATrackSim::ActsTrackInspectionTool::FpgaActsTrack::trackMeasurements
std::deque< std::unique_ptr< Measurement > > trackMeasurements
Definition: FPGATrackSimActsTrackInspectionTool.h:42
FPGATrackSim::ActsTrackInspectionTool::FpgaActsTrack::Measurement::type
std::string type
Definition: FPGATrackSimActsTrackInspectionTool.h:28
FPGATrackSim::ActsTrackInspectionTool::getActsTracks
fpgaActsEventTracks getActsTracks(const ActsTrk::TrackContainer &tracksContainer) const
Definition: FPGATrackSimActsTrackInspectionTool.cxx:17
FPGATrackSim::ActsTrackInspectionTool::ActsTrackInspectionTool
ActsTrackInspectionTool(const std::string &, const std::string &, const IInterface *)
Definition: FPGATrackSimActsTrackInspectionTool.cxx:8
FPGATrackSim::ActsTrackInspectionTool::getPrintoutActsEventTracks
std::string getPrintoutActsEventTracks(const fpgaActsEventTracks &tracks) const
Definition: FPGATrackSimActsTrackInspectionTool.cxx:74
FPGATrackSim::ActsTrackInspectionTool
Definition: FPGATrackSimActsTrackInspectionTool.h:17
FPGATrackSim::ActsTrackInspectionTool::FpgaActsTrack::Measurement::outlierFlag
bool outlierFlag
Definition: FPGATrackSimActsTrackInspectionTool.h:36
FPGATrackSim::ActsTrackInspectionTool::FpgaActsTrack::Measurement::materialFlag
bool materialFlag
Definition: FPGATrackSimActsTrackInspectionTool.h:38
FPGATrackSim::ActsTrackInspectionTool::FpgaActsTrack::Measurement::globalCoordinates::y
double y
Definition: FPGATrackSimActsTrackInspectionTool.h:31
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
AthAlgTool.h
FPGATrackSim::ActsTrackInspectionTool::FpgaActsTrack
Definition: FPGATrackSimActsTrackInspectionTool.h:25
FPGATrackSim
Definition: FPGATrackSimPrototrackFitterAlg.h:19
FPGATrackSim::ActsTrackInspectionTool::fpgaActsEventTracks
std::vector< std::unique_ptr< FpgaActsTrack > > fpgaActsEventTracks
Definition: FPGATrackSimActsTrackInspectionTool.h:46
FPGATrackSim::ActsTrackInspectionTool::FpgaActsTrack::parameters
Acts::BoundVector parameters
Definition: FPGATrackSimActsTrackInspectionTool.h:41
FPGATrackSim::ActsTrackInspectionTool::FpgaActsTrack::Measurement
Definition: FPGATrackSimActsTrackInspectionTool.h:26
FPGATrackSim::ActsTrackInspectionTool::FpgaActsTrack::Measurement::coordinates
struct FPGATrackSim::ActsTrackInspectionTool::FpgaActsTrack::Measurement::globalCoordinates coordinates
FPGATrackSim::ActsTrackInspectionTool::FpgaActsTrack::Measurement::holeFlag
bool holeFlag
Definition: FPGATrackSimActsTrackInspectionTool.h:37
FPGATrackSim::ActsTrackInspectionTool::FpgaActsTrack::Measurement::globalCoordinates::x
double x
Definition: FPGATrackSimActsTrackInspectionTool.h:30
FPGATrackSim::ActsTrackInspectionTool::getPrintoutStatistics
std::string getPrintoutStatistics(const std::map< std::string, std::map< uint32_t, std::vector< uint32_t >> > &tracksForAllEvents) const
Definition: FPGATrackSimActsTrackInspectionTool.cxx:117
FPGATrackSim::ActsTrackInspectionTool::FpgaActsTrack::Measurement::globalCoordinates
Definition: FPGATrackSimActsTrackInspectionTool.h:29
FPGATrackSim::ActsTrackInspectionTool::~ActsTrackInspectionTool
virtual ~ActsTrackInspectionTool()=default
FPGATrackSim::ActsTrackInspectionTool::FpgaActsTrack::Measurement::identifier
unsigned long identifier
Definition: FPGATrackSimActsTrackInspectionTool.h:27
AthAlgTool
Definition: AthAlgTool.h:26
TrackContainer.h
FPGATrackSim::ActsTrackInspectionTool::ATLAS_THREAD_SAFE
std::vector< std::unique_ptr< FpgaActsTrack > > m_actsTracks ATLAS_THREAD_SAFE
Definition: FPGATrackSimActsTrackInspectionTool.h:52
FPGATrackSimActsEventTracks
FPGATrackSim::ActsTrackInspectionTool::fpgaActsEventTracks FPGATrackSimActsEventTracks
Definition: FPGATrackSimActsTrackInspectionTool.h:57
FPGATrackSim::ActsTrackInspectionTool::FpgaActsTrack::Measurement::globalCoordinates::z
double z
Definition: FPGATrackSimActsTrackInspectionTool.h:32