简体中文 | English
Video-subtitle-extractor (VSE) is a free, open-source tool which can help you rip the hard-coded subtitles from videos and automatically generate corresponding srt files for each video. It includes the following implementations:

Features:
Usage:
Batch extraction: When opening files, choose multiple videos, ensure that every video's resolution and subtitle area remain consistent.
Remove watermark text/replace specific text:
If specific text needs to be deleted from generated .srt file, or specific text needs to be replaced, you can edit the
backend/configs/typoMap.jsonfile and add the content you want to replace or remove.
{
"l'm": "I'm",
"l just": "I just",
"Let'sqo": "Let's go",
"Iife": "life",
"威筋": "threat",
"性感荷官在线发牌": ""
}
In this way, you can replace all occurrences of "威筋" in the text with "threat" and delete all instances of the text "性感荷官在线发牌".
Download:
Windows executable (might be slow when initial start): vse.exe
Windows GPU version:vse_windows_gpu_v2.0.0.7z
Windows CPU version:vse_windows_cpu_v2.0.0.zip
MacOS:vse_macOS_CPU.dmg
Provide your suggestions to improve this project in ISSUES & DISCUSSION
Pre-built Package Comparison:
| Pre-built Package Name | Python | Paddle | Environment | Supported Compute Capability Range |
|---|---|---|---|---|
vse-windows-cpu.7z |
3.12 | 3.0.0 | No GPU, CPU only | Universal |
vse-windows-directml.7z |
3.12 | 3.0.0 | Windows without Nvidia GPU | Universal |
vse-windows-nvidia-cuda-10.2.7z |
3.11 | 2.5.2 | CUDA 10.2 | 3.0 – 7.5 |
vse-windows-nvidia-cuda-11.8.7z |
3.12 | 3.0.0 | CUDA 11.8 | 3.5 – 8.9 |
vse-windows-nvidia-cuda-12.6.7z |
3.12 | 3.0.0 | CUDA 12.6 | 5.0 – 9.0 |
NVIDIA provides a list of supported compute capabilities for each GPU model. You can refer to the following link: CUDA GPUs to check which CUDA version is compatible with your GPU.
NVIDIA 50 series graphics cards require CUDA 12.8.0 or above, but Paddle 3.0.0 does not support it yet, so it is recommended to use the DirectML universal version.
Recognition Mode Selection:
| Mode Name | GPU | OCR Model Size | Subtitle Detection Engine | Notes |
|---|---|---|---|---|
| Fast | Yes/No | Mini | VideoSubFinder | |
| Auto | Yes | Large | VideoSubFinder | Recommended |
| Auto | No | Mini | VideoSubFinder | Recommended |
| Precise | Yes/No | Large | VSE | Very slow |
The subtitle detection engine for both Windows/Linux environments is VideoSubFinder.

PS: can only run CLI version on Google Colab
Please ensure that you have installed Python 3.12+.
shell
brew install python@3.12shell
sudo apt update && sudo apt install python3.12 python3.12-venv python3.12-devIt is recommended to use a virtual environment to manage project dependencies to avoid conflicts with the system environment.
(1) Create and activate the virtual environment:
python -m venv videoEnv
videoEnv\\Scripts\\activate
source videoEnv/bin/activate
Change to the directory where your source code is located:
cd <source_code_directory>
For example, if your source code is in the
toolsfolder on the D drive and the folder name isvideo-subtitle-extractor, use:shell cd D:/tools/video-subtitle-extractor-main
This project supports four runtime modes: CUDA (NVIDIA GPU acceleration), CPU (no GPU), DirectML (AMD, Intel, and other GPUs/APUs), and ONNX.
Make sure your NVIDIA GPU driver supports the selected CUDA version.
Recommended CUDA 11.8, corresponding to cuDNN 8.6.0.
Install CUDA:
shell
wget https://developer.download.nvidia.com/compute/cuda/11.8.0/local_installers/cuda_11.8.0_520.61.05_linux.run
sudo sh cuda_11.8.0_520.61.05_linux.runCUDA is not supported on MacOS.
Install cuDNN (CUDA 11.8 corresponds to cuDNN 8.6.0):
Follow the installation guide in the NVIDIA official documentation.
Install PaddlePaddle GPU version (CUDA 11.8):
shell
pip install paddlepaddle-gpu==3.0.0 -i https://www.paddlepaddle.org.cn/packages/stable/cu118/
pip install -r requirements.txt
shell
pip install paddlepaddle==3.0.0 -i https://www.paddlepaddle.org.cn/packages/stable/cpu/
pip install -r requirements.txt
pip install -r requirements_directml.txt# Read documentation https://onnxruntime.ai/docs/execution-providers/ # Choose the appropriate execution backend based on your device, modify the dependencies in requirements_directml.txt accordingly.
# Example: # requirements_coreml.txt # paddle2onnx==1.3.1 # onnxruntime-coreml==1.13.1
pip install -r requirements_coreml.txt ```
shell
pip install paddlepaddle==3.0.0 -i https://www.paddlepaddle.org.cn/packages/stable/cpu/
pip install -r requirements.txtpython gui.py
python ./backend/main.py
Solution: If you are using a nvidia ampere architecture graphic card such as RTX 3050/3060/3070/3080, please use the latest PaddlePaddle version and CUDA 11.6 with cuDNN 8.2.1. Otherwise, check your which cuda and cudnn works with your GPU and then install them.
_lgeos = CDLL(os.path.join(sys.prefix, 'Library', 'bin', 'geos_c.dll'))
File "C:\Users\Flavi\anaconda3\envs\subEnv\lib\ctypes\__init__.py", line 364, in __init__
self._handle = _dlopen(self._name, mode)
OSError: [WinError 126] The specified module could not be found。
Solution:
1) Uninstall Shapely
pip uninstall Shapely -y
2) Reinstall Shapely via conda (make sure you have anaconda or miniconda installed)
conda install Shapely
Using Nuitka version 0.6.19, copy all the files of site-packages under the Lib folder of the conda virtual environment to the dependencies folder, and comment all codes relevant to subprocess of image.py under the paddle library dataset, and use the following packaging command:
python -m nuitka --standalone --mingw64 --include-data-dir=D:\vse\backend=backend --include-data-dir=D:\vse\dependencies=dependencies --nofollow-imports --windows-icon-from-ico=D:\vse\design\vse.ico --plugin-enable=tk-inter,multiprocessing --output-dir=out .\gui.py
Make a single .exe file, (pip install zstandard can compress the file):
python -m nuitka --standalone --windows-disable-console --mingw64 --lto no --include-data-dir=D:\vse\backend=backend --include-data-dir=D:\vse\dependencies=dependencies --nofollow-imports --windows-icon-from-ico=D:\vse\design\vse.ico --plugin-enable=tk-inter,multiprocessing --output-dir=out --onefile .\gui.py
$ claude mcp add video-subtitle-extractor \
-- python -m otcore.mcp_server <graph>