Use PyNvCodec for true zero-copy GPU video decode
Some checks are pending
GPU Worker CI/CD / test (push) Waiting to run
GPU Worker CI/CD / deploy (push) Blocked by required conditions

Replace decord (CPU-only pip package) with PyNvCodec which provides
direct NVDEC access. Frames decode straight to GPU memory without
any CPU transfer, eliminating the memory bandwidth bottleneck.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
giles
2026-02-04 01:47:03 +00:00
parent 771fb8cebc
commit b7e3827fa2
2 changed files with 120 additions and 66 deletions

View File

@@ -26,9 +26,9 @@ RUN pip install --no-cache-dir -r requirements.txt
# Install GPU-specific dependencies (CuPy for CUDA 12.x)
RUN pip install --no-cache-dir cupy-cuda12x
# Install decord for GPU-accelerated video decoding (keeps frames on GPU)
# This avoids CPU<->GPU memory transfers during video decode
RUN pip install --no-cache-dir decord
# Install PyNvCodec for true GPU-native video decoding (NVDEC)
# Frames decode directly to GPU memory - zero CPU transfer
RUN pip install --no-cache-dir PyNvCodec
# Copy application
COPY . .