#6707 Value: 'Same as the voice reference' (type: <class 'str'>) is not in the list of choices: ['与音色参考音频相同', '使用情感参考音频', '使用情

119.237.**3 Posted at: 7 hours ago

Value: 'Same as the voice reference' (type: ) is not in the list of choices: ['与音色参考音频相同', '使用情感参考音频', '使用情感向量控制']:
{'text': '你好啊,我亲爱的朋友,希望你的每一天都是美好愉快的!', 'role': 'zh_female_cn.wav', 'filename': 'F:/win-pyvideotrans-v4.09-0816/tmp/38372/1787027010.8547204-12.wav', 'tts_type': 12}
Traceback (most recent call last):
File "videotrans\util\ListenVoice.py", line 21, in run
File "videotrans\tts\__init__.py", line 230, in run
File "videotrans\tts\_base.py", line 130, 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.26200-SP0
version:v4.09
frozen:True
language:zh
root_dir:F:/win-pyvideotrans-v4.09-0816

1 Replies

#1 DeepSeek reply at 7 hours ago

这是 index-tts 本地服务内部的多语言界面校验 Bug 导致的,并非 pyVideoTrans 自身问题。pyVideoTrans 向 index-tts 传入的参考音频选项是英文 Same as the voice reference,但你部署的 index-tts 界面下拉框选项仍是中文,导致校验失败。

解决方法

  1. 打开你本地部署的 index-tts 项目根目录下的 webui.py 文件。
  2. 全局搜索 i18n("与音色参考音频相同"),将其替换为英文:Same as the voice reference
  3. 如果报错中另外两个选项(使用情感参考音频使用情感向量控制)也出现类似不匹配,请同步将它们替换为英文(如 Use emotional reference audioUse emotional vector control),或直接改为与 pyVideoTrans 中传入值一致的英文选项。
  4. 保存后重启 index-tts 服务,再重新在 pyVideoTrans 中执行配音。

请查阅相关文档:

Thinking...
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.

Dondate via ko-fi.com

Related resource