Neurolingua
commited on
Commit
•
fbacac8
1
Parent(s):
91194cb
Update app.py
Browse files
app.py
CHANGED
@@ -32,7 +32,7 @@ def predict_pest(filepath):
|
|
32 |
return result['predicted_classes'][0]
|
33 |
except Exception as e:
|
34 |
print(f"API call error: {e}")
|
35 |
-
return
|
36 |
|
37 |
def predict_disease(filepath):
|
38 |
CLIENT = InferenceHTTPClient(
|
@@ -46,7 +46,7 @@ def predict_disease(filepath):
|
|
46 |
return result['predicted_classes'][0]
|
47 |
except Exception as e:
|
48 |
print(f"API call error: {e}")
|
49 |
-
return
|
50 |
|
51 |
# Initialize the Flask app
|
52 |
account_sid = os.environ.get('TWILIO_ACCOUNT_SID')
|
|
|
32 |
return result['predicted_classes'][0]
|
33 |
except Exception as e:
|
34 |
print(f"API call error: {e}")
|
35 |
+
return e
|
36 |
|
37 |
def predict_disease(filepath):
|
38 |
CLIENT = InferenceHTTPClient(
|
|
|
46 |
return result['predicted_classes'][0]
|
47 |
except Exception as e:
|
48 |
print(f"API call error: {e}")
|
49 |
+
return e
|
50 |
|
51 |
# Initialize the Flask app
|
52 |
account_sid = os.environ.get('TWILIO_ACCOUNT_SID')
|