开发者社区 > ModelScope模型即服务 > 自然语言处理 > 正文

modelscope-funasr要么报错要么识别为空,为什么?

modelscope-funasr要么报错要么识别为空,为什么?

res = model.generate(input="voice.wav", batch_size_s=300, hotword='魔搭')
0%| | 0/1 [00:01<?, ?it/s]
Traceback (most recent call last):
File "", line 1, in
File "C:\Users\DGG\AppData\Roaming\Python\Python310\site-packages\funasr\auto\auto_model.py", line 263, in generate
return self.inference_with_vad(input, input_len=input_len, cfg)
File "C:\Users\DGG\AppData\Roaming\Python\Python310\site-packages\funasr\auto\auto_model.py", line 334, in inference_with_vad
res = self.inference(
File "C:\Users\DGG\AppData\Roaming\Python\Python310\site-packages\funasr\auto\auto_model.py", line 300, in inference
res = model.inference(
batch, kwargs)
File "C:\Users\DGG\AppData\Roaming\Python\Python310\site-packages\funasr\models\fsmn_vad_streaming\model.py", line 722, in inference
segments_i = self.forward(
batch)
File "C:\Users\DGG\AppData\Roaming\Python\Python310\site-packages\funasr\models\fsmn_vad_streaming\model.py", line 566, in forward
self.DetectLastFrames(cache=cache)
File "C:\Users\DGG\AppData\Roaming\Python\Python310\site-packages\funasr\models\fsmn_vad_streaming\model.py", line 772, in DetectLastFrames
frame_state = self.GetFrameState(
File "C:\Users\DGG\AppData\Roaming\Python\Python310\site-packages\funasr\models\fsmn_vad_streaming\model.py", line 522, in GetFrameState
speech_prob = math.log(sum_score)
ValueError: math domain error

展开
收起
三分钟热度的鱼 2024-07-31 21:37:44 62 0
1 条回答
写回答
取消 提交回答
  • 先用例子测试,没问题再换自己音频,如果出问题,再去对比音频本身。
    此回答整理自钉群“modelscope-funasr社区交流”

    2024-07-31 23:05:53
    赞同 8 展开评论 打赏

包含命名实体识别、文本分类、分词、关系抽取、问答、推理、文本摘要、情感分析、机器翻译等多个领域

热门讨论

热门文章

相关电子书

更多
视觉AI能力的开放现状及ModelScope实战 立即下载
ModelScope助力语音AI模型创新与应用 立即下载
低代码开发师(初级)实战教程 立即下载