#1719 TaskCfg(cache_folder='H:/win-pyvideotrans-v3.86/tmp12556/41e8d921f4', target_dir='H:/xiazai/_video_out/test', remove_noi

60.7* Posted at: 6 days ago 👁24

语音识别阶段出错:[阿里FunASR中文(本地)] 处理数据时缺少必需的键:'sentence_info':
Traceback (most recent call last):
File "videotrans\task\job.py", line 113, in run
File "videotrans\task\trans_create.py", line 354, in recogn
File "videotrans\recognition\__init__.py", line 224, in run
File "videotrans\recognition\_base.py", line 78, in run
File "videotrans\recognition\_funasr.py", line 61, in _exec
KeyError: 'sentence_info'

TaskCfg(cache_folder='H:/win-pyvideotrans-v3.86/tmp12556/41e8d921f4', target_dir='H:/xiazai/_video_out/test', remove_noise=False, is_separate=False, detect_language='zh-cn', subtitle_language=None, source_language='简体中文', target_language='简体中文', source_language_code='zh-cn', target_language_code='zh-cn', source_sub='H:/xiazai/_video_out/test/zh-cn.srt', target_sub='H:/xiazai/_video_out/test/zh-cn.srt', source_wav='H:/win-pyvideotrans-v3.86/tmp12556/41e8d921f4/zh-cn.wav', source_wav_output='H:/xiazai/_video_out/test/zh-cn.m4a', target_wav='H:/win-pyvideotrans-v3.86/tmp12556/41e8d921f4/target.wav', target_wav_output='H:/xiazai/_video_out/test/zh-cn.m4a', subtitles='', novoice_mp4='H:/win-pyvideotrans-v3.86/tmp12556/41e8d921f4/novoice.mp4', noextname='test', shibie_audio=None, targetdir_mp4='H:/xiazai/_video_out/test/test.mp4', instrument=None, vocal=None, back_audio='', background_music=None, app_mode='tiqu', subtitle_type=0, volume='+0%', pitch='+0Hz', voice_rate='+0%', voice_role='No', copysrt_rawvideo=False, clear_cache=False, translate_type=0, tts_type=0, recogn_type=2, model_name='paraformer-zh', split_type=0, voice_autorate=False, video_autorate=False, cuda=True, name='H:/xiazai/test.mp4', basename='test.mp4', ext='mp4', dirname='H:/xiazai', shound_del_name=None, uuid='41e8d921f4', remove_silent_mid=False, align_sub_audio=True, enable_diariz=False, nums_diariz=0, auto_fix=False)


=
system:Windows-10-10.0.26200-SP0
version:v3.86
frozen:True
language:zh
root_dir:H:/win-pyvideotrans-v3.86

1 Replies

这是阿里FunASR本地语音识别模块在处理返回数据时出现的错误,缺少必需的 'sentence_info' 键。这通常是由于FunASR模型文件损坏、下载不完整或版本不匹配导致的。

请按以下步骤解决:

  1. 清理并重新下载模型:

    • 前往软件根目录下的 models 文件夹(例如 H:/win-pyvideotrans-v3.86/models)。
    • 删除其中与 funasrparaformer 相关的文件夹(如 paraformer-zh)。
    • 重新启动软件,在语音识别阶段再次选择“阿里FunASR中文(本地)”,软件会自动重新下载模型文件。请确保网络通畅。
  2. 如果问题依旧,请切换识别引擎:

    • 作为临时解决方案,在主界面第2行“语音识别”处,将引擎切换为 faster-whisper(本地) 并选择一个模型(如 medium),这通常更稳定。
  3. 检查模型路径权限:

    • 确保软件所在路径(H:/win-pyvideotrans-v3.86)没有写入限制,且 models 文件夹可正常创建和写入文件。

如果以上步骤无法解决,请提供 H:/win-pyvideotrans-v3.86/logs/ 目录下最新的日志文件,以便进一步分析。

Post Your Reply
Open source and free maintenance is not easy. If this project is helpful to you, please consider making a small donation to help the project continue to maintain and update.

Donate: https://ko-fi.com/jianchang512

Trending Questions