File indexing completed on 2026-07-26 08:22:19
0001
0002
0003
0004
0005
0006
0007
0008 #pragma once
0009
0010
0011 #include "traccc/utils/helpers.hpp"
0012 #include "traccc/utils/messaging.hpp"
0013 #include "traccc/utils/seed_matching_config.hpp"
0014 #include "traccc/utils/truth_matching_config.hpp"
0015
0016
0017 #include "traccc/edm/measurement_collection.hpp"
0018 #include "traccc/edm/seed_collection.hpp"
0019 #include "traccc/edm/spacepoint_collection.hpp"
0020 #include "traccc/utils/event_data.hpp"
0021
0022
0023 #include <map>
0024 #include <memory>
0025 #include <string>
0026 #include <string_view>
0027
0028 namespace traccc {
0029 namespace details {
0030
0031
0032
0033 struct seeding_performance_writer_data;
0034
0035 }
0036
0037 class seeding_performance_writer : public messaging {
0038 public:
0039
0040 struct config {
0041
0042 std::string file_path = "performance_track_seeding.root";
0043
0044 std::string file_mode = "RECREATE";
0045
0046
0047 std::map<std::string, plot_helpers::binning> var_binning = {
0048 {"Eta", plot_helpers::binning("#eta", 40, -4.f, 4.f)},
0049 {"Phi", plot_helpers::binning("#phi", 100, -3.15f, 3.15f)},
0050 {"Pt", plot_helpers::binning("p_{T} [GeV/c]", 40, 0.f, 100.f)},
0051 {"Num", plot_helpers::binning("N", 30, -0.5f, 29.5f)}};
0052
0053
0054 truth_matching_config truth_config;
0055 seed_matching_config seed_truth_config;
0056 };
0057
0058
0059
0060
0061 seeding_performance_writer(const config& cfg,
0062 std::unique_ptr<const traccc::Logger> logger);
0063
0064
0065 ~seeding_performance_writer();
0066
0067 void write(const edm::seed_collection::const_view& seeds_view,
0068 const edm::spacepoint_collection::const_view& spacepoints_view,
0069 const edm::measurement_collection::const_view& measurements_view,
0070 const event_data& evt_data);
0071
0072 void finalize();
0073
0074 private:
0075
0076 config m_cfg;
0077
0078
0079 std::unique_ptr<details::seeding_performance_writer_data> m_data;
0080
0081 };
0082
0083 }