mirror of
https://github.com/k2-fsa/sherpa-onnx.git
synced 2026-11-10 21:11:03 +08:00
Add Java/Kotlin API and Android support for ten-vad (#2389)
This commit is contained in:
1 parent
fc2fc3d95d
commit
b376ad3a7c
36 files changed
+396
-47
No files matched your search
@@ -10,7 +10,7 @@ from a microphone.
|
||||
Usage:
|
||||
|
||||
|
||||
wget https://github.com/snakers4/silero-vad/raw/master/src/silero_vad/data/silero_vad.onnx
|
||||
wget https://github.com/k2-fsa/sherpa-onnx/releases/download/asr-models/silero_vad.onnx
|
||||
|
||||
./python-api-examples/simulate-streaming-sense-voice-microphone.py \
|
||||
--silero-vad-model=./silero_vad.onnx \
|
||||
|
||||
@@ -18,12 +18,12 @@ Note that `zh` means Chinese, while `en` means English.
|
||||
|
||||
(2) Download the VAD model
|
||||
Please visit
|
||||
https://github.com/snakers4/silero-vad/raw/master/src/silero_vad/data/silero_vad.onnx
|
||||
https://github.com/k2-fsa/sherpa-onnx/releases/download/asr-models/silero_vad.onnx
|
||||
to download silero_vad.onnx
|
||||
|
||||
For instance,
|
||||
|
||||
wget https://github.com/snakers4/silero-vad/raw/master/src/silero_vad/data/silero_vad.onnx
|
||||
wget https://github.com/k2-fsa/sherpa-onnx/releases/download/asr-models/silero_vad.onnx
|
||||
|
||||
(3) Run this script
|
||||
|
||||
|
||||
@@ -40,12 +40,12 @@ Note that `zh` means Chinese, while `en` means English.
|
||||
|
||||
(3) Download the VAD model
|
||||
Please visit
|
||||
https://github.com/snakers4/silero-vad/raw/master/src/silero_vad/data/silero_vad.onnx
|
||||
https://github.com/k2-fsa/sherpa-onnx/releases/download/asr-models/silero_vad.onnx
|
||||
to download silero_vad.onnx
|
||||
|
||||
For instance,
|
||||
|
||||
wget https://github.com/snakers4/silero-vad/raw/master/src/silero_vad/data/silero_vad.onnx
|
||||
wget https://github.com/k2-fsa/sherpa-onnx/releases/download/asr-models/silero_vad.onnx
|
||||
|
||||
(4) Please refer to ./generate-subtitles.py
|
||||
to download a non-streaming ASR model.
|
||||
|
||||
@@ -38,12 +38,12 @@ Note that `zh` means Chinese, while `en` means English.
|
||||
|
||||
(3) Download the VAD model
|
||||
Please visit
|
||||
https://github.com/snakers4/silero-vad/raw/master/src/silero_vad/data/silero_vad.onnx
|
||||
https://github.com/k2-fsa/sherpa-onnx/releases/download/asr-models/silero_vad.onnx
|
||||
to download silero_vad.onnx
|
||||
|
||||
For instance,
|
||||
|
||||
wget https://github.com/snakers4/silero-vad/raw/master/src/silero_vad/data/silero_vad.onnx
|
||||
wget https://github.com/k2-fsa/sherpa-onnx/releases/download/asr-models/silero_vad.onnx
|
||||
|
||||
(4) Please refer to ./generate-subtitles.py
|
||||
to download a non-streaming ASR model.
|
||||
|
||||
@@ -36,12 +36,12 @@ Note that `zh` means Chinese, while `en` means English.
|
||||
|
||||
(3) Download the VAD model
|
||||
Please visit
|
||||
https://github.com/snakers4/silero-vad/raw/master/src/silero_vad/data/silero_vad.onnx
|
||||
https://github.com/k2-fsa/sherpa-onnx/releases/download/asr-models/silero_vad.onnx
|
||||
to download silero_vad.onnx
|
||||
|
||||
For instance,
|
||||
|
||||
wget https://github.com/snakers4/silero-vad/raw/master/src/silero_vad/data/silero_vad.onnx
|
||||
wget https://github.com/k2-fsa/sherpa-onnx/releases/download/asr-models/silero_vad.onnx
|
||||
|
||||
(4) Run this script
|
||||
|
||||
|
||||
@@ -55,7 +55,7 @@ def main():
|
||||
if not Path(args.silero_vad_model).is_file():
|
||||
raise RuntimeError(
|
||||
f"{args.silero_vad_model} does not exist. Please download it from "
|
||||
"https://github.com/snakers4/silero-vad/raw/master/src/silero_vad/data/silero_vad.onnx"
|
||||
"https://github.com/k2-fsa/sherpa-onnx/releases/download/asr-models/silero_vad.onnx"
|
||||
)
|
||||
|
||||
device_name = args.device_name
|
||||
|
||||
@@ -38,7 +38,7 @@ def main():
|
||||
if not Path(args.silero_vad_model).is_file():
|
||||
raise RuntimeError(
|
||||
f"{args.silero_vad_model} does not exist. Please download it from "
|
||||
"https://github.com/snakers4/silero-vad/raw/master/src/silero_vad/data/silero_vad.onnx"
|
||||
"https://github.com/k2-fsa/sherpa-onnx/releases/download/asr-models/silero_vad.onnx"
|
||||
)
|
||||
|
||||
mic_sample_rate = 16000
|
||||
|
||||
@@ -14,12 +14,12 @@ python3 ./vad-remove-non-speech-segments-alsa.py \
|
||||
--silero-vad-model silero_vad.onnx
|
||||
|
||||
Please visit
|
||||
https://github.com/snakers4/silero-vad/raw/master/src/silero_vad/data/silero_vad.onnx
|
||||
https://github.com/k2-fsa/sherpa-onnx/releases/download/asr-models/silero_vad.onnx
|
||||
to download silero_vad.onnx
|
||||
|
||||
For instance,
|
||||
|
||||
wget https://github.com/snakers4/silero-vad/raw/master/src/silero_vad/data/silero_vad.onnx
|
||||
wget https://github.com/k2-fsa/sherpa-onnx/releases/download/asr-models/silero_vad.onnx
|
||||
"""
|
||||
|
||||
import argparse
|
||||
|
||||
@@ -13,12 +13,11 @@ python3 ./vad-remove-non-speech-segments-from-file.py \
|
||||
output.wav
|
||||
|
||||
Please visit
|
||||
https://github.com/snakers4/silero-vad/raw/master/src/silero_vad/data/silero_vad.onnx
|
||||
https://github.com/k2-fsa/sherpa-onnx/releases/download/asr-models/silero_vad.onnx
|
||||
to download silero_vad.onnx
|
||||
|
||||
For instance,
|
||||
|
||||
wget https://github.com/snakers4/silero-vad/raw/master/src/silero_vad/data/silero_vad.onnx
|
||||
wget https://github.com/k2-fsa/sherpa-onnx/releases/download/asr-models/silero_vad.onnx
|
||||
"""
|
||||
|
||||
import argparse
|
||||
|
||||
@@ -11,12 +11,12 @@ python3 ./vad-remove-non-speech-segments.py \
|
||||
--silero-vad-model silero_vad.onnx
|
||||
|
||||
Please visit
|
||||
https://github.com/snakers4/silero-vad/raw/master/src/silero_vad/data/silero_vad.onnx
|
||||
https://github.com/k2-fsa/sherpa-onnx/releases/download/asr-models/silero_vad.onnx
|
||||
to download silero_vad.onnx
|
||||
|
||||
For instance,
|
||||
|
||||
wget https://github.com/snakers4/silero-vad/raw/master/src/silero_vad/data/silero_vad.onnx
|
||||
wget https://github.com/k2-fsa/sherpa-onnx/releases/download/asr-models/silero_vad.onnx
|
||||
"""
|
||||
|
||||
import argparse
|
||||
|
||||
@@ -70,12 +70,13 @@ to install sherpa-onnx and to download non-streaming pre-trained models
|
||||
used in this file.
|
||||
|
||||
Please visit
|
||||
https://github.com/snakers4/silero-vad/raw/master/src/silero_vad/data/silero_vad.onnx
|
||||
https://github.com/k2-fsa/sherpa-onnx/releases/download/asr-models/silero_vad.onnx
|
||||
to download silero_vad.onnx
|
||||
|
||||
For instance,
|
||||
|
||||
wget https://github.com/snakers4/silero-vad/raw/master/src/silero_vad/data/silero_vad.onnx
|
||||
wget https://github.com/k2-fsa/sherpa-onnx/releases/download/asr-models/silero_vad.onnx
|
||||
|
||||
"""
|
||||
import argparse
|
||||
import sys
|
||||
|
||||
Reference in new issue
Block a user