Update app.py
Browse files
app.py
CHANGED
@@ -16,7 +16,7 @@ def predict(image):
|
|
16 |
img = img.resize((280, 280)) # Adjusted the size to 280x280
|
17 |
|
18 |
# Convert to numpy array and normalize the pixel values
|
19 |
-
img_array = np.array(img).reshape(1, 280
|
20 |
|
21 |
# Make prediction
|
22 |
prediction = model.predict(img_array)
|
|
|
16 |
img = img.resize((280, 280)) # Adjusted the size to 280x280
|
17 |
|
18 |
# Convert to numpy array and normalize the pixel values
|
19 |
+
img_array = np.array(img).reshape(1, 280 * 280) / 255.0 # Flattened image to 78400
|
20 |
|
21 |
# Make prediction
|
22 |
prediction = model.predict(img_array)
|