From b948ff459fab4779c5abdec62878e69f547e75aa Mon Sep 17 00:00:00 2001 From: PocketDocLabs Date: Tue, 21 May 2024 15:51:24 -0700 Subject: [PATCH] modified: GPT_SoVITS/AR/models/t2s_model.py modified: GPT_SoVITS/inference_webui.py --- GPT_SoVITS/AR/models/t2s_model.py | 2 +- GPT_SoVITS/inference_webui.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/GPT_SoVITS/AR/models/t2s_model.py b/GPT_SoVITS/AR/models/t2s_model.py index c53b6383..dbca6bae 100644 --- a/GPT_SoVITS/AR/models/t2s_model.py +++ b/GPT_SoVITS/AR/models/t2s_model.py @@ -329,7 +329,7 @@ class Text2SemanticDecoder(nn.Module): bert_feature, top_k: int = -100, top_p: int = 100, - min_p: int = 80, + min_p: float = 0.0, early_stop_num: int = -1, temperature: float = 1.0, ): diff --git a/GPT_SoVITS/inference_webui.py b/GPT_SoVITS/inference_webui.py index 4a723e5b..b456418b 100644 --- a/GPT_SoVITS/inference_webui.py +++ b/GPT_SoVITS/inference_webui.py @@ -311,7 +311,7 @@ def merge_short_text_in_array(texts, threshold): result[len(result) - 1] += text return result -def get_tts_wav(ref_wav_path, prompt_text, prompt_language, text, text_language, how_to_cut=i18n("不切"), top_k=20, min_p=0.8, top_p=1.0, temperature=0.6, ref_free = False): +def get_tts_wav(ref_wav_path, prompt_text, prompt_language, text, text_language, how_to_cut=i18n("不切"), top_k=20, min_p=0.0, top_p=0.6, temperature=0.6, ref_free = False): if prompt_text is None or len(prompt_text) == 0: ref_free = True t0 = ttime() @@ -587,7 +587,7 @@ with gr.Blocks(title="GPT-SoVITS WebUI") as app: with gr.Row(): gr.Markdown(value=i18n("gpt采样参数(无参考文本时不要太低):")) top_k = gr.Slider(minimum=1,maximum=100,step=1,label=i18n("top_k"),value=5,interactive=True) - min_p = gr.Slider(minimum=0,maximum=1,step=0.05,label=i18n("min_p"),value=0.8,interactive=True) + min_p = gr.Slider(minimum=0,maximum=1,step=0.05,label=i18n("min_p"),value=0.0,interactive=True) top_p = gr.Slider(minimum=0,maximum=1,step=0.05,label=i18n("top_p"),value=1,interactive=True) temperature = gr.Slider(minimum=0,maximum=1,step=0.05,label=i18n("temperature"),value=1,interactive=True) inference_button = gr.Button(i18n("合成语音"), variant="primary")