Merge f20f17c2c06c8cf2f99fcf66c922a881bbcc34a6 into 13055fa56994e75a7152c176047c56c62bbeede4

This commit is contained in:
Karasukaigan 2025-05-16 18:03:57 +08:00 committed by GitHub
commit da6aacfc68
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -766,6 +766,12 @@ def get_tts_wav(
if not ref_free:
phones1, bert1, norm_text1 = get_phones_and_bert(prompt_text, prompt_language, version)
# 确保sample_steps为int
try:
sample_steps = int(sample_steps)
except (TypeError, ValueError):
sample_steps = 8
for i_text, text in enumerate(texts):
# 解决输入目标文本的空行导致报错的问题
if len(text.strip()) == 0: