Skip to content

vad : add download-vad-model scripts #3149

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
May 14, 2025

Conversation

danbev
Copy link
Member

@danbev danbev commented May 13, 2025

This commit adds a script to download VAD models.

This currently only contains a shell script for linux to see if this is the correct approach with regards how to handle the models in huggingface and a similar script for windows will be added later.

Refs: #3146


I've created a VAD collection. But I opted to only create a single model named whisper-vad similar to what is currently done for the whisper.cpp models. If this is the right way to go I'll also add a script for windows.

Usage example:

$ ./models/download-vad-model.sh
Usage: ./models/download-vad-model.sh <model> [models_path]

Available models:
  silero-v5.1.2

Linux example:

$ ./models/download-vad-model.sh silero-v5.1.2
Downloading ggml model silero-v5.1.2 from 'https://huggingface.co/ggml-org/whisper-vad' ...
ggml-silero-v5.1.2.bin  100%[============================>] 864.35K  4.01MB/s    in 0.2s
Done! Model 'silero-v5.1.2' saved in '/Users/danbev/work/ai/whisper.cpp/models/ggml-silero-v5.1.2.bin'
You can now use it like this:

  $ ./build/bin/whisper-cli -vm /Users/danbev/work/ai/whisper.cpp/models/ggml-silero-v5.1.2.bin --vad -f samples/jfk.wav -m models/ggml-base.en.bin

Windows example:

> .\models\download-vad-model.cmd silero-v5.1.2
Downloading vad model silero-v5.1.2...                                                                                                                                                                           Done! Model silero-v5.1.2 saved in C:\Users\danie\work\ai\whisper.cpp\ggml-silero-v5.1.2.bin
You can now use it like this:
C:\Users\danie\work\ai\whisper.cpp\build\bin\Release\whisper-cli.exe -vm C:\Users\danie\work\ai\whisper.cpp\ggml-silero-v5.1.2.bin --vad -m models/ggml-base.en.bin -f samples\jfk.wav

danbev added 2 commits May 13, 2025 13:09
This commit adds a script to download VAD models.

This currently only contains a shell script for linux to see if this is
the correct approach with regards how to handle the models in
huggingface and a similar script for windows will be added later.

Refs: ggml-org#3146
@danbev danbev marked this pull request as ready for review May 14, 2025 06:18
@danbev danbev requested a review from ggerganov May 14, 2025 06:18
@danbev danbev merged commit 96d791a into ggml-org:master May 14, 2025
@itsthisjustin
Copy link

Any idea how to get this working for the Swift package?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants