This repository has been archived on 2025-08-26. You can view files and clone it, but cannot push or open issues or pull requests.
Files

20 lines
930 B
Bash
Raw Normal View History

2023-07-21 17:56:09 +08:00
#!/usr/bin/env bash
2024-05-21 11:50:13 +08:00
set -ex
if [ ! -d icefall-asr-zipformer-streaming-wenetspeech-20230615 ]; then
curl -SL -O https://github.com/k2-fsa/sherpa-onnx/releases/download/asr-models/icefall-asr-zipformer-streaming-wenetspeech-20230615.tar.bz2
tar xvf icefall-asr-zipformer-streaming-wenetspeech-20230615.tar.bz2
rm icefall-asr-zipformer-streaming-wenetspeech-20230615.tar.bz2
fi
go mod tidy
go build
2023-07-21 17:56:09 +08:00
./real-time-speech-recognition-from-microphone \
--encoder ./icefall-asr-zipformer-streaming-wenetspeech-20230615/exp/encoder-epoch-12-avg-4-chunk-16-left-128.onnx \
--decoder ./icefall-asr-zipformer-streaming-wenetspeech-20230615/exp/decoder-epoch-12-avg-4-chunk-16-left-128.onnx \
--joiner ./icefall-asr-zipformer-streaming-wenetspeech-20230615/exp/joiner-epoch-12-avg-4-chunk-16-left-128.onnx \
--tokens ./icefall-asr-zipformer-streaming-wenetspeech-20230615/data/lang_char/tokens.txt \
--model-type zipformer2