
This submission is a containerized video captioning pipeline built for the AMD Developer Hackathon (ACT II) Track 2. It takes a tasks.json file containing video URLs and requested caption styles, detects scenes, extracts and clips audio, transcribes speech, summarizes each scene using a vision-language model, and finally generates styled captions in formats such as formal, sarcastic, humorous tech, and humorous non-tech. The pipeline uses PySceneDetect for scene boundary detection, FFmpeg for audio extraction and clipping, OpenAI Whisper for speech-to-text transcription, and a local Ollama VLM (default gemma4:e2b) or Fireworks AI for scene understanding and caption generation. The Docker image is designed to run on AMD GPUs by default, using the ROCm 6.2 PyTorch wheel. It can also be rebuilt for NVIDIA CUDA or CPU-only targets via the TORCH_INDEX_URL build argument. A runtime fallback script detects the available GPU and can reinstall PyTorch automatically when TORCH_RUNTIME_FALLBACK=1 is set. The container bakes both the Whisper model and the Ollama VLM model into the image so no network access is required at runtime. For hackathon submission, set AUTO_RUN_PIPELINE=1 so the container processes the mounted input and writes results.json to the output directory before exiting. Configuration is fully environment-driven, with support for custom models, VLM providers, image resizing, input/output paths, and GPU backend selection.
13 Jul 2026