r/Python • • 2h ago

News I built a local YouTube-to-Shorts clipper in Python 3.11+ using FFmpeg and deterministic DSP heurist

Hey r/Python! I wanted a way to automatically turn long YouTube videos into vertical 9:16 clips without paying for LLM APIs or running heavy PyTorch models on an old laptop.

How Max Clipper works under the hood:

- Explainable Clip Picking: Uses deterministic DSP and statistical heuristics (hook, audio energy, pacing, heatmap) instead of black-box LLMs—same input always gives the exact same output.

- Low-Spec Optimization: Built and tested on a 4th-gen Intel i5 with 8GB RAM and no GPU. Uses a global render lock to prevent FFmpeg CPU starvation, stall-based timeouts, and -preset ultrafast on <= 4 cores.

- Packaging: One-command installers for Linux/macOS/Windows plus Docker support.

Source Code (MIT License): https://github.com/4hmed1/MaxClipper

Would love code review or feedback on the clip-scoring heuristics!

1 Upvotes

0 comments sorted by