70 uint32_t add_series(std::string name,
93 void bind(uint32_t series_index, std::shared_ptr<Nodes::Node> node);
105 void bind(uint32_t series_index,
106 std::shared_ptr<Buffers::AudioBuffer> buffer);
117 void bind(uint32_t series_index,
118 std::shared_ptr<Nodes::Network::NodeNetwork>
network);
130 void bind(uint32_t series_index,
131 std::function<
void(std::vector<double>&)> fn);
142 void set_raw(uint32_t series_index, std::vector<double> data);
148 void unbind(uint32_t series_index);
155 void write_series(uint32_t index, std::span<const double> samples);
163 void write_sample(uint32_t index, uint64_t sample_index,
double value);
170 void resize_series(uint32_t index, uint64_t
count);
175 [[nodiscard]] uint32_t series_count()
const;
180 [[nodiscard]]
const std::string& series_name(uint32_t index)
const;
185 [[nodiscard]] uint64_t series_size(uint32_t index)
const;
196 [[nodiscard]] std::vector<DataDimension> get_dimensions()
const override;
197 [[nodiscard]] uint64_t get_total_elements()
const override;
202 [[nodiscard]] uint64_t get_num_frames()
const override;
214 [[nodiscard]] std::vector<DataVariant> get_region_data(
const Region& region)
const override;
223 void set_region_data(
const Region& region,
const std::vector<DataVariant>& data)
override;
225 [[nodiscard]] std::vector<DataVariant> get_region_group_data(
const RegionGroup& group)
const override;
226 [[nodiscard]] std::vector<DataVariant> get_segments_data(
const std::vector<RegionSegment>& segments)
const override;
228 [[nodiscard]] std::span<const double> get_frame(uint64_t frame_index)
const override;
229 void get_frames(std::span<double> output, uint64_t start_frame, uint64_t num_frames)
const override;
231 [[nodiscard]]
double get_value_at(
const std::vector<uint64_t>& coordinates)
const override;
232 void set_value_at(
const std::vector<uint64_t>& coordinates,
double value)
override;
234 [[nodiscard]] uint64_t coordinates_to_linear_index(
const std::vector<uint64_t>& coordinates)
const override;
235 [[nodiscard]] std::vector<uint64_t> linear_index_to_coordinates(uint64_t linear_index)
const override;
237 void clear()
override;
242 [[nodiscard]]
const void* get_raw_data()
const override;
243 [[nodiscard]]
bool has_data()
const override;
251 [[nodiscard]] std::unordered_map<std::string, RegionGroup> get_all_region_groups()
const override;
258 [[nodiscard]]
DataAccess channel_data(
size_t index)
override;
259 [[nodiscard]] std::vector<DataAccess> all_channel_data()
override;
268 void register_state_change_callback(
269 std::function<
void(
const std::shared_ptr<SignalSourceContainer>&,
ProcessingState)> cb)
override;
270 void unregister_state_change_callback()
override;
272 [[nodiscard]]
bool is_ready_for_processing()
const override;
273 void mark_ready_for_processing(
bool ready)
override;
275 void create_default_processor()
override;
276 void process_default()
override;
278 void set_default_processor(
const std::shared_ptr<DataProcessor>& processor)
override;
279 [[nodiscard]] std::shared_ptr<DataProcessor> get_default_processor()
const override;
285 [[nodiscard]]
const std::vector<DataVariant>&
get_processed_data()
const override {
return m_processed_data; }
286 [[nodiscard]]
const std::vector<DataVariant>&
get_data()
override {
return m_data; }
316 std::atomic<ProcessingState> m_processing_state { ProcessingState::IDLE };
317 std::atomic<bool> m_ready_for_processing {
false };
Core::GlobalNetworkConfig network
Type-erased accessor for NDData with semantic view construction.
std::shared_ptr< DataProcessingChain > m_chain
std::vector< DataVariant > m_data
uint32_t register_dimension_reader(uint32_t) override
Register a reader for a specific dimension.
void set_processing_chain(const std::shared_ptr< DataProcessingChain > &chain) override
Set the processing chain for this container.
void unload_region(const Region &) override
Unload a region from memory.
void mark_dimension_consumed(uint32_t, uint32_t) override
Mark a dimension as consumed for the current processing cycle.
const std::vector< DataVariant > & get_processed_data() const override
Get a const reference to the processed data buffer.
MemoryLayout get_memory_layout() const override
Get the memory layout used by this container.
std::function< void(const std::shared_ptr< SignalSourceContainer > &, ProcessingState)> m_state_cb
PlotContainer(PlotContainer &&)=delete
void unregister_dimension_reader(uint32_t) override
Unregister a reader for a specific dimension.
std::unordered_map< std::string, RegionGroup > m_region_groups
std::vector< DataVariant > m_processed_data
ContainerDataStructure m_structure
bool all_dimensions_consumed() const override
Check if all active dimensions have been consumed in this cycle.
void mark_buffers_for_removal() override
Mark associated buffers for removal from the system.
bool is_region_loaded(const Region &) const override
Check if a region is loaded in memory.
void set_structure(ContainerDataStructure s) override
Set the data structure for this container.
PlotContainer(const PlotContainer &)=delete
void lock() override
Acquire a lock for thread-safe access.
std::vector< DataVariant > & get_processed_data() override
Get a mutable reference to the processed data buffer.
std::shared_ptr< DataProcessingChain > get_processing_chain() override
Get the current processing chain for this container.
std::vector< double > m_frame_cache
void load_region(const Region &) override
Load a region into memory.
void set_memory_layout(MemoryLayout) override
Set the memory layout for this container.
~PlotContainer() override=default
bool try_lock() override
Attempt to acquire a lock without blocking.
uint64_t get_frame_size() const override
Get the number of elements that constitute one "frame".
void unlock() override
Release a previously acquired lock.
PlotContainer & operator=(PlotContainer &&)=delete
ContainerDataStructure & get_structure() override
Get the data structure defining this container's layout.
std::shared_ptr< DataProcessor > m_processor
const ContainerDataStructure & get_structure() const override
const std::vector< DataVariant > & get_data() override
Get a reference to the raw data stored in the container.
void mark_buffers_for_processing(bool) override
Mark associated buffers for processing in the next cycle.
bool has_active_readers() const override
Check if any dimensions currently have active readers.
PlotContainer & operator=(const PlotContainer &)=delete
SignalSourceContainer holding N named scalar series for plotting and signal use.
DataProcessor that acquires per-series data from heterogeneous sources and writes into PlotContainer:...
Data-driven interface for managing arbitrary processable signal sources.
ProcessingState
Represents the current processing lifecycle state of a container.
std::optional< RegionGroup > get_region_group(const std::unordered_map< std::string, RegionGroup > &groups, const std::string &name)
Get a RegionGroup by name from a group map.
DataModality
Data modality types for cross-modal analysis.
void add_region_group(std::unordered_map< std::string, RegionGroup > &groups, const RegionGroup &group)
Add a RegionGroup to a group map.
MemoryLayout
Memory layout for multi-dimensional data.
void remove_region_group(std::unordered_map< std::string, RegionGroup > &groups, const std::string &name)
Remove a RegionGroup by name from a group map.
Contains the node-based computational processing system components.
Container structure for consistent dimension ordering.
Role
Semantic role of the dimension.
Organizes related signal regions into a categorized collection.
Represents a point or span in N-dimensional space.