From 248408f92fab400d4de451742d085391d9ee7dec Mon Sep 17 00:00:00 2001
From: yhliang <68215459+yhliang-aslp@users.noreply.github.com>
Date: 星期五, 12 五月 2023 11:42:29 +0800
Subject: [PATCH] Merge pull request #506 from alibaba-damo-academy/main
---
funasr/runtime/python/onnxruntime/demo_vad_online.py | 10 +++++-----
1 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/funasr/runtime/python/onnxruntime/demo_vad_online.py b/funasr/runtime/python/onnxruntime/demo_vad_online.py
index 1ab4d9d..a80f58a 100644
--- a/funasr/runtime/python/onnxruntime/demo_vad_online.py
+++ b/funasr/runtime/python/onnxruntime/demo_vad_online.py
@@ -1,9 +1,10 @@
-import soundfile
from funasr_onnx import Fsmn_vad_online
+import soundfile
+from pathlib import Path
+model_dir = "damo/speech_fsmn_vad_zh-cn-16k-common-pytorch"
+wav_path = '{}/.cache/modelscope/hub/damo/speech_fsmn_vad_zh-cn-16k-common-pytorch/example/vad_example.wav'.format(Path.home())
-model_dir = "/mnt/ailsa.zly/tfbase/espnet_work/FunASR_dev_zly/export/damo/speech_fsmn_vad_zh-cn-16k-common-pytorch"
-wav_path = "/mnt/ailsa.zly/tfbase/espnet_work/FunASR_dev_zly/egs_modelscope/vad/speech_fsmn_vad_zh-cn-16k-common/vad_example_16k.wav"
model = Fsmn_vad_online(model_dir)
@@ -24,5 +25,4 @@
segments_result = model(audio_in=speech[sample_offset: sample_offset + step],
param_dict=param_dict)
if segments_result:
- print(segments_result)
-
+ print(segments_result)
\ No newline at end of file
--
Gitblit v1.9.1