#5307 videotrans.configure.excepts.DubbingSrtError: Value: 'Same as the voice reference' (type: <class 'str'>) is not in the l

113.88* Posted at: 1 day ago

Value: 'Same as the voice reference' (type: ) is not in the list of choices: ['与音色参考音频相同', '使用情感参考音频', '使用情感向量控制']:
Traceback (most recent call last):
File "videotrans\util\ListenVoice.py", line 16, in run
File "videotrans\tts\__init__.py", line 185, in run
File "videotrans\tts\_base.py", line 133, in run
videotrans.configure.excepts.DubbingSrtError: Value: 'Same as the voice reference' (type: ) is not in the list of choices: ['与音色参考音频相同', '使用情感参考音频', '使用情感向量控制']


=
system:Windows-10-10.0.19045-SP0
version:v4.03
frozen:True
language:zh
root_dir:G:/VideoTrans

1 Replies

这是由于 index-tts 开源库内部的多语言界面字符翻译不一致引发的校验 Bug。软件在发起配音请求时传递了英文参数 'Same as the voice reference',但 index-tts 的后端验证列表是中文的 ['与音色参考音频相同', ...],导致匹配失败。

解决方案:

  1. 找到你本地部署的 index-tts 项目根目录下的 webui.py 文件。
  2. 使用文本编辑器打开该文件,全局搜索 i18n("与音色参考音频相同") 字符串。
  3. 将其直接替换为英文:Same as the voice reference,保存文件。
  4. 重启 index-tts 服务,然后重试 pyVideoTrans 中的配音任务。
注意:如果你使用的是第三方预打包的 index-tts 集成环境(非自行部署),可能需要联系该集成包的维护方进行修复,或者尝试将 index-tts 更新到最新版本。
Post Your Reply