Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -4,11 +4,10 @@ import numpy as np
|
|
4 |
from PIL import Image
|
5 |
|
6 |
# Load the model
|
7 |
-
model = tf.keras.models.load_model('
|
8 |
|
9 |
# Define the class names
|
10 |
-
class_names = ['Magnesium','Nitrogen','
|
11 |
-
|
12 |
# Function to classify the image
|
13 |
def classify_image(image):
|
14 |
# Convert the numpy array to a PIL Image object
|
|
|
4 |
from PIL import Image
|
5 |
|
6 |
# Load the model
|
7 |
+
model = tf.keras.models.load_model('Adam_8_1000_Acc 0.88_Nutrient-Model.h5')
|
8 |
|
9 |
# Define the class names
|
10 |
+
class_names = ['Calcium','Magnesium','Nitrogen','Phosphorus','Potassium','Sulfur']
|
|
|
11 |
# Function to classify the image
|
12 |
def classify_image(image):
|
13 |
# Convert the numpy array to a PIL Image object
|