Baike.dev
All toolsOnline toolsAI codingTrendingOpen sourceNewsSubmit
Log in
< Back to tools
C

cosmo-edge

> 包管理
Open source

Production-grade C++ edge AI engine for video analytics with visual pipeline orchestration, on-device VLM, and real-time OSD.

342 stars0 likes3 views
WebsiteGitHub

About

Production-grade C++ edge AI engine for video analytics with visual pipeline orchestration, on-device VLM, and real-time OSD.


CosmoEdge goes beyond model serving with a complete application layer for model import, visual orchestration, alarms, and event delivery. The core engine and console in this repository are released under Apache-2.0; certified hardware, commercial preset models, and Model Guard distribution protection have separate boundaries.

CosmoEdge 1.1

  • Multi-platform release: BM1688, CV186X, RK3576, and RV1126B use the same video-ingest, orchestration, event, and observability workflow with target-specific model artifacts.
  • Public benchmark pack: the CosmoEdge 1.1 multi-platform report covers single workloads, concurrent mixed workloads, a controlled 72-hour dual-CV profile, and validated VLM performance with sanitized, traceable benchmark artifacts.
  • Rockchip release platforms: RK3576 and RV1126B both include cross-build, board operation, RKNN inference, and MPP/RGA media paths in the same v1.1 release tier; their models and measured evidence remain bound separately.
  • Sophon model handling: chip-aware validation supports target-specific .nn artifacts for BM1688 and CV186X. The benchmark records an exact Open-package and running-engine binding for both reference devices.
  • RKNN data path: targeted DMA-BUF-to-RGA input, persistent bound-input, native quantized output, and direct YOLOv8 tensor decoding paths with explicit fallbacks.
  • Agent-assisted development: a repository-guided path for handing model porting, integration, and UI tasks to the coding agent you already use and receiving verifiable deliverables.
  • Model Guard 2.3: protects commercial preset-model distribution in Sophon Protected packages. Open and Protected expose the same application features, with no SKU-gated software functionality; they differ in model encryption and device-provisioning tooling.
  • macOS Docker Preview: an isolated linux/amd64 path for one local-video workflow on Apple Silicon, validated through multiple end-to-end lab rounds.
  • Benchmark scope: VLM figures are exact short-run gate boundaries for the recorded protocol. The separate 72-hour test covers the listed fixed-channel profiles using controlled local-loop input; detailed conditions are documented in the benchmark report.

Choose a Platform

CosmoEdge provides one engine architecture and orchestration experience, but each build selects one inference backend and uses models generated for that target platform.

Platform Status Runtime / model artifact Current scope and evidence
Sophon BM1688 v1.1 supported / primary; VLM supported BMRT / .nn Validated VLM at 0.1 FPS/ch through 6 channels, plus v1.1 workload evidence
Rockchip RK3576 / RV1126B v1.1 supported; RK3576 VLM supported RKNN / target-specific .rknn; RKLLM on RK3576 RK3576 validates VLM at 0.1 FPS/ch through 4 channels; RV1126B VLM is outside this release claim. Other platform-specific results remain separate in the v1.1 report
Sophon CV186X v1.1 supported; VLM supported BMRT / target-specific .nn Validated VLM at 0.1 FPS/ch through 6 channels, plus model-import and workload evidence in the v1.1 benchmark
x86 Linux / Windows; Apple Silicon macOS Linux / Windows supported; macOS Preview ONNX Runtime / .onnx Mac uses amd64 emulation for one local-video developer workflow, not native performance evidence
Sophon BM1684X Planned — Not part of the current release scope

Quick Start

Try locally on x86

No edge hardware is required. The x86 mode uses the same UI and workflow with lower throughput than an NPU deployment.

bash
# 1. Clone
git clone https://github.com/cosmo-wander-ai/cosmo-edge.git
cd cosmo-edge

# 2. Start on Linux
sudo docker compose -f docker-compose.x86.yml up -d --build
# Windows: docker compose -f docker-compose.x86.windows.yml up -d --build

# 3. Open http://localhost:8080

Apple Silicon macOS uses a separate amd64-emulation Preview path:

bash
./scripts/macos-docker-preview.sh doctor
./scripts/macos-docker-preview.sh up
./scripts/macos-docker-preview.sh status
# Open http://127.0.0.1:8080

The Mac Preview provides a local, single-video workflow under linux/amd64 emulation on Apple Silicon. Read the full macOS Docker Preview scope first.

After startup, use the Scenario Configuration tutorial to create your first AI detection task. Docker Compose V1 users can replace docker compose with docker-compose.

Build for Sophon

bash
git clone https://github.com/cosmo-wander-ai/cosmo-edge.git
cd cosmo-edge
# BM1688 (default when the chip model is omitted)
./scripts/docker-compose.sh -f docker-compose.sophon.yml run --rm cosmo-sophon-package --chip bm1688

# CV186X
./scripts/docker-compose.sh -f docker-compose.sophon.yml run --rm cosmo-sophon-package --chip cv186x

The wrapper selects the available Compose implementation and requests elevated Docker access only when required. The build selects the matching model resources without a model-path argument and exports each target independently under build_output/public-runtime//, together with TARGET_CHIP and SHA256SUMS.

The default Open package contains plaintext models and requires no device authorization. Verify the chip marker and checksum before deployment. The Build Guide is the authoritative build reference; follow the Deployment Guide for SSH installation, web upgrade, recovery, and post-reboot acceptance.

Build for Rockchip

bash
./scripts/docker-compose.sh -f docker-compose.rockchip.yml pull cosmo-rockchip-package

# RK3576 (uses the tracked RK3576 model resources)
COSMO_TARGET_CHIP=rk3576 ./scripts/docker-compose.sh \
  -f docker-compose.rockchip.yml run --rm cosmo-rockchip-package
ls -lh build_output/rk3576/

# RV1126B (requires a prepared target model overlay)
COSMO_TARGET_CHIP=rv1126b ./scripts/docker-compose.sh \
  -f docker-compose.rockchip.yml run --rm cosmo-rockchip-package
ls -lh build_output/rv1126b/

One digest-pinned Rockchip builder shares the compiler and RKNN SDK while selecting an isolated MPP/RGA profile for each chip. RKLLM v1.3.0 is required and packaged only for RK3576. Target markers, media-profile identities, and checksums are exported under build_output//. See the Build Guide and RK3576 integration guide for model and device-validation boundaries.

For CV186X, follow the CV186X Quick Start for package installation, model import, first-event verification, upgrade, and recovery boundaries.

What You Can Build

  • Real-time video analytics: detection, classification, tracking, zones, counters, OSD, and alarm snapshots.
  • Prompt-driven vision: VLM state judgment and GroundingDINO open-vocabulary detection alongside conventional CV pipelines.
  • Visual application workflows: connect models, rules, events, and output actions in the browser.
  • Edge integrations: operate managed tasks and deliver structured events through REST, WebSocket, MQTT, or HTTP webhooks.

Core Capabilities

Capability What it covers Go deeper
Native runtime C++17 engine for multi-channel media, inference scheduling, OSD, tasks, and events Architecture
Visual orchestration Browser-based pipeline composition, task binding, parameter validation, and live feedback Pipeline tutorial
Inference and media Platform backends for Sophon, RKNN, and x86; platform-specific builds and model artifacts Build Guide
VLM and DINO Prompt-based judgment, open-vocabulary detection, and optional VLM review before a detection alarm is reported VLM Guide
Operations and integration Model management, alarms, event history, REST, WebSocket, MQTT, and webhooks API Overview
Model onboarding and protection Model conversion, import, validation, and the Open/Protected distribution boundary Model Porting Guide

▶ Watch: compose a complete visual pipeline

▶ Watch: GroundingDINO and VLM visual workflows

Agent-Assisted Development

Already have a model-porting, integration, or UI task? Give your usual coding agent the business goal, available materials, target device or test environment, and acceptance criteria. The repository provides task entry points, examples, checks, and evidence boundaries so the result can include importable artifacts, scoped code changes, and a verifiable conclusion.

Start with Agent-Assisted Development, then use the Model Porting Guide or Contributor Guide for the task at hand.

Validation

CosmoEdge 1.1 multi-platform performance report

The v1.1 report covers BM1688, CV186X, RK3576, and RV1126B. It includes 49 independent small-model case reports for person detection, no-safety-helmet analysis, and a concurrent mixed workload at 5 FPS per business task, a controlled 72-hour dual-CV configured profile, and validated VLM performance for BM1688, CV186X, and RK3576.

  • English benchmark index
  • 中文基准报告索引
  • English primary report (rendered documentation site)
  • 72-hour dual-CV report (rendered documentation site)
  • Methodology and reproduction

The short-run capacity refresh uses source commit 89c73a7464a81ef378686447d7c1eeb88b988455, tree 6857fbcce72c7af64e6cb23a27e66a405e9df9af, one fixed 1080p24 input, 30-second steps, and the gates recorded in the release manifest. The 72-hour observation uses source commit 44209759f450e96cda265acfa8bc6d17a1138888, tree 5cbdefeaefaf642407356c22c271ccc7d57935b0, and the same controlled input.

Platform 72-hour configured channels Task bindings Sample coverage Min / avg FPS Result
BM1688 8 16 4316 / 4320 4.68 / 5.086 PASS
CV186X 8 16 4316 / 4320 4.54 / 5.085 PASS
RK3576 8 16 4316 / 4320 5.00 / 5.098 PASS
RV1126B 4 8 4316 / 4320 4.85 / 5.230 PASS

These results describe the tested fixed-channel profiles under controlled local-loop input; they are not maximum-capacity or RTSP-resilience measurements. Execution details are documented in the methodology.

Each channel concurrently runs two business tasks across three model stages: person detection has one detector stage, while no-safety-helmet analysis has a detector followed by a classifier.

Platform Workload per channel Model stages/ch Target FPS/task Passing channels Business-task bindings
BM1688 Person detection + no-safety-helmet analysis 3 5 ≥16 32/

Issues· 0 open

View all issuesOpen on GitHub

No open issues yet, or sync has not completed.

> Tags

Cbm1688computer-visioncpp17edge-ai

No comments yet. Be the first to share.

> Details

PublishedAug 1, 2026
UpdatedSep 18, 2026
Category包管理
PricingOpen source

> Related tools

N
npm
Node.js 默认包管理器
P
pnpm
高效节省磁盘的 Node 包管理器
I
is-gif
Check if a Buffer/Uint8Array is a GIF image