Skip to main content

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

  1. Define nodes and edges in Graph.
  2. Build with GraphSession.
  3. Run with GraphRun.

You can mix:

  • PipelineNode for regular NEAT Node/NodeGroup pipeline fragments.
  • StageNode for 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.

Key node families

See also

Tutorials