Spaces:
Runtime error
Runtime error
Sync from GitHub repo
Browse filesThis Space is synced from the GitHub repo: https://github.com/SWivid/F5-TTS. Please submit contributions to the Space there
src/f5_tts/infer/utils_infer.py
CHANGED
|
@@ -32,6 +32,8 @@ from f5_tts.model.utils import (
|
|
| 32 |
_ref_audio_cache = {}
|
| 33 |
|
| 34 |
device = "cuda" if torch.cuda.is_available() else "mps" if torch.backends.mps.is_available() else "cpu"
|
|
|
|
|
|
|
| 35 |
|
| 36 |
# -----------------------------------------
|
| 37 |
|
|
|
|
| 32 |
_ref_audio_cache = {}
|
| 33 |
|
| 34 |
device = "cuda" if torch.cuda.is_available() else "mps" if torch.backends.mps.is_available() else "cpu"
|
| 35 |
+
if device == "mps":
|
| 36 |
+
os.environ["PYTOCH_ENABLE_MPS_FALLBACK"] = "1"
|
| 37 |
|
| 38 |
# -----------------------------------------
|
| 39 |
|