FunASR
FunASR copied to clipboard
使用funasr-onnx-online-asr测试paraformer_streaming训练的onnx导出模型出现c++段错误
🐛 Bug
- 使用funasr-onnx-online-asr测试paraformer_streaming训练的onnx到处模型出现c++段错误,
- 报错位置:funasr-onnx-online-asr.cpp文件148行,FunASRInferBuffer推理函数
- 使用modelscope上的基础模型能正常运行:speech_paraformer-large_asr_nat-zh-cn-16k-common-vocab8404-online-onnx
To Reproduce
- 使用funasr-1.0.19 examples/industrial_data_pretraining/paraformer_streaming目录下的微调脚本训练模型
- 基础模型使用iic/speech_paraformer_asr_nat-zh-cn-16k-common-vocab8404-online,并保持config配置一致
- 模型导出使用export.sh
Code sample
model="outputs"
python -m funasr.bin.export \
++model=${model} \
++type="onnx" \
++quantize=true \
++device="cpu" \
++debug=false
onnx推理
funasr-onnx-online-asr --model-dir outputs --quantize true --audio-fs 16000 --wav-path $wavfile
Environment
- OS : ubuntu22.04
- FunASR Version 1.0.19
- PyTorch Version: 2.2.1
- How you installed funasr : pip
- Python version: 3.10
more logs, more details
onnx: 1.15.0, onnxruntime: 1.17.1
more logs, more details
more logs, more details
it's config.yaml problem, should write tokens into config.yaml
if the issue persists, you can reopen the issue.