Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -162,7 +162,7 @@ with col4[0]:
|
|
| 162 |
st.image(img, caption='Uploaded Image', width=300)
|
| 163 |
|
| 164 |
# Preprocess the image
|
| 165 |
-
img = img.resize((224, 224)) # Resize to
|
| 166 |
img_array = image.img_to_array(img) # Convert to array
|
| 167 |
img_array = np.expand_dims(img_array, axis=0) # Expand dimensions
|
| 168 |
img_array /= 255.0 # Normalize if needed
|
|
|
|
| 162 |
st.image(img, caption='Uploaded Image', width=300)
|
| 163 |
|
| 164 |
# Preprocess the image
|
| 165 |
+
img = img.resize((224, 224)) # Resize to 224x224
|
| 166 |
img_array = image.img_to_array(img) # Convert to array
|
| 167 |
img_array = np.expand_dims(img_array, axis=0) # Expand dimensions
|
| 168 |
img_array /= 255.0 # Normalize if needed
|