Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -69,7 +69,7 @@ def chat_tts(text, temperature, top_P, top_K, audio_seed_input, text_seed_input,
|
|
69 |
|
70 |
# OpenVoice Clone
|
71 |
ckpt_converter = 'OpenVoice/checkpoints/converter'
|
72 |
-
device =
|
73 |
|
74 |
tone_color_converter = ToneColorConverter(f'{ckpt_converter}/config.json', device=device)
|
75 |
tone_color_converter.load_ckpt(f'{ckpt_converter}/checkpoint.pth')
|
|
|
69 |
|
70 |
# OpenVoice Clone
|
71 |
ckpt_converter = 'OpenVoice/checkpoints/converter'
|
72 |
+
device = "cuda:0" if torch.cuda.is_available() else "cpu"
|
73 |
|
74 |
tone_color_converter = ToneColorConverter(f'{ckpt_converter}/config.json', device=device)
|
75 |
tone_color_converter.load_ckpt(f'{ckpt_converter}/checkpoint.pth')
|