Go API and GPU workers for Anime Upscaling — video2x + FFmpeg job orchestration
3.4K
Go HTTP API for Anime Upscaling, a self-hosted app for anime video restoration. This image does the actual work: it orchestrates video2x and FFmpeg subprocesses on your GPU and streams progress back to the dashboard.
Pair it with the dashboard —
ivanmicai/anime-upscaling-app —
which is the only container you publish a port for.
Everything stays on your machine — no cloud, no telemetry, no per-minute pricing.
Website: https://ivanmicai.github.io/anime-upscaling/
Four operations, usable on their own or chained into a saved pipeline:
| Operation | What it does |
|---|---|
upscale | Runs video2x with the chosen processor, model and scale. |
interpolate | Runs RIFE to multiply the frame rate. |
optimize | Re-encodes with the chosen codec, CRF preset and audio settings. |
integrity check | Probes the file with FFmpeg to confirm it decodes end to end. |
Bundled model families: RealESRGAN, Anime4K v4 (libplacebo shaders), RealCUGAN,
and the full RIFE line through rife-v4.26.
It also runs a GPU health monitor that detects a wedged NVIDIA driver, and two independent worker queues — one for GPU work, one for FFmpeg — so re-encodes do not sit behind upscales.
API_PORT (default 4751) — keep it on the internal Compose networklinux/amd64 (the video2x base is amd64-only)services:
api:
image: ivanmicai/anime-upscaling-api:latest
container_name: anime-upscaling-api
environment:
API_PORT: 4751
PROCESS_DIR: /data
GPU_COUNT: 1
STREAMS_PER_GPU: 1
FFMPEG_STREAMS: 1
expose: ["4751"]
volumes:
- ./data:/data
restart: unless-stopped
deploy:
resources:
reservations:
devices:
- driver: nvidia
count: 1
capabilities: [gpu]
web:
image: ivanmicai/anime-upscaling-app:latest
container_name: anime-upscaling-app
environment:
PORT: 4750
API_URL: http://api:4751
PROCESS_DIR: /data
AUTH_PASSWORD: replace-this-password
AUTH_SECRET: replace-with-openssl-rand-hex-32
ports:
- "4750:4750"
volumes:
- ./data:/data:ro
depends_on: [api]
restart: unless-stopped
mkdir -p data/input data/output data/optimized data/interpolated data/temp
docker compose up -d
The GPU reservation needs the NVIDIA Container Toolkit on the host. Drop it to run on CPU.
Or clone the repository and run make quickstart, which generates the secrets, creates the
folders and starts both containers for you.
| Variable | Default | Description |
|---|---|---|
API_PORT | 4751 | Port the API listens on. |
PROCESS_DIR | /data | Container path where the media tree is mounted. |
GPU_COUNT | 1 | Number of GPU slots exposed to the worker queue. |
STREAMS_PER_GPU | 1 | Concurrent video2x streams per GPU. |
FFMPEG_STREAMS | 1 | Concurrent FFmpeg workers. On automatic thread count, each encode gets the host's core count divided by this value. |
GPU_VENDOR | empty | Hardware encoder for optimize jobs: nvidia, amd, intel, or empty for software encoding. |
Mount the media tree read-write here — this is the container that writes the output.
| Tag | Meaning |
|---|---|
latest | Most recent release |
X.Y.Z | Exact release, matching the GitHub release |
X.Y | Latest patch of that minor |
X | Latest release of that major |
Keep this image and anime-upscaling-app on the same tag — they are released together.
Do not publish this port. The API has no authentication of its own: the login gate lives in the dashboard, and the API is meant to be reachable only from the internal Compose network.
Content type
Image
Digest
sha256:226959a59…
Size
1.9 GB
Last updated
about 2 months ago
docker pull ivanmicai/anime-upscaling-api