38 lines
2.1 KiB
Markdown
38 lines
2.1 KiB
Markdown
# transcriber
|
|
|
|
[](https://img.shields.io/github/v/release/dscoular/transcriber)
|
|
[](https://github.com/dscoular/transcriber/actions/workflows/main.yml?query=branch%3Amain)
|
|
[](https://img.shields.io/github/commit-activity/m/dscoular/transcriber)
|
|
[](https://img.shields.io/github/license/dscoular/transcriber)
|
|
|
|
|
|
## Description
|
|
|
|
This **`transcribe`** script is intended to be used, primarily, with the [Bonsai Tutorials](https://hub.openingdesign.com/OpeningDesign/Bonsai_Tutorials#readme) video collection
|
|
to create SRT subtitle text files for the tutorial videos.
|
|
|
|
Since there were so many videos it became difficult to remember which one contained
|
|
a valuable explanation and exactly when in the video that explanation occurred.
|
|
|
|
I found the [OpenAI Whisper](https://github.com/openai/whisper) python library and set about using it to
|
|
transcribe the videos to SRT subtitle text files (thanks to the [pydub](https://github.com/jiaaro/pydub)
|
|
and [pysrt](https://github.com/byroot/pysrt) modules).
|
|
|
|
SRT subtitle text files are described by this Wikipedia entry:
|
|
|
|
- [SubRip](https://en.wikipedia.org/wiki/SubRip)
|
|
|
|
I used the [cookiecutter-uv](https://github.com/fpgmaas/cookiecutter-uv) project template to try to ensure that
|
|
I had the basis of a modern python project.
|
|
|
|
## Prerequisites
|
|
|
|
You can either:
|
|
|
|
1. Use python's [uv](https://docs.astral.sh/uv/) and **`make`** to manage the script's dependencies.
|
|
See the [🚀 Getting Started](getting-started.md) document for more details.
|
|
2. Use the included **`Dockerfile`** and the **`docker`** command to make use of this script.
|
|
See the [🚢 Using Docker](docker.md) document for more details.
|
|
|
|
***Notes***<br>
|
|
*Each matching video found in the target directory will have an `.srt` file created as a sibling. This makes it easy for video players to match the video with the subtitles.*
|