From 17743dfdcfcdd5026911da6bdf7f619cdaffd2c6 Mon Sep 17 00:00:00 2001 From: ginnoir Date: Sun, 18 Oct 2026 19:39:31 -0500 Subject: [PATCH] feat(media): run Storyteller whisper on the P100 (CUDA 12.9 image) Switch storyteller to the amd64-cuda-12.9.0 image with the P100 via CDI. Tested on a 2-min clip: 3.9 s on GPU vs 25 s on the CPU build. The whisper build lacks sm_60 kernels, so persist the PTX JIT cache under /data. CUDA images are SHA-tagged only, so pin the tag and exclude from Watchtower. Co-Authored-By: Claude Opus 5.5 --- stacks/media/BOOKS.md | 2 +- stacks/media/docker-compose.yml | 24 ++++++++++++++---------- 2 files changed, 15 insertions(+), 11 deletions(-) diff --git a/stacks/media/BOOKS.md b/stacks/media/BOOKS.md index 36b5ff4..f752491 100644 --- a/stacks/media/BOOKS.md +++ b/stacks/media/BOOKS.md @@ -65,5 +65,5 @@ sudo chown -R 1000:1000 /config/chaptarr /config/calibre-web-automated /config/a ## Notes - `STORYTELLER_SECRET_KEY` is in `stack.env` (`secrets.token_hex(64)`). If you rotate it, every Storyteller session is logged out. -- GPU: the `deploy:` block for the P100s is commented out in compose. When you turn it on, check upstream's GPU Acceleration docs for the CUDA image tag. +- GPU: Storyteller runs the CUDA 12.9 image on the P100 (`nvidia.com/gpu=0`, CDI). Upstream only tags CUDA images by commit SHA, so the tag is pinned and Watchtower is off. To bump it, pick a newer SHA from the registry's `amd64-cuda-12.9.0` repository. Don't use the CUDA 13.x images: they drop Pascal. The whisper build has no sm_60 kernels, so the first GPU run JIT-compiles PTX (~60 s). `CUDA_CACHE_PATH=/data/.nv-compute-cache` keeps that cache across restarts. - Chaptarr is young and runs on `:latest` with Watchtower. If an update breaks it, pin a tag and add `com.centurylabs.watchtower.enable=false`. diff --git a/stacks/media/docker-compose.yml b/stacks/media/docker-compose.yml index b0c6d7e..97579e4 100644 --- a/stacks/media/docker-compose.yml +++ b/stacks/media/docker-compose.yml @@ -289,26 +289,30 @@ services: storyteller: container_name: storyteller - image: registry.gitlab.com/storyteller-platform/storyteller:latest + # CUDA 12.9 build so whisper runs on the P100 (~6x the CPU build). CUDA 13.x + # images drop Pascal. Upstream publishes CUDA images only as commit-SHA tags + # (no :latest), so this is pinned and out of Watchtower; bump the tag by hand + # from the registry's amd64-cuda-12.9.0 repository. + image: registry.gitlab.com/storyteller-platform/storyteller/amd64-cuda-12.9.0:67260c54 restart: unless-stopped + labels: + - "com.centurylabs.watchtower.enable=false" networks: [media, edge] env_file: - stack.env # STORYTELLER_SECRET_KEY lives here + devices: + - nvidia.com/gpu=0 + environment: + # The whisper build has no sm_60 kernels, so the P100 JIT-compiles PTX on + # first use (~60 s). Persist the JIT cache so that only happens once. + - CUDA_CACHE_PATH=/data/.nv-compute-cache + - CUDA_CACHE_MAXSIZE=4294967296 volumes: - /storage1/labdata/storyteller:/data - /storage1/Media/Books:/libraries/books:ro - /storage1/Media/Audiobooks:/libraries/audiobooks:ro ports: - "8001:8001" - # Whisper runs on CPU until the P100s land. Then add (and check upstream's - # GPU Acceleration docs for the CUDA image tag): - # deploy: - # resources: - # reservations: - # devices: - # - driver: nvidia - # count: 1 - # capabilities: [gpu] networks: media: