Spaces:
Sleeping
Sleeping
Commit
·
a3b4c21
1
Parent(s):
7ef344d
Migrate model debug on app
Browse files
app.py
CHANGED
@@ -60,6 +60,12 @@ os.environ["TOKENIZERS_PARALLELISM"] = "false"
|
|
60 |
# os.environ["HF_HOME"] = huggingface_cache_dir # Use this folder for HF cache
|
61 |
# 2. Setup Hugging Face Cloud project model cache
|
62 |
MODEL_CACHE_DIR = "/app/model_cache"
|
|
|
|
|
|
|
|
|
|
|
|
|
63 |
# Check if the required model files exist
|
64 |
if os.path.exists(os.path.join(MODEL_CACHE_DIR, "config.json")):
|
65 |
print(f"✅ Found cached model at {MODEL_CACHE_DIR}")
|
|
|
60 |
# os.environ["HF_HOME"] = huggingface_cache_dir # Use this folder for HF cache
|
61 |
# 2. Setup Hugging Face Cloud project model cache
|
62 |
MODEL_CACHE_DIR = "/app/model_cache"
|
63 |
+
# Verify structure
|
64 |
+
print("\n📂 LLM Model Structure:")
|
65 |
+
for root, dirs, files in os.walk(MODEL_CACHE_DIR):
|
66 |
+
print(f"📁 {root}/")
|
67 |
+
for file in files:
|
68 |
+
print(f" 📄 {file}")
|
69 |
# Check if the required model files exist
|
70 |
if os.path.exists(os.path.join(MODEL_CACHE_DIR, "config.json")):
|
71 |
print(f"✅ Found cached model at {MODEL_CACHE_DIR}")
|