Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -14,8 +14,8 @@ class TTSWebUI:
|
|
| 14 |
|
| 15 |
def __init__(self,
|
| 16 |
gpu_id="cpu",
|
| 17 |
-
title="
|
| 18 |
-
article="
|
| 19 |
tts_model_path=None,
|
| 20 |
vocoder_model_path=None,
|
| 21 |
embedding_gan_path=None,
|
|
@@ -33,24 +33,24 @@ class TTSWebUI:
|
|
| 33 |
embedding_gan_path=embedding_gan_path)
|
| 34 |
self.iface = gr.Interface(fn=self.read,
|
| 35 |
inputs=[gr.Textbox(lines=2,
|
| 36 |
-
placeholder="
|
| 37 |
value="What I cannot create, I do not understand.",
|
| 38 |
-
label="
|
| 39 |
gr.Dropdown(text_selection,
|
| 40 |
type="value",
|
| 41 |
-
value='
|
| 42 |
-
label="
|
| 43 |
-
gr.Slider(minimum=0.0, maximum=0.8, step=0.1, value=0.5, label="
|
| 44 |
-
gr.Slider(minimum=0.7, maximum=1.3, step=0.1, value=1.0, label="
|
| 45 |
-
gr.Slider(minimum=0, maximum=available_artificial_voices, step=1, value=16, label="
|
| 46 |
-
gr.Slider(minimum=-10.0, maximum=10.0, step=0.1, value=0.0, label="
|
| 47 |
-
gr.Audio(type="filepath", show_label=True, container=True, label="[
|
| 48 |
# gr.Slider(minimum=0.5, maximum=1.5, step=0.1, value=1.0, label="Pitch Variance Scale"),
|
| 49 |
# gr.Slider(minimum=0.5, maximum=1.5, step=0.1, value=1.0, label="Energy Variance Scale"),
|
| 50 |
# gr.Slider(minimum=-10.0, maximum=10.0, step=0.1, value=0.0, label="Voice Depth")
|
| 51 |
],
|
| 52 |
-
outputs=[gr.Audio(type="numpy", label="
|
| 53 |
-
gr.Image(label="
|
| 54 |
title=title,
|
| 55 |
allow_flagging="never",
|
| 56 |
description=article
|
|
|
|
| 14 |
|
| 15 |
def __init__(self,
|
| 16 |
gpu_id="cpu",
|
| 17 |
+
title="超过7000种语音 文本转语音 Text-to-Speech",
|
| 18 |
+
article="这是使用 CPU 运行的. <br>",
|
| 19 |
tts_model_path=None,
|
| 20 |
vocoder_model_path=None,
|
| 21 |
embedding_gan_path=None,
|
|
|
|
| 33 |
embedding_gan_path=embedding_gan_path)
|
| 34 |
self.iface = gr.Interface(fn=self.read,
|
| 35 |
inputs=[gr.Textbox(lines=2,
|
| 36 |
+
placeholder="在这里写下您希望综合阅读的内容...",
|
| 37 |
value="What I cannot create, I do not understand.",
|
| 38 |
+
label="文本输入"),
|
| 39 |
gr.Dropdown(text_selection,
|
| 40 |
type="value",
|
| 41 |
+
value='Bulgarian (bul)',
|
| 42 |
+
label="选择文本的语言(在键盘上输入以快速找到它)"),
|
| 43 |
+
gr.Slider(minimum=0.0, maximum=0.8, step=0.1, value=0.5, label="创造力"),
|
| 44 |
+
gr.Slider(minimum=0.7, maximum=1.3, step=0.1, value=1.0, label="更快 - 更慢"),
|
| 45 |
+
gr.Slider(minimum=0, maximum=available_artificial_voices, step=1, value=16, label="人工语音的随机种子"),
|
| 46 |
+
gr.Slider(minimum=-10.0, maximum=10.0, step=0.1, value=0.0, label="人工声音的性别 女-男"),
|
| 47 |
+
gr.Audio(type="filepath", show_label=True, container=True, label="[可选] 克隆声音(如果留空,将使用人工声音)"),
|
| 48 |
# gr.Slider(minimum=0.5, maximum=1.5, step=0.1, value=1.0, label="Pitch Variance Scale"),
|
| 49 |
# gr.Slider(minimum=0.5, maximum=1.5, step=0.1, value=1.0, label="Energy Variance Scale"),
|
| 50 |
# gr.Slider(minimum=-10.0, maximum=10.0, step=0.1, value=0.0, label="Voice Depth")
|
| 51 |
],
|
| 52 |
+
outputs=[gr.Audio(type="numpy", label="生成音频"),
|
| 53 |
+
gr.Image(label="音调可视化")],
|
| 54 |
title=title,
|
| 55 |
allow_flagging="never",
|
| 56 |
description=article
|