Spaces:
Running
Running
futurespyhi
commited on
Commit
·
9e45d3b
1
Parent(s):
6bcf3a4
debugging loading decoders
Browse files
app.py
CHANGED
|
@@ -275,7 +275,32 @@ def generate_music_spaces(lyrics: str, genre: str, mood: str, progress=gr.Progre
|
|
| 275 |
print(f"⏱️ Estimated time: 8-9 minutes for high-quality generation")
|
| 276 |
print(f"Working directory: {os.getcwd()}")
|
| 277 |
print(f"Command: {' '.join(cmd)}")
|
| 278 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 279 |
# Change to YuE/inference directory for execution
|
| 280 |
original_cwd = os.getcwd()
|
| 281 |
inference_dir = os.path.join(os.getcwd(), "YuE", "inference")
|
|
|
|
| 275 |
print(f"⏱️ Estimated time: 8-9 minutes for high-quality generation")
|
| 276 |
print(f"Working directory: {os.getcwd()}")
|
| 277 |
print(f"Command: {' '.join(cmd)}")
|
| 278 |
+
|
| 279 |
+
# Debug: Check decoder files before inference
|
| 280 |
+
decoder_base = os.path.join(os.getcwd(), "YuE", "inference", "xcodec_mini_infer", "decoders")
|
| 281 |
+
print(f"🔍 Checking decoder files at: {decoder_base}")
|
| 282 |
+
if os.path.exists(decoder_base):
|
| 283 |
+
decoder_files = os.listdir(decoder_base)
|
| 284 |
+
print(f"🔍 Available decoder files: {decoder_files}")
|
| 285 |
+
|
| 286 |
+
# Check specific decoder files
|
| 287 |
+
vocal_decoder = os.path.join(decoder_base, "decoder_131000.pth")
|
| 288 |
+
inst_decoder = os.path.join(decoder_base, "decoder_151000.pth")
|
| 289 |
+
|
| 290 |
+
if os.path.exists(vocal_decoder):
|
| 291 |
+
size_mb = os.path.getsize(vocal_decoder) // (1024*1024)
|
| 292 |
+
print(f"✅ Vocal decoder: {size_mb}MB")
|
| 293 |
+
else:
|
| 294 |
+
print("❌ Vocal decoder missing!")
|
| 295 |
+
|
| 296 |
+
if os.path.exists(inst_decoder):
|
| 297 |
+
size_mb = os.path.getsize(inst_decoder) // (1024*1024)
|
| 298 |
+
print(f"✅ Instrumental decoder: {size_mb}MB")
|
| 299 |
+
else:
|
| 300 |
+
print("❌ Instrumental decoder missing!")
|
| 301 |
+
else:
|
| 302 |
+
print("❌ Decoder directory not found!")
|
| 303 |
+
|
| 304 |
# Change to YuE/inference directory for execution
|
| 305 |
original_cwd = os.getcwd()
|
| 306 |
inference_dir = os.path.join(os.getcwd(), "YuE", "inference")
|