← all repositories
YaoFANGUK/video-subtitle-extractor

OCR your hardsubs without calling a single API

A local-only tool that turns burned-in video subtitles into clean SRT files using deep learning, no cloud OCR required.

9.2k stars Python Computer VisionDomain Apps
video-subtitle-extractor
Velocity · 7d
+7.4
★ / day
Trend
steady
star history

What it does

Video-subtitle-extractor (VSE) is a GUI and CLI tool that pulls hard-coded subtitles out of video files and spits out SRT or plain text. It handles the full pipeline: keyframe extraction, text region detection, OCR, deduplication, and filtering out watermarks or station logos. It also pairs with a separate “subtitle remover” project if you want to erase the original hardsubs entirely.

The interesting bit

The whole thing runs locally on PaddlePaddle models — no Baidu, Alibaba, or any cloud OCR keys to beg for. The README is refreshingly honest about the trade-offs: “fast” mode may drop a few lines and typo here and there; “accurate” mode is frame-by-frame, nearly perfect, and “very slow.” The sweet spot is “auto,” which picks model size based on whether it detects a GPU.

Key highlights

  • Supports 87 languages including Chinese (simplified/traditional), English, Japanese, Korean, Arabic, and most major European languages
  • Three speed/accuracy tiers: fast, auto (recommended), and accurate
  • GPU acceleration via CUDA, DirectML, or ONNX; CPU fallback available
  • Batch processing for multiple videos with matching resolution and subtitle region
  • Custom text replacement/deletion via typoMap.json — useful for cleaning up watermarks or common OCR errors
  • Cross-platform: Windows, macOS, Linux

Caveats

  • Paths containing Chinese characters or spaces will “cause unknown errors” — the README warns this explicitly and repeatedly
  • NVIDIA 50-series cards need CUDA 12.8+, but Paddle 3.3.1 doesn’t support it yet; DirectML workaround suggested
  • ONNX path for macOS/AMD is marked “untested” and the maintainers ask you not to file issues about it

Verdict

Worth a look if you regularly need to archive, translate, or repurpose subtitled video and would rather not pipe your content through someone else’s API. Skip it if you need real-time processing or can’t tolerate the path-naming restrictions.

Frequently asked

What is YaoFANGUK/video-subtitle-extractor?
A local-only tool that turns burned-in video subtitles into clean SRT files using deep learning, no cloud OCR required.
Is video-subtitle-extractor open source?
Yes — YaoFANGUK/video-subtitle-extractor is open source, released under the Apache-2.0 license.
What language is video-subtitle-extractor written in?
YaoFANGUK/video-subtitle-extractor is primarily written in Python.
How popular is video-subtitle-extractor?
YaoFANGUK/video-subtitle-extractor has 9.2k stars on GitHub and is currently holding steady.
Where can I find video-subtitle-extractor?
YaoFANGUK/video-subtitle-extractor is on GitHub at https://github.com/YaoFANGUK/video-subtitle-extractor.

heatdrop uses Google Analytics to see which pages get read — nothing else. Your call. How we handle data.