15#ifndef NRF_EDGEAI_OBSV_CORE_H
16#define NRF_EDGEAI_OBSV_CORE_H
int nrf_edgeai_obsv_core_init(nrf_edgeai_obsv_core_t *p_ctx, const nrf_edgeai_obsv_model_info_t *p_model)
Initialize portable observability core.
int nrf_edgeai_obsv_core_for_each_metric(nrf_edgeai_obsv_core_t *p_ctx, nrf_edgeai_obsv_metric_cb_t cb, void *user)
Iterate over all registered metrics.
int nrf_edgeai_obsv_core_register(nrf_edgeai_obsv_core_t *p_ctx, nrf_edgeai_obsv_metric_t *p_metric, const void *p_cfg)
Register a metric with the core.
struct nrf_edgeai_obsv_model_info_s nrf_edgeai_obsv_model_info_t
Static model metadata included in observability snapshots.
int nrf_edgeai_obsv_core_update_features(nrf_edgeai_obsv_core_t *p_ctx, const float *p_feats, uint16_t n)
Feed one extracted-feature vector to all FEATURES-source metrics.
bool(* nrf_edgeai_obsv_metric_cb_t)(const nrf_edgeai_obsv_metric_snapshot_t *snap, void *user)
Callback invoked once per registered metric by nrf_edgeai_obsv_core_for_each_metric().
Definition nrf_edgeai_obsv_core.h:71
int nrf_edgeai_obsv_core_update_probs(nrf_edgeai_obsv_core_t *p_ctx, const float *p_probs)
Feed one inference result to all registered metrics.
int nrf_edgeai_obsv_core_deregister(nrf_edgeai_obsv_core_t *p_ctx, nrf_edgeai_obsv_metric_t *p_metric)
Deregister a previously registered metric.
int nrf_edgeai_obsv_core_reset(nrf_edgeai_obsv_core_t *p_ctx)
Reset the inference and feature counters and clear all registered metrics.
uint8_t num_metrics
Total number of registered metrics.
Definition nrf_edgeai_obsv_core.h:64
uint32_t num_features
Total number of processed feature-vector updates (FEATURES stream). Counter for the input stream,...
Definition nrf_edgeai_obsv_core.h:62
nrf_edgeai_obsv_metric_t * p_metrics_list
Head of registered metrics singly linked list.
Definition nrf_edgeai_obsv_core.h:55
nrf_edgeai_obsv_model_info_t model
Model metadata copied during initialization.
Definition nrf_edgeai_obsv_core.h:53
uint32_t num_inferences
Total number of processed inferences (PROBS stream). Wraps at UINT32_MAX.
Definition nrf_edgeai_obsv_core.h:57
Portable observability core (no RTOS).
Definition nrf_edgeai_obsv_core.h:51
Observability metric operation table and list node.
Definition nrf_edgeai_obsv_metrics.h:87
Read-only view over one metric's accumulated counters.
Definition nrf_edgeai_obsv_metrics.h:42
uint16_t num_classes
Number of model output classes.
Definition nrf_edgeai_obsv_core.h:35
uint32_t version
Model version identifier.
Definition nrf_edgeai_obsv_core.h:41
uint16_t num_features
Length of the input-feature vector, in elements. 0 if the model has no FEATURES-source metrics (the f...
Definition nrf_edgeai_obsv_core.h:39
uint16_t model_id
Application-defined model identifier.
Definition nrf_edgeai_obsv_core.h:33
Static model metadata included in observability snapshots.
Definition nrf_edgeai_obsv_core.h:31