AHOY Perception
The end-to-end platform for production computer vision — one integrated system from physical sensors to deployed inference: annotate, version, train, evaluate, deploy and monitor, with the data and the model fully traceable at every step.
API-first · SDK · CLI · Web
Edge · On-prem · Cloud · Air-gap
Full data & model lineage
Vertically-integrated architecture
Why it's different
- One platform, not a toolchain. Label, version, train, serve — no seams where reproducibility leaks out.
- Lineage by construction. Every model traces to the exact data and code that made it; data leakage is structurally impossible.
- Git for datasets. Immutable, fingerprinted, copy-on-write versions you can diff and pull back byte-for-byte.
- Runs on what you have. A resource governor admits work against live GPU/CPU capacity — SaaS or on-prem.
- Deploy by YAML. One config file takes an ONNX model to live multi-stream inference, edge to cloud.
The thin glue that is the product:
Best-in-class permissive components:
The same stack, placed where data lives:
AHOY Perception · Solution brief — see the companion Technical Architecture & Platform Diagram for detail.
AHOY Perception
End-to-end platform for production computer vision — sensors to inference
Perception Workflow
One API-first platform for the full lifecycle — from raw sensor data to a deployed model — driven from a web studio, SDK, CLI or REST.
Lineage & Trust
Every model traces back to the exact data and code that made it. Reproducibility, access control and compliance across all datasets and models.
Vision Models
State-of-the-art CV architectures plus bring-your-own-model. Detection, classification, pose and segmentation, registered with full lineage.
Data & Compute Core
A content-addressed dataset store with git-like versioning, plus resource-aware training and serving on whatever hardware is present.
Heterogeneous Compute
Deploy on the hardware and clusters you already run. The same stack ships to a Jetson at the edge, a server room, or a cloud region.
From the sensor to the served model
An end-to-end platform and SDK for production computer vision — covering the full journey from physical sensors to deployed inference: annotate, version, train, evaluate, deploy and monitor, with the data and the model fully traceable at every step.
01 Executive summary
Computer-vision teams today stitch together a dozen disconnected tools — one to label, another to store data, a notebook to train, a registry somewhere, and a separate runtime to deploy. The seams are where reproducibility, accuracy and time-to-production are lost.
AHOY Perception collapses that toolchain into a single, vertically-integrated platform. A team ingests data from cameras, LiDAR or RADAR; labels it with AI assistance; freezes it into an immutable, versioned dataset; trains a built-in or custom model on whatever compute is available; evaluates and selects the best candidate; exports it to an optimized runtime format; and deploys it for live inference at the edge, on-prem or in the cloud — all through one API, one SDK and one web studio.
North star. Any model's lineage must trace back to the exact data and the exact code that created it. Every dataset is an immutable, content-addressed snapshot; every training run links a model version to the dataset version and configuration that produced it. Reproducibility is structural, not aspirational.
The guiding build philosophy is to adopt the hard, generic parts and build only the thin glue that is the product: best-in-class permissively-licensed components (annotation, tracking, serving, identity) stitched by an API-first backend, with three things built in-house because off-the-shelf tools do them badly — a git-like data-versioning engine, a resource-aware job governor, and a YAML-driven inference runtime.
02 Architecture at a glance
The platform is organized as five layers. The workflow a user touches sits on top; underneath it, governance makes every action traceable, the model layer supplies the intelligence, the data & compute engine does the heavy lifting, and the infrastructure layer places it all on the hardware you already run.
See the companion Platform Architecture Diagram for the full layered view with per-layer capabilities.
Perception Workflow
The end-to-end lifecycle, exposed identically through Web Studio, Python SDK, CLI and REST.
Lineage & Trust
RBAC, audit, reproducible splits, immutability, tenant isolation, compliance.
Vision Models
Detection, classification, pose, segmentation, plus bring-your-own-model.
Perception Data Engine
Content-addressed versioning, resource governor, sandboxed training, serving.
03 The perception lifecycle
Every capability maps to one stage of a single closed loop. The same steps run whether driven by a point-and-click studio user or a CI pipeline calling the SDK — because both hit the same API.
① Capture — from physical sensors to managed data
Data enters from live cameras (RTSP/RTMP/HLS), recorded video and image files, or other modalities such as LiDAR and RADAR captures. Bytes are streamed into object storage, hashed (SHA-256) and stored exactly once — duplicates across a workspace collapse to a single blob.
② Annotate — label with AI assistance
A rebranded annotation studio handles boxes, masks, keypoints and classes, with optional AI pre-labeling (e.g. SAM / GroundingDINO) to bootstrap labels for a human to correct. Already-labeled data imports directly via COCO or YOLO.
③ Version — git for datasets
The working set is frozen into a numbered, immutable version with a content fingerprint and a deterministic, leakage-safe train/val/test split. Versioning is metadata-only and copy-on-write — a new version that adds 300 images to an existing 1,200 stores only the 300 new blobs.
④ Train — catalog, fine-tune, or bring your own
Pick a built-in architecture, a fine-tuning recipe, or supply your own model code. The job is admitted by the resource governor when a slot is free; untrusted custom code runs sandboxed. Metrics stream live to the studio and the SDK.
⑤ Optimize — evaluate, select, export
Compare runs on per-class metrics, PR curves and confusion matrices; promote the best candidate; export to ONNX (portable) or a TensorRT engine (fastest on NVIDIA), packaged for the inference runtime.
⑥ Deploy & Infer — anywhere
The exported model drops into the YAML-driven inference runtime and serves live streams on edge devices, on-prem servers or cloud GPUs. Detections flow out as overlaid video, files, or structured Kafka messages.
04 Layer-by-layer
Application Layer — Perception Workflow
The platform is API-first: one versioned public API is the product, and the Web Studio, Python SDK and CLI are co-equal clients of it. Everything the UI can do is reachable from code.
- Web Studio — point-and-click for labelers, reviewers and managers.
- Python SDK — script the whole loop: create → upload → version → train → stream metrics → export → deploy.
- CLI — a thin wrapper over the SDK for CI/CD and ops.
- REST API — versioned (
/v1), OpenAPI-specified, with async-job semantics and webhooks.
Governance Layer — Lineage & Trust
- Data & model lineage — a dual foreign key ties every model to its dataset version and run.
- Reproducible splits & immutability — committed versions never change; splits are deterministic.
- RBAC, SSO/MFA, audit logging — adopted via Keycloak; who-changed-what is recorded.
- Tenant isolation & quotas — strict per-workspace separation, storage quotas, GDPR purge.
Model Layer — Vision Models
- Built-in architectures — detection (YOLO, RT-DETR), classification, pose, instance segmentation.
- NVIDIA TAO — the native train → ONNX → TensorRT → DeepStream path for CV.
- Bring-your-own-model — three tiers: catalog, script-mode, and full custom container.
- Plugin contracts — register a model like a DeepStream plugin; the UI builds its config form automatically.
Perception Data Engine — Data & Compute Core
- Content-addressed store — bytes stored once by hash, deduplicated per workspace.
- Git-for-datasets — immutable versions, diffs, tags, lineage, COCO/YOLO import-export.
- Resource governor & job queue — admits work against live hardware capacity.
- Serving runtimes — Triton for hosted endpoints, DeepStream for streaming inference.
Infrastructure Layer — Heterogeneous Compute
- Targets — Edge (Jetson/IGX), on-prem servers, cloud (AWS/Azure/GCP), and air-gapped sites.
- Compute — GPU / MIG slices, multi-GPU, or CPU-only — the platform detects and adapts.
- Storage — cloud S3 or self-hosted SeaweedFS; PostgreSQL for all metadata.
05 Data versioning engine Built in-house
This is the bottom of the stack and the part no off-the-shelf tool gives you the right way. It is an independent, hexagonal module (ports & adapters): a pure core that runs standalone on a laptop (SQLite + local disk), embedded in the platform, or as a microservice — the same code in every mode.
Content-addressed, copy-on-write storage
File bytes are stored once by their sha256 and deduplicated within a workspace. A dataset references content; a version freezes those references. Nothing copies bytes, so versions are cheap metadata.
| Table | Role |
|---|---|
datasets | Named, workspace-owned containers; soft-delete; unique slug per workspace. |
files | Content records — one per unique (workspace, sha256). |
dataset_files | The mutable working area — (dataset, filename) → file. |
dataset_versions | Immutable snapshots — number, fingerprint, split, parent_id lineage. |
version_files | The frozen manifest — (filename, sha256, role, split) per version. |
version_tags | Stable mutable names (production, golden) → one version. |
Reproducible by construction
- Fingerprint —
manifest_hash= sha256 over the sorted manifest rows, computed in Python (codepoint sort, canonical JSON) so it is identical on SQLite and Postgres. - Leakage-safe split — each file's bucket is decided by hashing its content plus a seed, so duplicate bytes can never straddle train and test, and the split survives renames.
- Lineage — every commit records its
parent_id; the chain walks back to origin.
Safe deletion over immutable, deduplicated data
Because versions are immutable and blobs are shared, deletion removes a reference, never naively the bytes. Reference counting plus a grace-period garbage collector reclaims a blob only when zero versions point at it. A lineage guard protects any version a model was trained on, and GDPR erasure is an explicit, audited tombstone.
06 Models & training
For the CV core, NVIDIA TAO Toolkit is the backbone: a clean train → export(.onnx) → TensorRT engine path that drops straight into the inference runtime. Alongside it, MMDetection / RT-DETR and Hugging Face cover Apache/BSD-licensed alternatives.
Three execution tiers for custom models
| Tier | What the user brings | Runs in | Trade-off |
|---|---|---|---|
| 0 · Catalog | A built-in architecture + hyperparameters | Curated images | Lowest effort, safest |
| 1 · Script mode | A training script + a deps list | Curated framework base images | BYO model, recommended default |
| 2 · BYO container | A full Docker image with their code | Their image, sandboxed | Max flexibility, max security surface |
The plugin framework — "define the rules, users add models"
Just as DeepStream lets you drop in a custom plugin by implementing a known interface, the platform defines a small set of extension-point contracts (build / train / evaluate / export). A user implements them to make their own model a first-class, trainable, reproducible citizen — discovered via standard Python entry points, configured from a JSON-Schema manifest that the UI renders into a form automatically.
07 Inference & deployment runtime Built in-house
The Perception SDK replaces dozens of low-level DeepStream config files, GStreamer elements and inference parameters with a single declarative YAML file. You provide an ONNX model and labels; the SDK generates every DeepStream config, links the pipeline, and routes multi-stream output automatically.
Model types
Detector, classifier, pose (17 COCO joints), instance segmentation, and Triton-served variants — chainable (e.g. detect → track → classify).
Architectures
YOLO v5–v13 / v26 & YOLOX, DetectNet_v2, YOLO-pose, YOLO-seg, and any softmax classifier (ResNet, EfficientNet, ViT…).
Inputs
Local files, RTSP, RTMP and HLS streams — single or multi-stream, batched automatically.
Outputs
X11 display overlays, MP4/MKV files, RTSP/RTMP re-streaming, FPS metering, and structured per-frame Kafka detection messages.
Hardware-accelerated encode/decode (GPU by default, CPU fallback) means the same YAML runs on a Jetson at the edge and a multi-GPU server — only the device changes.
08 Reproducibility & lineage
Lineage is the spine that connects the two in-house engines. The data engine fingerprints every dataset version; the training layer records, for every run, which dataset version and which model code produced the artifact.
| Question | How the architecture answers it |
|---|---|
| What exact data trained this model? | A dual FK from the model version to its dataset_version — a single join. |
| Can I rebuild last month's dataset? | version.pull() reconstructs the exact files, labels and split byte-for-byte. |
| Did the data change between runs? | diff(a, b) reports added / removed / relabeled, with old and new hashes. |
| Which code produced the model? | The run records its source type and reference (catalog id, script + commit, or image digest). |
| Did test data leak into training? | Content-hash splitting makes leakage structurally impossible. |
09 Multi-tenancy & resource governance Built in-house
What a user is allowed to run depends on live capacity, not hardcoded limits — and this holds identically for hosted SaaS and a customer's on-prem box, where the hardware is unknown in advance. A resource governor probes the host and admits work against real capacity.
- Probe — GPUs present? VRAM free? CPU cores, RAM, disk — continuously, gracefully handling a no-GPU host.
- Request — every job carries a resource request (catalog models fill it in; plugins declare it).
- Admit / queue / reject — fits now → run; could fit later → queue with a visible position; can never fit → reject with a clear reason.
| Detected hardware | Sharing strategy | Concurrency |
|---|---|---|
| No GPU (CPU-only) | CPU/RAM-bound; GPU jobs rejected | by free cores / RAM |
| One consumer GPU | whole-GPU per job; MPS for bursty small jobs | ~1 heavy job |
| Several GPUs | one job per GPU, or multi-GPU jobs | = # GPUs |
| Datacenter GPU (A100/H100) | optional MIG partitioning into isolated slices | up to # slices |
Tenant isolation is structural: every operation resolves through a single workspace-scoped chokepoint, so cross-tenant access is impossible by construction rather than by per-call discipline.
10 Deployment topologies
Jetson / IGX devices
The inference runtime ships to the device; models exported as TensorRT engines for the target GPU. Streams processed locally, detections published upstream.
Single-tenant appliance
The full platform as a self-contained bundle on the customer's LAN. The governor auto-sizes to the box; license-safe component swaps (SeaweedFS, Valkey).
Multi-tenant SaaS
Hosted, with cloud object storage, GPU pools and MIG-aware scheduling; horizontal scale-out via Ray or Kubernetes when a single node is outgrown.
Disconnected sites
For regulated or offline environments — the same bundle with no outbound dependencies, models and data never leaving the perimeter.
11 Technology stack & licensing
| Concern | Choice | Posture | Why |
|---|---|---|---|
| Public API / SDK / CLI | FastAPI · Python SDK · Typer | Build | One versioned API; clients generated from the spec. |
| Identity | Keycloak | Adopt | Apache-2.0; realms = tenants; SSO/MFA free. |
| Annotation | Label Studio CE | Adopt | Apache-2.0; rebrand & resell freely. |
| Data versioning | Custom on Postgres + object store | Build | SaaS needs row-level, API-first snapshots — not git-shaped tools. |
| Tracking + registry | MLflow (headless) | Adopt | Apache-2.0 REST backend; charts rendered in our UI. |
| Queue + sandbox | RQ/Dramatiq + Valkey · gVisor | Build/Adopt | Clean hard-cancel; safe untrusted-code execution. |
| Training (CV) | NVIDIA TAO · MMDet / RT-DETR | Adopt ⚠ | Native ONNX→TRT→DeepStream; verify NVIDIA EULA. |
| Serving | Triton · DeepStream (Perception SDK) | Adopt/Build | BSD-3 Triton; YAML runtime built in-house. |
| Object storage | Cloud S3 / SeaweedFS | Adopt | Avoid MinIO (AGPL) for the appliance. |
12 Delivery roadmap
| Phase | Delivers | Milestone |
|---|---|---|
| 1 · Data engine | Content-addressed store, immutable versions, diff/pull, lineage, SDK + CLI. | Import a folder → commit v1 → pull it back byte-for-byte. |
| 2 · Label & interchange | Rebranded annotation, COCO/YOLO import-export, tags, stats. | Annotate & freeze a labeled dataset via UI and API. |
| 3 · Train & track | Governor, catalog + script-mode training, MLflow, live metrics, registry. | One-call .train() with live metrics, model tied to dataset version. |
| 4 · BYO & serve | gVisor sandbox + BYO-container, ONNX/TRT export, Triton + DeepStream serving, RBAC, audit. | Multi-tenant beta with full bring-your-own-model. |
| 5 · Appliance & scale | On-prem bundle, air-gap, license-safe swaps; Ray/K8s scale-out. | Customer runs the rebranded appliance on their LAN / edge. |
Create your own inference pipeline
Bring your own model or generate one with our SDK — then compose a live, multi-stream inference pipeline in a single YAML file that runs unchanged from a device at the edge to a GPU in the cloud.
Two ways to get a model — both end deployable
Whether you train from scratch on the platform or arrive with a model already in hand, you finish with the same thing: a portable artifact the pipeline can serve.
Train it on the platform
No model yet? Build one from your data with the AHOY training pipeline — fully tracked and reproducible.
Drop in a model you already have
Already trained elsewhere? Provide an ONNX file and a labels list — no retraining, no lock-in.
Connect inputs → inference → outputs
A pipeline is a dataflow: one or more sources feed an inference chain, which feeds one or more sinks. You declare it; the SDK generates all the DeepStream wiring.
- Cameras — RTSP / RTMP
- HLS (http/https)
- Recorded files
- Multi-stream, batched
- Detector (YOLO / RT-DETR)
- Pose · Segmentation
- Classifier (chained)
- Tracker — IOU / NvSORT / NvDCF
- Display (tiled)
- File — MP4 / MKV
- RTSP / RTMP re-stream
- Kafka — JSON detections
# pipeline.yaml — declare the dataflow, run with: vision-runner pipeline.yaml streams: - { uri: "rtsp://camera-01/stream", source_id: 0 } models: - { name: detector, type: detector, architecture: yolo11, onnx_file: /models/model.onnx, label_file: /models/labels.txt } - { type: tracker, tracker_type: NvSORT } sinks: outputs: - { type: display } - { type: kafka, broker: "kafka:9092", topic: detections }
One pipeline, anywhere on the continuum
The same YAML runs on a Jetson at the edge, a server on your LAN, or a GPU in the cloud — only the target device changes. Models export to a TensorRT engine tuned per device; GPU encode/decode falls back to CPU when needed.
Lowest latency, data never leaves the device. Best for real-time control & privacy-sensitive sites.
Full data residency & compliance control, with room for more streams and bigger models.
Elastic scale across many cameras and sites; GPU pools and MIG-aware scheduling.
| Dimension | Edge | On-prem | Cloud |
|---|---|---|---|
| Latency | Lowest — processed locally | Low (LAN) | Network-bound round-trip |
| Data residency | Stays on device | Stays on your network | Leaves the perimeter |
| Scale | Per-device | Per-server / cluster | Elastic, many sites |
| Hardware | Jetson / IGX GPU | Your GPUs (MIG optional) | Cloud GPU pools |
| Best for | Real-time, offline, regulated | Compliance, steady load | Burst, aggregation, central ops |
Four steps to a running pipeline
Get a model
Train with the SDK or bring your own ONNX + labels.
Write one YAML
Declare streams, models & sinks in pipeline.yaml.
Run it
vision-runner pipeline.yaml on the target device.
Stream results
View live, re-stream RTSP, or publish detections to Kafka.
What you can compose
Multi-stream
Many cameras in one pipeline — tiled or per-stream outputs.
Model chaining
Detector → tracker → classifier, or nested detectors.
Precision control
FP16 or FP32; batch size auto-tuned to stream count.
Structured output
Per-frame JSON to Kafka with class, bbox & tracking ID.
Triton-served
Point at a Triton endpoint instead of a local ONNX file.
Active classes
Detect only the class IDs you care about.
HW-accelerated
NVIDIA encode/decode by default, CPU fallback.
Full lineage
SDK-trained models trace back to their exact dataset.
One YAML file, one command
A YAML-driven video analytics SDK. Define your input streams, AI models, object tracker, and outputs in a single config file and run everything with one command — the SDK generates all DeepStream configuration automatically.
01 Overview
Define your input streams, AI models, object tracker, and outputs in a single config file and run everything with one command.
What you receive
| Item | Description |
|---|---|
| Container image | The SDK, delivered as a licensed Docker image through AMS. Bundles the DeepStream runtime, the vision-runner CLI, and all native libraries. |
| Example YAML configs (optional) | Ready-to-use pipeline configurations |
Prerequisites
- NVIDIA GPU with driver 590 or newer (required by DeepStream 9.0)
- Docker with the NVIDIA Container Toolkit (for GPU access)
- AMS credentials (API key and service ID) — provided with your subscription
- Your model weights (ONNX + label files) and input media files or camera streams
Running the container
The SDK ships as a licensed Docker image through AMS — there is no separate install step. Pull the image with the credentials AMS gives you, then start it with GPU access, your model-weights directory mounted, and (for the display output) X11 forwarding:
# Allow the container to open a display window (see Display below) xhost +local:docker docker run \ --gpus all -itd --network=host --privileged \ -v /path/to/model_weights:/root/models \ -v /tmp/.X11-unix:/tmp/.X11-unix -e DISPLAY=$DISPLAY \ -e AMS_API_KEY="ams_..." \ -e AMS_SERVICE_ID="<service-id>" \ <ams-image>:<tag>
AMS credentials
| Variable | Required | Description |
|---|---|---|
AMS_API_KEY | Yes | Your AMS API key (ams_...) |
AMS_SERVICE_ID | Yes | UUID of the subscribed Perception SDK service |
Run options
| Option | Purpose |
|---|---|
--gpus all | Expose all host GPUs to the container (required) |
-itd | Interactive terminal, detached — the container runs in the background |
--network=host | Share the host network stack, so the pipeline can reach RTSP cameras, Kafka brokers, or webhook endpoints on the host/LAN |
--privileged | Full device access (required for GPU and display) |
-v /path/to/model_weights:/root/models | Mount your model weights (ONNX + labels) and configs into the container. Reference these paths in your YAML. |
-v /tmp/.X11-unix:/tmp/.X11-unix | Mount the host X11 socket — required only for the display output |
-e DISPLAY=$DISPLAY | Forward the host display into the container — required only for the display output |
Display
The display output opens a live video window on your host's X server. It needs the two X11 options above, plus permission for the container to reach your display (xhost +local:docker). Outputs that do not render a window (file, rtsp, rtmp, kafka, webhook, fps_meter) do not require X11 — omit the two X11 options if you are not using display.
Quick start
1. Create a config file (pipeline.yaml) inside your mounted weights directory, so it is visible in the container under /root/models:
pipeline: name: "My First Pipeline" streams: - uri: "file:///root/models/video.mp4" source_id: 0 models: - name: "my-detector" type: "detector" architecture: "yolo11" onnx_file: /root/models/model.onnx label_file: /root/models/labels.txt outputs: width: 1280 height: 720 video: - type: "display"
/root/models directory.2. Run it inside the running container:
docker exec -it <container> vision-runner /root/models/pipeline.yaml
3. Stop the pipeline with Ctrl+C.
Running multiple pipelines
Because the container started with -itd idles in the background, you can run several pipelines side by side — each vision-runner is its own independent process, so they don't affect one another. Start each in the background with docker exec -d:
docker exec -d <container> vision-runner /root/models/lot-a.yaml docker exec -d <container> vision-runner /root/models/lot-b.yaml
Give each pipeline a distinct pipeline.name and, for streaming outputs (rtsp/rtmp), distinct URLs/ports so they don't collide.
To run a single pipeline without a long-lived container, pass the config directly — the container then runs that one pipeline and exits when it ends:
docker run --gpus all --network=host --privileged \ -v /path/to/model_weights:/root/models \ -e AMS_API_KEY="ams_..." -e AMS_SERVICE_ID="<service-id>" \ <ams-image>:<tag> /root/models/pipeline.yaml
02 Configuration overview
pipeline: # Pipeline metadata (optional) streams: # Input sources (required) models: # AI models and tracker (required) outputs: # Where results go: video + events (required)
| Section | Required | Description |
|---|---|---|
pipeline | No | Pipeline metadata |
pipeline.name | No | Friendly name for logs (default: vision-pipeline) |
streams | Yes | List of input sources (at least 1) |
models | Yes | List of AI models and/or a tracker (at least 1) |
outputs | Yes | Output configuration (video and/or events) with at least 1 output |
03 Input — streams
streams: - uri: "file:///path/to/video.mp4" source_id: 0 - uri: "rtsp://192.168.1.100:554/live" source_id: 1
Stream fields
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
uri | string | Yes | — | Input source URI |
source_id | integer | No | list index (0, 1, 2…) | Unique ID for this stream |
mode: "multi"), set source_id on each stream so they match their corresponding output entries. For a single stream, source_id can be omitted.Supported URI formats
| URI prefix | Type |
|---|---|
file:///path/to/video.mp4 | Local file |
rtsp://host:port/path | RTSP stream |
rtmp://host:port/path | RTMP stream |
http:// / https:// | HLS stream |
04 Models
The models list defines the inference pipeline — detectors, classifiers, pose estimators, segmentation models, Triton models, and an optional tracker. Entries are processed in the order they appear, which controls the inference chain.
Common model fields
Apply to all model types except tracker:
| Field | Type | Req. | Default | Description |
|---|---|---|---|---|
name | string | No | auto (e.g. detector_0) | Unique name; referenced by operate_on for chaining |
type | string | Yes | — | Model type (see below) |
onnx_file | string | Yes | — | Path to ONNX model file |
label_file | string | Yes | — | Path to label file (one class name per line) |
batch_size | integer | No | next pow-2 ≥ stream count | Inference batch size |
precision | string | No | fp16 | Inference precision: fp32 or fp16 |
num_classes is determined by counting non-empty lines in label_file, and the inference config is auto-generated — you only provide the ONNX model and labels.Model types
| Type | Description |
|---|---|
detector | Object detection with bounding boxes |
pose | Human keypoint estimation (17 COCO joints) |
segmentation | Instance segmentation with mask overlay |
classifier | Secondary classification on detected objects |
triton_detector | Object detection via Triton Inference Server |
triton_classifier | Classification via Triton Inference Server |
tracker | Object tracking |
Detector
Runs on full frames and produces bounding-box detections. At least one primary detector (without operate_on) is required in every pipeline.
| Field | Type | Req. | Default | Description |
|---|---|---|---|---|
architecture | string | Yes | — | Model architecture (see below) |
active_classes | list<int> | No | all classes | Only detect these class IDs (0-indexed) |
operate_on | string | No | — | Parent model name (makes this a secondary detector) |
operate_on_classes | list<int> | No | all parent classes | Only process these parent class IDs |
Supported detector architectures
yolo5 · yolo6 · yolo7 · yolo8 · yolo9 · yolo10 (built-in NMS) · yolo11 · yolo12 · yolo13 · yolo26 (built-in NMS) · yolox · detectnet_v2 (NVIDIA TAO / ResNet-based)
Pose estimation
Detects human keypoints (17 COCO joints) in addition to bounding boxes; skeleton overlays are drawn automatically. Field architecture required; active_classes optional.
Architectures: yolo_pose8 · yolo_pose11 · yolo_pose26 (each n/s/m/l/x variants)
Instance segmentation
Detects objects and produces per-instance masks, drawn automatically. Field architecture required; active_classes optional.
Architectures: yolo_seg5 · yolo_seg8 · yolo_seg11 · yolo_seg26
Classifier (model chaining)
Classifiers run on objects detected by a parent model and must reference it with operate_on. The SDK supports a softmax classifier compatible with ResNet, VGG, GoogLeNet/Inception, MobileNet, EfficientNet, SqueezeNet, DenseNet, ShuffleNet, DarkNet and Vision Transformers (ViT/DeiT/Swin).
| Field | Type | Req. | Default | Description |
|---|---|---|---|---|
architecture | string | No | softmax | Classifier architecture (defaults to softmax) |
operate_on | string | Yes | — | Parent model name (must appear earlier in the list) |
operate_on_classes | list<int> | No | all parent classes | Only classify these parent class IDs |
Triton detector & classifier
For models served by NVIDIA Triton Inference Server (over gRPC). Triton models do not use onnx_file or architecture — the model definition lives on the Triton server.
| Field | Type | Req. | Default | Description |
|---|---|---|---|---|
triton.model_name | string | Yes | — | Model name on the Triton server |
triton.server_url | string | Yes | — | Triton gRPC endpoint (e.g. localhost:8001) |
triton.model_version | integer | No | latest | Specific model version |
triton.preprocess | object | No | see below | Preprocessing overrides |
Preprocessing overrides
| Field | Default | Description |
|---|---|---|
scale_factor | 0.00392156862 (1/255) | Input normalization scale |
color_format | RGB | RGB, BGR, or GRAY |
offsets | none | Channel mean offsets (e.g. [0.485, 0.456, 0.406]) |
maintain_aspect_ratio | 0 | 1 to maintain aspect ratio during resize |
symmetric_padding | 0 | 1 to use symmetric padding |
Tracker
Assigns persistent IDs to detected objects across frames. Add it as an entry in the models list; its position determines where tracking occurs in the chain. Only one tracker is allowed per pipeline.
# Option A — built-in tracker type - type: "tracker" tracker_type: "NvSORT" # Option B — custom tracker config file - type: "tracker" config_path: "/path/to/custom_tracker.yml"
| Built-in type | Description |
|---|---|
IOU | Intersection-over-Union. Fast and lightweight. |
NvSORT | NVIDIA SORT. Good balance of speed and accuracy. |
NvDCF | Discriminative Correlation Filter. Most accurate, higher GPU usage. |
Optional fields: tracker-width (default 960), tracker-height (default 544). config_path overrides tracker_type.
Active classes & chaining rules
- Active classes — set
active_classes: [0, 2]on a detector, pose, or segmentation model to detect only specific class IDs (0-indexed line numbers in the label file). - At least one primary model (without
operate_on) is required in every pipeline. operate_onmust reference a model defined before it; classifiers must always haveoperate_on.- Supported chains:
detector → classifier,detector → detector,triton_detector → triton_classifier.
05 Outputs
Outputs are split into two categories. video holds visual renderers that produce a video stream: display, file, rtsp, rtmp. events holds data, metadata, and diagnostics that produce no video: kafka, webhook, fps_meter. You can define multiple outputs simultaneously across both categories.
outputs: width: 1280 height: 720 video: - type: "display" - type: "rtsp" url: "rtsp://localhost:8554/stream" events: - type: "kafka" broker: "kafka-host:9092" topic: "detections"
Output-level fields
| Field | Type | Default | Description |
|---|---|---|---|
width | integer | 1280 | Composited video width (pixels) |
height | integer | 720 | Composited video height (pixels) |
video | list | — | Visual renderer definitions |
events | list | — | Data / metadata / diagnostics definitions |
video and events are each optional, but at least one output across the two is required. Each entry's type must belong to the category it appears under — placing (for example) kafka under video is a configuration error.display (video)
Live video window with overlays. Multiple streams are shown in an auto-tiled grid. No extra config.
fps_meter (events)
Measures pipeline throughput without producing video; FPS printed to stdout. No extra config.
File · RTSP · RTMP (video)
Write/stream video with overlays. All three accept mode (single = one tiled output, multi = per-stream), bitrate (default 4 000 000), and encoder. File/RTSP also accept codec (h264/h265); file adds container (mp4/mkv) and path; RTSP/RTMP use url.
# File — per-stream output - type: "file" mode: "multi" codec: "h264" container: "mp4" bitrate: 4000000 encoder: "gpu" streams: - { source_id: 0, path: "/recordings/cam0.mp4" } - { source_id: 1, path: "/recordings/cam1.mp4" }
codec field needed).Kafka (events)
Sends per-frame detection results as JSON messages to a Kafka topic — see Event message format for the payload schema.
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
broker | string | Yes | — | Kafka broker address (host:port) |
topic | string | Yes | — | Kafka topic name |
proto_lib | string | No | DeepStream default | Kafka protocol adapter library path |
Not affected by multi-stream modes — each message carries a source_id identifying which stream the frame came from. Bounding box coordinates are scaled from the source frame resolution into the configured outputs.width × outputs.height, so they match the pipeline's output resolution rather than the raw input size.
Webhook (events)
POSTs the same per-frame detection JSON to an HTTP endpoint. Messages are accumulated into batches and sent as a JSON array. Network I/O runs on a background thread, so a slow or unreachable endpoint never stalls the pipeline — the queue drops oldest-first when full.
- type: "webhook" url: "http://127.0.0.1:8000/detections" batch_size: 10 timeout: 5.0 frame_interval: 1 max_queue_size: 1000
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
url | string | Yes | — | HTTP endpoint the batches are POSTed to |
batch_size | integer | No | 10 | Messages accumulated per POST (a JSON array) |
timeout | number | No | 5.0 | POST request timeout in seconds |
frame_interval | integer | No | 1 | Emit every Nth frame (1 = every frame) |
max_queue_size | integer | No | 1000 | Max queued messages before oldest are dropped |
Like Kafka, the webhook output taps the batched buffer, so each message carries its own source_id, and bounding boxes are scaled to the configured outputs.width × outputs.height.
Encoder options
| Value | H264 encoder | H265 encoder | Description |
|---|---|---|---|
gpu (default) | nvv4l2h264enc | nvv4l2h265enc | NVIDIA hardware encoder |
cpu | x264enc | x265enc | Software encoder |
Multi-stream behavior
| Output | single mode | multi mode |
|---|---|---|
display | Tiled grid (always) | N/A |
file | One tiled file | One file per stream |
rtsp | One tiled RTSP stream | One RTSP stream per input |
rtmp | One tiled RTMP stream | One RTMP stream per input |
kafka | All frames to one topic | N/A (includes source_id) |
webhook | All frames to one endpoint | N/A (includes source_id) |
fps_meter | Measures overall FPS | N/A |
Tiling auto-arranges inputs in a grid (2 streams = 1×2, 4 = 2×2, 6 = 2×3). With mode: "multi", the streams list must have one entry per input stream, and each source_id must match a valid input stream.
06 Event message format
The two event outputs — kafka and webhook, configured under outputs.events — emit the same per-frame JSON schema. Each message covers one frame and contains all detected objects. They differ only in transport: kafka publishes one JSON message per frame to the configured topic, while webhook POSTs a JSON array of these per-frame messages (batched by batch_size) to the configured URL.
Detection-only message
{
"version": "1.0",
"source_id": 0,
"frame_id": 180,
"timestamp": "2026-01-29T16:39:38.066Z",
"objects": [
{
"class_id": 0,
"label": "car",
"confidence": 0.93,
"bbox": { "left": 384.89, "top": 321.08, "width": 16.56, "height": 16.64 },
"tracking_id": 19
}
]
}
Detection + classification message
When a classifier runs on an object, that object gains a classifications array:
{
"version": "1.0",
"source_id": 0,
"frame_id": 180,
"timestamp": "2026-01-29T16:39:38.066Z",
"objects": [
{
"class_id": 0,
"label": "car",
"confidence": 0.93,
"bbox": { "left": 384.89, "top": 321.08, "width": 16.56, "height": 16.64 },
"tracking_id": 19,
"classifications": [
{ "classifier_id": 2, "label": "silver", "confidence": 0.88 },
{ "classifier_id": 3, "label": "sedan", "confidence": 0.76 }
]
}
]
}
Fields
| Field | Type | Description |
|---|---|---|
version | string | Message schema version (currently 1.0) |
source_id | integer | Input stream index this frame belongs to |
frame_id | integer | Frame number since pipeline start |
timestamp | string | RFC 3339 wall-clock timestamp |
objects | array | Detected objects in this frame |
objects[].class_id | integer | Model output class ID |
objects[].label | string | Class name from the model's label file |
objects[].confidence | float | Detection confidence (0.0–1.0) |
objects[].bbox | object | Bounding box: left, top, width, height (pixels), scaled to the configured outputs.width × outputs.height |
objects[].tracking_id | integer | Tracker-assigned ID (−1 if no tracker) |
objects[].classifications | array | Classification results for this object. Omitted entirely for objects that no classifier ran on. |
…[].classifier_id | integer | Unique component ID of the classifier that produced this result |
…[].label | string | Predicted class name from the classifier's label file |
…[].confidence | float | Classification confidence (0.0–1.0) |
classifier_id to tell them apart.07 Complete examples
Basic object detection
pipeline: name: "Object Detection" streams: - uri: "file:///opt/nvidia/deepstream/deepstream/samples/streams/sample_1080p_h264.mp4" source_id: 0 models: - name: "yolo-detector" type: "detector" architecture: "yolo11" onnx_file: /path/to/model.onnx label_file: /path/to/labels.txt outputs: width: 1280 height: 720 video: - type: "display"
Detector + tracker + classifier chain
Detect vehicles, track them, then classify their color.
models: - name: "vehicle-detector" # primary detector type: "detector" architecture: "yolo11" onnx_file: /path/to/vehicle_model.onnx label_file: /path/to/vehicle_labels.txt active_classes: [0, 2] - type: "tracker" # tracker between detector and classifier tracker_type: "IOU" - name: "color-classifier" # secondary classifier type: "classifier" onnx_file: /path/to/color_model.onnx label_file: /path/to/color_labels.txt operate_on: "vehicle-detector" operate_on_classes: [0, 2] outputs: width: 1280 height: 720 video: - type: "display"
Kafka analytics (no video output)
models: - name: "yolo-detector" type: "detector" architecture: "yolo11" onnx_file: /path/to/model.onnx label_file: /path/to/labels.txt - type: "tracker" tracker_type: "NvSORT" outputs: width: 1920 height: 1080 events: - type: "fps_meter" - type: "kafka" broker: "kafka-host:9092" topic: "detections"
Webhook events alongside a live display
outputs: width: 1280 height: 720 video: - type: "display" events: - type: "webhook" url: "http://127.0.0.1:8000/detections" batch_size: 10 frame_interval: 1
Multi-stream with per-stream RTSP outputs
streams: - uri: "rtsp://camera1/live" source_id: 0 - uri: "rtsp://camera2/live" source_id: 1 models: - name: "yolo-detector" type: "detector" architecture: "yolo11" onnx_file: /path/to/model.onnx label_file: /path/to/labels.txt - type: "tracker" tracker_type: "NvSORT" outputs: width: 1280 height: 720 video: - type: "display" - type: "rtsp" mode: "multi" codec: "h264" bitrate: 4000000 streams: - { source_id: 0, url: "rtsp://localhost:8554/cam0" } - { source_id: 1, url: "rtsp://localhost:8554/cam1" }
Triton detector + classifier chain
models: - name: "triton-detector" type: "triton_detector" triton: model_name: "detector_model" server_url: "localhost:8001" label_file: /path/to/labels.txt - type: "tracker" tracker_type: "IOU" - name: "triton-classifier" type: "triton_classifier" triton: model_name: "classifier_model" server_url: "localhost:8001" label_file: /path/to/class_labels.txt operate_on: "triton-detector" operate_on_classes: [0, 2] outputs: width: 1280 height: 720 video: - type: "display"
Additional ready-to-run configs (pose estimation, instance segmentation, tiled RTSP, standalone Triton detector) follow the same structure — swap the model type/architecture and the output block.