Graph
Use Graph when a single linear pipeline is no longer enough. In real deployments, you often need:
- One input, multiple consumers: run inference, recording, and telemetry from the same stream without duplicating ingest.
- Multi-stream coordination: synchronize or merge outputs from multiple cameras/sources before downstream decisions.
- Mixed workloads: combine media-heavy pipeline stages with lightweight in-process logic (routing, filtering, policy checks).
- Selective branching: route only specific frames/events to expensive stages (for example secondary models).
- Operational isolation: keep custom control logic in stage nodes while leaving media/runtime-heavy parts in pipeline nodes.
graph::Graph provides this as a DAG (Directed Acyclic Graph): deterministic forward flow, explicit fan-out/join, and hybrid execution.
How it works
- Define nodes and edges in
Graph. - Build with
GraphSession. - Run with
GraphRun.
You can mix:
PipelineNodefor regular NEATNode/NodeGrouppipeline fragments.StageNodefor in-process custom logic.
Core objects
Graph: DAG container with typed ports and edges.GraphSession: compiles the DAG into runnable segments.GraphRun: runtime handle for push/pull and stats.Compiler: partitions and wires pipeline/stage backends.