Spaces:
Sleeping
Sleeping
nukopy commited on
Commit ·
454083d
1
Parent(s): 71c3f53
fix: specify device for Whisper model loading
Browse files- Updated the Whisper model loading to explicitly set the device to "cpu" for improved compatibility and performance.
apps/audio_cloning/vallex/main.py
CHANGED
|
@@ -170,7 +170,9 @@ if not os.path.exists(OUTPUT_DIR_WHISPER):
|
|
| 170 |
try:
|
| 171 |
logger.info("Loading Whisper model...")
|
| 172 |
model_name = "tiny"
|
| 173 |
-
whisper_model = whisper.load_model(
|
|
|
|
|
|
|
| 174 |
logger.info("Whisper model loaded successfully")
|
| 175 |
except NotImplementedError as e:
|
| 176 |
logger.error("Error on loading Whisper model: %s", e)
|
|
|
|
| 170 |
try:
|
| 171 |
logger.info("Loading Whisper model...")
|
| 172 |
model_name = "tiny"
|
| 173 |
+
whisper_model = whisper.load_model(
|
| 174 |
+
model_name, device="cpu", download_root=OUTPUT_DIR_WHISPER
|
| 175 |
+
)
|
| 176 |
logger.info("Whisper model loaded successfully")
|
| 177 |
except NotImplementedError as e:
|
| 178 |
logger.error("Error on loading Whisper model: %s", e)
|