Spaces:
Running
on
T4
Running
on
T4
add app
Browse files
app.py
CHANGED
|
@@ -50,7 +50,6 @@ def inference(
|
|
| 50 |
name,
|
| 51 |
voice,
|
| 52 |
voice_b,
|
| 53 |
-
voice_c,
|
| 54 |
preset,
|
| 55 |
seed,
|
| 56 |
regenerate,
|
|
@@ -81,8 +80,6 @@ def inference(
|
|
| 81 |
voices = [voice]
|
| 82 |
if voice_b != "disabled":
|
| 83 |
voices.append(voice_b)
|
| 84 |
-
if voice_c != "disabled":
|
| 85 |
-
voices.append(voice_c)
|
| 86 |
|
| 87 |
if len(voices) == 1:
|
| 88 |
voice_samples, conditioning_latents = load_voice(voice)
|
|
@@ -151,23 +148,19 @@ def main():
|
|
| 151 |
label="(Optional) Select second voice:",
|
| 152 |
type="value",
|
| 153 |
)
|
| 154 |
-
voice_c = gr.Dropdown(
|
| 155 |
-
VOICE_OPTIONS,
|
| 156 |
-
value="disabled",
|
| 157 |
-
label="(Optional) Select third voice:",
|
| 158 |
-
type="value",
|
| 159 |
-
)
|
| 160 |
seed = gr.Number(value=0, precision=0, label="Seed (for reproducibility):")
|
| 161 |
regenerate = gr.Textbox(
|
| 162 |
lines=1,
|
| 163 |
label="Comma-separated indices of clips to regenerate [starting from 1]",
|
| 164 |
)
|
|
|
|
| 165 |
split_by_newline = gr.Radio(
|
| 166 |
["Yes", "No"],
|
| 167 |
label="Split by newline (If [No], it will automatically try to find relevant splits):",
|
| 168 |
type="value",
|
| 169 |
value="No",
|
| 170 |
)
|
|
|
|
| 171 |
output_audio = gr.Audio(label="Combined audio:")
|
| 172 |
output_text = gr.Textbox(label="Split texts with indices:", lines=10)
|
| 173 |
|
|
@@ -179,7 +172,6 @@ def main():
|
|
| 179 |
name,
|
| 180 |
voice,
|
| 181 |
voice_b,
|
| 182 |
-
voice_c,
|
| 183 |
preset,
|
| 184 |
seed,
|
| 185 |
regenerate,
|
|
|
|
| 50 |
name,
|
| 51 |
voice,
|
| 52 |
voice_b,
|
|
|
|
| 53 |
preset,
|
| 54 |
seed,
|
| 55 |
regenerate,
|
|
|
|
| 80 |
voices = [voice]
|
| 81 |
if voice_b != "disabled":
|
| 82 |
voices.append(voice_b)
|
|
|
|
|
|
|
| 83 |
|
| 84 |
if len(voices) == 1:
|
| 85 |
voice_samples, conditioning_latents = load_voice(voice)
|
|
|
|
| 148 |
label="(Optional) Select second voice:",
|
| 149 |
type="value",
|
| 150 |
)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 151 |
seed = gr.Number(value=0, precision=0, label="Seed (for reproducibility):")
|
| 152 |
regenerate = gr.Textbox(
|
| 153 |
lines=1,
|
| 154 |
label="Comma-separated indices of clips to regenerate [starting from 1]",
|
| 155 |
)
|
| 156 |
+
|
| 157 |
split_by_newline = gr.Radio(
|
| 158 |
["Yes", "No"],
|
| 159 |
label="Split by newline (If [No], it will automatically try to find relevant splits):",
|
| 160 |
type="value",
|
| 161 |
value="No",
|
| 162 |
)
|
| 163 |
+
|
| 164 |
output_audio = gr.Audio(label="Combined audio:")
|
| 165 |
output_text = gr.Textbox(label="Split texts with indices:", lines=10)
|
| 166 |
|
|
|
|
| 172 |
name,
|
| 173 |
voice,
|
| 174 |
voice_b,
|
|
|
|
| 175 |
preset,
|
| 176 |
seed,
|
| 177 |
regenerate,
|