本帖最后由 wangerxian 于 2024-9-20 14:36 编辑
0、环境安装
1. VS环境安装:
如果您没有Visual Studio 2022 c++运行环境,双击 VC_redist.x64(2022).exe 安装 Visual Studio 2022环境下编译的C++程序运行所需要的库;
2. git安装:
1.1 下载地址:
官网下载 (如遇网络问题,大陆用户可以使用下述地址:oss镜像)
1.2 如何进入git bash命令行可参考:
点击开始菜单,找到Git文件夹;在Git文件夹中,点击“Git Bash”
1.3 Git Bash安装lfs:
git lfs install
1、FunASR中文离线文件转写服务部署
1. Git Bash运行下述命令,下载相关模型至:
D:/funasr-runtime-resources/models
下载指令:
mkdir -p D:/funasr-runtime-resources/models && cd D:/funasr-runtime-resources/models;
git clone https://www.modelscope.cn/damo/speech_fsmn_vad_zh-cn-16k-common-onnx.git;
git clone https://www.modelscope.cn/damo/speech_paraformer-large-vad-punc_asr_nat-zh-cn-16k-common-vocab8404-onnx.git;
git clone https://www.modelscope.cn/damo/speech_ngram_lm_zh-cn-ai-wesp-fst.git;
git clone https://www.modelscope.cn/damo/punc_ct-transformer_cn-en-common-vocab471067-large-onnx.git;
git clone https://www.modelscope.cn/thuduj12/fst_itn_zh.git
# 如果您想使用8k模型,请下载8k模型:
git clone https://www.modelscope.cn/damo/speech_fsmn_vad_zh-cn-8k-common-onnx.git;
git clone https://www.modelscope.cn/damo/speech_paraformer_asr_nat-zh-cn-8k-common-vocab8358-tensorflow1-onnx.git;
git clone https://www.modelscope.cn/damo/speech_ngram_lm_zh-cn-ai-wesp-fst-token8358.git;
git clone https://www.modelscope.cn/damo/punc_ct-transformer_cn-en-common-vocab471067-large-onnx.git;
git clone https://www.modelscope.cn/thuduj12/fst_itn_zh.git
2. Git Bash在项目目录(funasr-runtime-win-cpu-x64-v0.2.0)启动服务端:
./funasr-wss-server.exe --vad-dir D:/funasr-runtime-resources/models/speech_fsmn_vad_zh-cn-16k-common-onnx --model-dir D:/funasr-runtime-resources/models/speech_paraformer-large-vad-punc_asr_nat-zh-cn-16k-common-vocab8404-onnx --lm-dir D:/funasr-runtime-resources/models/speech_ngram_lm_zh-cn-ai-wesp-fst --punc-dir D:/funasr-runtime-resources/models/punc_ct-transformer_cn-en-common-vocab471067-large-onnx --itn-dir D:/funasr-runtime-resources/models/fst_itn_zh --certfile ssl_key/server.crt --keyfile ssl_key/server.key
# 如果您想使用8k模型:
./funasr-wss-server.exe --vad-dir D:/funasr-runtime-resources/models/speech_fsmn_vad_zh-cn-8k-common-onnx --model-dir D:/funasr-runtime-resources/models/speech_paraformer_asr_nat-zh-cn-8k-common-vocab8358-tensorflow1-onnx --lm-dir D:/funasr-runtime-resources/models/speech_ngram_lm_zh-cn-ai-wesp-fst-token8358 --punc-dir D:/funasr-runtime-resources/models/punc_ct-transformer_cn-en-common-vocab471067-large-onnx --itn-dir D:/funasr-runtime-resources/models/fst_itn_zh --certfile ssl_key/server.crt --keyfile ssl_key/server.key
3. Git Bash在项目目录(funasr-runtime-win-cpu-x64-v0.2.0)启动客户端:
./funasr-wss-client.exe --server-ip 127.0.0.1 --port 10095 --wav-path asr_example_zh.wav
4. 详情及客户端用法可参考:
2、FunASR实时语音听写服务部署
1. Git Bash运行下述命令,下载相关模型至:
D:/funasr-runtime-resources/models :
下载指令:
mkdir -p D:/funasr-runtime-resources/models && cd D:/funasr-runtime-resources/models;
git clone https://www.modelscope.cn/damo/speech_fsmn_vad_zh-cn-16k-common-onnx.git;
git clone https://www.modelscope.cn/damo/speech_paraformer-large-vad-punc_asr_nat-zh-cn-16k-common-vocab8404-onnx.git;
git clone https://www.modelscope.cn/damo/speech_paraformer-large_asr_nat-zh-cn-16k-common-vocab8404-online-onnx.git;
git clone https://www.modelscope.cn/damo/speech_ngram_lm_zh-cn-ai-wesp-fst.git;
git clone https://www.modelscope.cn/damo/punc_ct-transformer_zh-cn-common-vad_realtime-vocab272727-onnx.git;
git clone https://www.modelscope.cn/thuduj12/fst_itn_zh.git
2. Git Bash在项目目录(funasr-runtime-win-cpu-x64-v0.2.0)启动服务端:
./funasr-wss-server-2pass.exe --vad-dir D:/funasr-runtime-resources/models/speech_fsmn_vad_zh-cn-16k-common-onnx --model-dir D:/funasr-runtime-resources/models/speech_paraformer-large-vad-punc_asr_nat-zh-cn-16k-common-vocab8404-onnx --online-model-dir D:/funasr-runtime-resources/models/speech_paraformer-large_asr_nat-zh-cn-16k-common-vocab8404-online-onnx --lm-dir D:/funasr-runtime-resources/models/speech_ngram_lm_zh-cn-ai-wesp-fst --punc-dir D:/funasr-runtime-resources/models/punc_ct-transformer_zh-cn-common-vad_realtime-vocab272727-onnx --itn-dir D:/funasr-runtime-resources/models/fst_itn_zh --certfile ssl_key/server.crt --keyfile ssl_key/server.key
3. Git Bash在项目目录(funasr-runtime-win-cpu-x64-v0.2.0)启动客户端:
./funasr-wss-client-2pass.exe --server-ip 127.0.0.1 --port 10095 --wav-path asr_example_zh.wav
4. 详情及客户端用法可参考:
3、FunASR英文离线文件转写服务部署
1. Git Bash运行下述命令,下载相关模型至:
D:/funasr-runtime-resources/models
下载指令:
mkdir -p D:/funasr-runtime-resources/models && cd D:/funasr-runtime-resources/models;
git clone https://www.modelscope.cn/damo/speech_fsmn_vad_zh-cn-16k-common-onnx.git;
git clone https://www.modelscope.cn/damo/speech_paraformer-large_asr_nat-en-16k-common-vocab10020-onnx.git;
git clone https://www.modelscope.cn/damo/punc_ct-transformer_cn-en-common-vocab471067-large-onnx.git
2. Git Bash在项目目录(funasr-runtime-win-cpu-x64-v0.2.0)启动服务端:
./funasr-wss-server.exe --vad-dir D:/funasr-runtime-resources/models/speech_fsmn_vad_zh-cn-16k-common-onnx --model-dir D:/funasr-runtime-resources/models/speech_paraformer-large_asr_nat-en-16k-common-vocab10020-onnx --punc-dir D:/funasr-runtime-resources/models/punc_ct-transformer_cn-en-common-vocab471067-large-onnx --certfile ssl_key/server.crt --keyfile ssl_key/server.key
3. Git Bash在项目目录(funasr-runtime-win-cpu-x64-v0.2.0)启动客户端:
./funasr-wss-client-2pass.exe --server-ip 127.0.0.1 --port 10095 --wav-path asr_example_zh.wav
4. 详情及客户端用法可参考:
Clone with HTTP
git clone https://www.modelscope.cn/damo/funasr-runtime-win-cpu-x64.git
|