Spaces:
Running on Zero
Running on Zero
error handling in installs
Browse files
app.py
CHANGED
|
@@ -8,8 +8,13 @@ import spaces
|
|
| 8 |
|
| 9 |
# Download model weights (skips already-downloaded models automatically)
|
| 10 |
# In total, ~6GB (3GB for RFD3, 3GB for RF3, <100MB for MPNN); may take a few minutes depending on your connection speed
|
| 11 |
-
os.system("foundry install rfd3 ligandmpnn rf3")# installing model weights
|
| 12 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 13 |
|
| 14 |
#download_dir = "./models/"
|
| 15 |
#if not os.path.exists(download_dir):
|
|
|
|
| 8 |
|
| 9 |
# Download model weights (skips already-downloaded models automatically)
|
| 10 |
# In total, ~6GB (3GB for RFD3, 3GB for RF3, <100MB for MPNN); may take a few minutes depending on your connection speed
|
|
|
|
| 11 |
|
| 12 |
+
cmd = "foundry install rfd3 ligandmpnn rf3"
|
| 13 |
+
result = subprocess.run(cmd, shell=True, capture_output=True, text=True)
|
| 14 |
+
if result.returncode == 0:
|
| 15 |
+
print("Models installed successfully.")
|
| 16 |
+
else:
|
| 17 |
+
print(f"Error installing models: {result.stderr}")
|
| 18 |
|
| 19 |
#download_dir = "./models/"
|
| 20 |
#if not os.path.exists(download_dir):
|