1#ifndef EVENTBUILDER_EVENTBUILDER_H
2#define EVENTBUILDER_EVENTBUILDER_H
6#include "Event/PhysicsEventData.h"
7#include "FragmentBuffer.h"
9#include "Framework/Logger.h"
10#include "Packing/Utility/Reader.h"
12namespace eventbuilder {
18 m_verbose_parse_(
false),
22 enableLogging(
"EventBuilder");
31 PhysicsEventData assemblePayload(
const std::vector<DataFragment>& fragments);
33 const std::string& path =
"events.bin");
35 bool m_verbose_parse_;
36 unsigned int m_event_id_;
38 std::string m_input_file_;
40 std::string m_output_name_{
"BuilderOutput"};
41 long long m_coherence_window_ns_{
47 int m_min_subsystems_{2};
54 std::chrono::steady_clock::time_point m_start_time_;
55 std::chrono::steady_clock::time_point m_event_start_time_;
56 uint64_t m_total_bytes_read_{0};
57 uint64_t m_total_events_built_{0};
58 unsigned long m_events_since_last_report_{0};
61 static constexpr unsigned int WINDOW_SIZE =
63 std::chrono::steady_clock::time_point m_window_start_time_;
64 uint64_t m_window_events_count_{0};
65 uint64_t m_window_bytes_read_{0};
Base classes for all user event processing components to extend.
std::string m_performance_file_
performance metrics CSV, empty to disable
void produce(framework::Event &event) override
Process the event and put new data products into it.
void configure(framework::config::Parameters &ps) override
Callback for the EventProcessor to configure itself from the given set of parameters.
std::string m_binary_file_
binary event output, empty to disable
long long m_reorder_window_ns_
extra wait past the window for out-of-order fragments, 0 = none
Implements an event buffer system for storing event data.
Class which represents the process under execution.
Base class for a module which produces a data product.
Class encapsulating parameters for configuring a processor.