pub struct BatchEntry {
pub feed_id: FeedId,
pub frame: FrameEnvelope,
pub view: ViewSnapshot,
pub output: Option<StageOutput>,
}Expand description
An entry in a batch, passed to BatchProcessor::process.
Each entry represents one frame from one feed. The processor reads
frame (and optionally view and feed_id) then writes the
per-item result into output.
§Contract
After BatchProcessor::process returns Ok(()), every entry’s
output should be Some(StageOutput). Entries left as None are
treated as if the processor returned StageOutput::empty() for
that item.
Fields§
§feed_id: FeedIdThe feed that submitted this frame.
frame: FrameEnvelopeThe video frame to process.
FrameEnvelope is Arc-backed — zero-copy reference, cheap to
clone. Use frame.require_host_data() to obtain host-readable
bytes (zero-copy for host frames, cached materialization for
device frames), or frame.host_data() when host residency is
guaranteed.
view: ViewSnapshotView-state snapshot at the time of this frame.
Processors may use this to skip inference during rapid camera movement or adapt behavior based on camera stability.
output: Option<StageOutput>Slot for the processor to write its per-item output.
Must be set to Some(...) for each successfully processed item.
Any StageOutput variant is valid — detections, scene features,
signals, or typed artifacts for downstream consumption.