npx skills add ...
npx skills add nvidia/deepstream --skill amc-setup-calibration-stack
Launch AutoMagicCalib microservice and web UI from NGC release images via Docker Compose. Use when user says 'deploy auto calibration', 'launch auto calibration', 'launch AMC', 'start MS+UI', or 'set up auto-magic-calib'. Requires NGC API key.
npx skills add nvidia/deepstream --skill amc-setup-calibration-stack
Set up the AutoMagicCalib microservice and UI from release containers: resolve an AMC checkout, authenticate to NGC, optionally download VGGT, configure Docker Compose, launch services, and verify readiness.
auto-magic-calib repo on disk. Step 0b resolves the current repo, DeepStream tools/auto-magic-calib, DEEPSTREAM_REPO_ROOT, or ~/auto-magic-calib; otherwise it asks before cloning https://github.com/NVIDIA-AI-IOT/auto-magic-calib.sudo; verify with docker ps before continuing.docker group. Ask the user to run:
docker ps works before continuing.Agent note: If
docker pscannot be run from within the agent sandbox, ask the user to confirm it works (e.g. "Can you confirmdocker psruns without sudo?") before proceeding.
The skill needs AMC repo assets (compose/, sample data, and models/). Resolve an existing checkout first; ask before cloning into ~/auto-magic-calib.
Agent note: never clone silently. Prefer initialized DeepStream
tools/auto-magic-calib; do not clone over that submodule path. If it exists but is empty, ask the user to rungit submodule update --init tools/auto-magic-calib. Honour an alternate AMC path if provided.
On a fresh system, pip and python3-venv may not be available. Install them first:
Note: Skip this step if a venv with
hfalready exists (checkvenv/bin/hfin the repo root or~/venv/amc/bin/hf).
Ask the user for their NGC API key using the host's question mechanism; if none is available, ask in chat and wait. Then run:
To download VGGT: ask the user to accept the license at https://huggingface.co/facebook/VGGT-1B-Commercial and provide a read token from https://huggingface.co/settings/tokens using the host's question mechanism. Pass it through HF_TOKEN so it is not exposed in ps output:
Important: Download BEFORE setting
chown 1000:1000on the models directory — the current user needs write access during download. Set permissions in Step 4 after download completes.
The Compose environment file controls ports and paths. Update it before launching:
Important: HOST_IP must be the machine's network IP (not localhost) so the UI container can reach the backend from a browser.
Optional: set VGGT_MODEL_PATH only if the VGGT model is mounted at a non-default container path; default is /tmp/vggt_model/vggt_1B_commercial.pt inside the MS container.
Optional for RTSP calibration: use skills/amc-run-rtsp-calibration/SKILL.md after launch. That skill verifies VIOS reachability and, when needed, relaunches the microservice with a temporary compose override that exports VIOS_BASE_URL without changing checked-in compose files.
The containers run as UID/GID 1000. The projects and models directories must be owned by this UID for containers to read/write properly:
Before pulling, fail fast if the NGC key authenticated in Step 1 but cannot actually access a release image — otherwise docker compose up aborts partway with a 401/403 after some work is already done.
The exact image tags change by release; read them from the active compose files instead of hardcoding a version.
docker compose ps shows MS and UI containers Up; MS should be healthy./v1/ready returns code:0 and Step 6 prints the microservice and UI URLs.http://<HOST_IP>:<AUTO_MAGIC_CALIB_UI_PORT> works.$REPO_ROOT/projects/.| Issue | Fix |
|---|---|
| Docker permission denied | Ask the user to run sudo usermod -aG docker $USER && newgrp docker, then retry docker ps. |
docker login rejected | Ask for a current NGC key and log in again. |
| Required image inaccessible | The key lacks image namespace access; ask for a key with access, then retry Step 1 and Step 5. |
python3 -m venv, pip, or hf missing | Install python3-venv/python3-pip; the HF binary is named hf. |
| VGGT permission error | Download VGGT before chown 1000:1000; to recover, restore user ownership of models/ and re-download. |
| Port in use | Pick a free MS port in 8000-8009 and UI port in 5000-5009, then update the Compose environment file. |
| Readiness timeout or exited container | Run cd $REPO_ROOT/compose && docker compose ps and inspect docker compose logs auto-magic-calib-ms. |
| Project/model permission denied | Re-run Step 4 for projects/ or models/ only. |
| UI cannot reach backend | Verify HOST_IP in the Compose environment file is the machine network IP, not localhost. |
| GPU unavailable | Verify NVIDIA runtime with docker run --rm --runtime=nvidia --gpus all ubuntu:20.04 nvidia-smi. |
Common Fixes:
skills/amc-run-sample-calibration/SKILL.md - Sanity-check the running stack with the bundled sample datasetskills/amc-run-video-calibration/SKILL.md - Calibrate from your own pre-recorded MP4s via REST APIskills/amc-run-rtsp-calibration/SKILL.md - Calibrate from live RTSP streams through VIOS capture