File indexing completed on 2025-01-18 09:11:02
0001
0002
0003
0004
0005
0006
0007
0008
0009 #pragma once
0010
0011
0012
0013 #include "Acts/EventData/Seed.hpp"
0014 #include "Acts/EventData/SpacePointData.hpp"
0015 #include "Acts/Seeding/SeedFinderConfig.hpp"
0016 #include "Acts/Seeding/SeedFinderGbtsConfig.hpp"
0017 #include "Acts/TrackFinding/RoiDescriptor.hpp"
0018 #include "Acts/Utilities/Logger.hpp"
0019
0020 #include <array>
0021 #include <iostream>
0022 #include <list>
0023 #include <map>
0024 #include <memory>
0025 #include <set>
0026 #include <string>
0027 #include <utility>
0028 #include <vector>
0029
0030 namespace Acts {
0031
0032 template <typename external_spacepoint_t>
0033 struct GbtsTrigTracklet {
0034 public:
0035 GbtsTrigTracklet(std::vector<const GbtsSP<external_spacepoint_t> *> &vSP,
0036 std::vector<TrigInDetTriplet<external_spacepoint_t>> &tbuf)
0037 : m_track(vSP), m_seeds(tbuf) {}
0038
0039 std::vector<const GbtsSP<external_spacepoint_t> *> m_track;
0040 std::vector<TrigInDetTriplet<external_spacepoint_t>> m_seeds;
0041 };
0042
0043 template <typename external_spacepoint_t>
0044 class SeedFinderGbts {
0045 public:
0046 static constexpr std::size_t NDims = 3;
0047
0048 using seed_t = Seed<external_spacepoint_t>;
0049
0050
0051 SeedFinderGbts(const SeedFinderGbtsConfig<external_spacepoint_t> &config,
0052 const GbtsGeometry<external_spacepoint_t> &gbtsgeo,
0053 std::unique_ptr<const Acts::Logger> logger =
0054 Acts::getDefaultLogger("Finder",
0055 Acts::Logging::Level::INFO));
0056
0057 ~SeedFinderGbts() = default;
0058 SeedFinderGbts() = default;
0059 SeedFinderGbts(const SeedFinderGbts<external_spacepoint_t> &) = delete;
0060 SeedFinderGbts<external_spacepoint_t> &operator=(
0061 const SeedFinderGbts<external_spacepoint_t> &) = delete;
0062
0063 void loadSpacePoints(
0064 const std::vector<GbtsSP<external_spacepoint_t>> &gbtsSPvect);
0065
0066
0067 template <typename output_container_t>
0068 void createSeeds(
0069 const Acts::RoiDescriptor & ,
0070 const Acts::GbtsGeometry<external_spacepoint_t> & ,
0071 output_container_t & );
0072
0073 std::vector<seed_t> createSeeds(
0074 const Acts::RoiDescriptor & ,
0075 const Acts::GbtsGeometry<external_spacepoint_t> & );
0076
0077 private:
0078 enum Dim { DimPhi = 0, DimR = 1, DimZ = 2 };
0079
0080
0081 SeedFinderGbtsConfig<external_spacepoint_t> m_config;
0082
0083 void runGbts_TrackFinder(
0084 std::vector<GbtsTrigTracklet<external_spacepoint_t>> &vTracks,
0085 const Acts::RoiDescriptor &roi,
0086 const Acts::GbtsGeometry<external_spacepoint_t> &gbtsgeo);
0087
0088
0089 std::unique_ptr<GbtsDataStorage<external_spacepoint_t>> m_storage{nullptr};
0090
0091
0092 std::vector<TrigInDetTriplet<external_spacepoint_t>> m_triplets;
0093
0094 const Acts::Logger &logger() const { return *m_logger; }
0095 std::unique_ptr<const Acts::Logger> m_logger =
0096 Acts::getDefaultLogger("Finder", Acts::Logging::Level::INFO);
0097 };
0098
0099 }
0100
0101 #include "Acts/Seeding/SeedFinderGbts.ipp"