metadata
license: mit
Create dataset from video
This project contains a script based on an OpenAI model that will help you automatically create your own text dataset from video files or podcasts.
Under the hood, it uses the powerful Whisper-Large-V3 model, which can accept the following audio and video formats: .mp3, .m4a, .wav, .mp4, .mkv, and .webm.
(We recommend using the .mp3 and .mp4 formats for best compatibility and performance.)
Installation and Run
- Make sure you have Python 3.9 or later installed.
- Install FFmpeg (required, as extracting audio from video won't work without it).
- On Windows, open a command prompt and enter:
winget install ffmpeg
- Install PyTorch with support for your graphics card (CUDA) for faster recognition:
pip install torch torchvision torchaudio --index-url [https://download.pytorch.org/whl/cu121](https://download.pytorch.org/whl/cu121)
4. Install the necessary libraries for working with the model:
pip install transformers accelerate
5. Create two empty folders in the script folder:
* `Videos` (place your videos here)
* `model` (for local storage of Whisper weights).
6. Run the script. All processed dialogs will be automatically saved to a clean .txt file.
**⚠️ Licensing Information:**
* The code portion of this project (automation scripts) is distributed under the MIT license.
* The Whisper neural network model itself, developed by OpenAI, is distributed under the Apache 2.0 license.