Spaces:
Runtime error
Runtime error
Commit
·
1dcab46
1
Parent(s):
fdf6071
Update app.py
Browse files
app.py
CHANGED
|
@@ -18,8 +18,8 @@ def get_text(text, hps):
|
|
| 18 |
return text_norm
|
| 19 |
|
| 20 |
def tts(text):
|
| 21 |
-
model_path = './logs/'
|
| 22 |
-
config_path = './configs/'
|
| 23 |
hps = utils.get_hparams_from_file(config_path)
|
| 24 |
|
| 25 |
if "use_mel_posterior_encoder" in hps.model.keys() and hps.model.use_mel_posterior_encoder == True:
|
|
@@ -64,7 +64,7 @@ if __name__ == "__main__":
|
|
| 64 |
|
| 65 |
gr.Interface(
|
| 66 |
fn=tts,
|
| 67 |
-
inputs=[components.
|
| 68 |
outputs=components.Audio(type='filepath', label="Generated Speech"),
|
| 69 |
live=False
|
| 70 |
).launch(show_error=True)
|
|
|
|
| 18 |
return text_norm
|
| 19 |
|
| 20 |
def tts(text):
|
| 21 |
+
model_path = './logs/G_13900.pth'
|
| 22 |
+
config_path = './configs/config.json'
|
| 23 |
hps = utils.get_hparams_from_file(config_path)
|
| 24 |
|
| 25 |
if "use_mel_posterior_encoder" in hps.model.keys() and hps.model.use_mel_posterior_encoder == True:
|
|
|
|
| 64 |
|
| 65 |
gr.Interface(
|
| 66 |
fn=tts,
|
| 67 |
+
inputs=[components.Textbox(label="Text Input")],
|
| 68 |
outputs=components.Audio(type='filepath', label="Generated Speech"),
|
| 69 |
live=False
|
| 70 |
).launch(show_error=True)
|