#3603 TaskCfgSTT(is_cuda=True, uuid='a35e2a465e', cache_folder='C:/SOFT/pyvideotrans/tmp/28592/a35e2a465e', target_dir='c:/sof

14.212* Posted at: 1 day ago 👁31

语音识别阶段出错 [阿里FunASR(本地)] Traceback (most recent call last):
File "videotrans\process\stt_fun.py", line 898, in funasr_mlt
File "funasr\auto\auto_model.py", line 135, in init

model, kwargs = self.build_model(**kwargs)

File "funasr\auto\auto_model.py", line 281, in build_model

assert model_class is not None, f'{kwargs["model"]} is not registered'

AssertionError: FunASRNano is not registered

Traceback (most recent call last):
File "videotrans\task\job.py", line 105, in run
File "videotrans\task\_speech2text.py", line 152, in recogn
File "videotrans\recognition\__init__.py", line 242, in run
File "videotrans\recognition\_base.py", line 143, in run
File "videotrans\recognition\_funasr.py", line 64, in _exec
File "videotrans\configure\_base.py", line 288, in _new_process
RuntimeError: Traceback (most recent call last):
File "videotrans\process\stt_fun.py", line 898, in funasr_mlt
File "funasr\auto\auto_model.py", line 135, in init

model, kwargs = self.build_model(**kwargs)

File "funasr\auto\auto_model.py", line 281, in build_model

assert model_class is not None, f'{kwargs["model"]} is not registered'

AssertionError: FunASRNano is not registered
TaskCfgSTT(is_cuda=True, uuid='a35e2a465e', cache_folder='C:/SOFT/pyvideotrans/tmp/28592/a35e2a465e', target_dir='c:/soft/pyvideotrans/output/recogn', source_language=None, source_language_code=None, source_sub=None, source_wav=None, source_wav_output=None, target_language=None, target_language_code=None, target_sub='c:/soft/pyvideotrans/output/recogn/R_MIC_260310-203253xx.srt', target_wav=None, target_wav_output=None, name='K:/R_MIC_260310-203253xx.mp3', noextname='R_MIC_260310-203253xx', basename='R_MIC_260310-203253xx.mp3', ext='mp3', dirname='K:/', shound_del_name=None, detect_language='zh-cn', recogn_type=3, model_name='Fun-ASR-Nano-2512', shibie_audio='C:/SOFT/pyvideotrans/tmp/28592/a35e2a465e/R_MIC_260310-203253xx-1773463544.7995083.wav', remove_noise=False, enable_diariz=True, nums_diariz=0, rephrase=0, fix_punc=False)


=
system:Windows-10-10.0.22631-SP0
version:v3.98
frozen:True
language:zh
root_dir:C:/SOFT/pyvideotrans

5 Replies

这是由于 FunASR 本地模型 FunASRNano 未正确注册或模型文件缺失导致的。

  1. 检查模型文件:确认 models/ 目录下是否存在 FunASR 模型文件夹(例如 models--iic--FunASR)。如果不存在,需要手动下载或等待软件自动下载(可能因网络问题失败)。
  2. 手动下载模型:如果自动下载失败,请访问 HuggingFace 模型仓库(例如 https://huggingface.co/iic/FunASR)或国内镜像站,下载 FunASRNano 模型的所有文件(.json, .bin, .txt 等),并将其放入 models/models--iic--FunASR 目录中(具体文件夹名需与模型对应)。
  3. 切换模型:如果问题持续,可以尝试在语音识别渠道的下拉列表中,选择另一个可用的 FunASR 模型(例如 Paraformer-zh),或者暂时切换到其他语音识别渠道(如 faster-whisper(本地)qwen-asr(本地))。
  4. 配置网络代理:如果模型需要从 HuggingFace 下载,请确保网络通畅,或在“网络代理”设置中填写有效的代理地址。

请查阅相关文档:

试试下载 2.5G的完整包

下载的是2.5G完整包,之后是覆盖升级的

根据开发者回复,您已下载并覆盖安装了2.5G的完整包。如果覆盖安装后问题依旧,可能是模型文件在覆盖过程中未正确更新或仍存在损坏。

请按以下步骤操作:

  1. 清理旧模型:进入软件安装目录下的 models/ 文件夹,查找并删除所有以 models--iic--FunASR 开头的文件夹(例如 models--iic--FunASRmodels--iic--FunASR-Nano)。
  2. 重新启动软件:重新启动 pyVideoTrans。
  3. 重新触发下载:再次尝试使用“阿里FunASR(本地)”渠道进行语音识别。软件会自动重新下载缺失的模型文件。请确保网络通畅,或已配置有效的“网络代理”。
  4. 验证模型:下载完成后,检查 models/ 目录下是否生成了新的 FunASR 模型文件夹。
  5. 备用方案:如果问题仍未解决,建议暂时切换到其他语音识别渠道,如 faster-whisper(本地)qwen-asr(本地)

请查阅相关文档:

升级之前是哪个版本?如果低于 3.97,需要重新下载 3.98 完整包。

  1. 删掉 models/models 下的所有文件
  2. 关掉vpn,删掉网络代理文本框内容

然后重新试试

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.

Related resource