Updated app.py
Browse files
app.py
CHANGED
|
@@ -52,7 +52,7 @@ file = st.file_uploader('Upload an Image', type=['jpg', 'jpeg', 'png'])
|
|
| 52 |
if file is not None:
|
| 53 |
# Display uploaded image with reduced size
|
| 54 |
img = Image.open(file)
|
| 55 |
-
st.image(img, caption='Uploaded Image', width=200
|
| 56 |
|
| 57 |
# Extract features from the uploaded image
|
| 58 |
input_image = extract_features_from_images(file, model)
|
|
@@ -65,6 +65,7 @@ if file is not None:
|
|
| 65 |
cols = st.columns(3) # 3 images per row
|
| 66 |
for i, idx in enumerate(indices[0]):
|
| 67 |
product_path = filenames[idx]
|
|
|
|
| 68 |
product_image = Image.open(product_path)
|
| 69 |
|
| 70 |
# Assign columns dynamically
|
|
|
|
| 52 |
if file is not None:
|
| 53 |
# Display uploaded image with reduced size
|
| 54 |
img = Image.open(file)
|
| 55 |
+
st.image(img, caption='Uploaded Image', width=200)
|
| 56 |
|
| 57 |
# Extract features from the uploaded image
|
| 58 |
input_image = extract_features_from_images(file, model)
|
|
|
|
| 65 |
cols = st.columns(3) # 3 images per row
|
| 66 |
for i, idx in enumerate(indices[0]):
|
| 67 |
product_path = filenames[idx]
|
| 68 |
+
st.write(product_path)
|
| 69 |
product_image = Image.open(product_path)
|
| 70 |
|
| 71 |
# Assign columns dynamically
|