Spaces:
Paused
Paused
Update app.py
Browse filesEdit wav to mp3
app.py
CHANGED
|
@@ -20,8 +20,8 @@ tts = TTS("tts_models/multilingual/multi-dataset/xtts_v2").to(device)
|
|
| 20 |
def voice_clone(text: str, speaker_wav: str, language: str):
|
| 21 |
# Run TTS
|
| 22 |
print("Speaker wav:", speaker_wav)
|
| 23 |
-
tts.tts_to_file(text=text, speaker_wav=speaker_wav, language=language, file_path="output.
|
| 24 |
-
return "output.
|
| 25 |
|
| 26 |
iface = gr.Interface(fn=voice_clone,
|
| 27 |
inputs=[gr.Textbox(lines=2, placeholder="Enter the text...", label="Text"),
|
|
|
|
| 20 |
def voice_clone(text: str, speaker_wav: str, language: str):
|
| 21 |
# Run TTS
|
| 22 |
print("Speaker wav:", speaker_wav)
|
| 23 |
+
tts.tts_to_file(text=text, speaker_wav=speaker_wav, language=language, file_path="output.mp3")
|
| 24 |
+
return "output.mp3"
|
| 25 |
|
| 26 |
iface = gr.Interface(fn=voice_clone,
|
| 27 |
inputs=[gr.Textbox(lines=2, placeholder="Enter the text...", label="Text"),
|