Created
March 1, 2023 06:57
-
-
Save m1ndy/8dc51447300e6922619920ed192e324b to your computer and use it in GitHub Desktop.
Auto-transcribe all mp4 video files in a folder with Whisper (running on MacOS with M1 Max, though this is CPU based model)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
for mp4 in *.mp4 | |
do | |
echo "Processing $mp4" | |
ffmpeg -i $mp4 -ar 16000 -ac 1 -c:a pcm_s16le $mp4.wav | |
~/Documents/Dev/whisper.cpp-1.2.1/main -m ~/Documents/Dev/whisper.cpp-1.2.1/models/ggml-large.bin -osrt -t 8 -f "$mp4.wav" | |
rm $mp4.wav | |
done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment