Spaces:
Running
Running
MilesCranmer
commited on
Commit
•
1049889
1
Parent(s):
71ed397
More helpful error message for julia install
Browse files- gui/app.py +8 -0
gui/app.py
CHANGED
@@ -1,5 +1,6 @@
|
|
1 |
import io
|
2 |
import gradio as gr
|
|
|
3 |
import os
|
4 |
import tempfile
|
5 |
import numpy as np
|
@@ -45,6 +46,13 @@ def greet(
|
|
45 |
fi"""
|
46 |
)
|
47 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
48 |
import pysr
|
49 |
try:
|
50 |
from julia.api import JuliaInfo
|
|
|
1 |
import io
|
2 |
import gradio as gr
|
3 |
+
import sys
|
4 |
import os
|
5 |
import tempfile
|
6 |
import numpy as np
|
|
|
46 |
fi"""
|
47 |
)
|
48 |
|
49 |
+
# Check if /usr/bin/julia exists:
|
50 |
+
if not os.path.isfile("/usr/bin/julia"):
|
51 |
+
return (
|
52 |
+
empty_df,
|
53 |
+
"Julia is not installed! (assuming '/usr/bin/julia')",
|
54 |
+
)
|
55 |
+
|
56 |
import pysr
|
57 |
try:
|
58 |
from julia.api import JuliaInfo
|