vishalkatheriya
commited on
Update app.py
Browse files
app.py
CHANGED
@@ -11,7 +11,7 @@ image_processor = AutoImageProcessor.from_pretrained(repo_name)
|
|
11 |
model = AutoModelForImageClassification.from_pretrained(repo_name)
|
12 |
|
13 |
# Streamlit UI
|
14 |
-
st.title("Image Classification with Streamlit")
|
15 |
|
16 |
# Option to select image input method
|
17 |
method = st.radio("Select input method", ("Upload Image", "Paste Image URL"))
|
@@ -30,7 +30,8 @@ elif method == "Paste Image URL":
|
|
30 |
image = Image.open(BytesIO(response.content))
|
31 |
|
32 |
if image:
|
33 |
-
|
|
|
34 |
st.write("")
|
35 |
st.write("Classifying...")
|
36 |
|
|
|
11 |
model = AutoModelForImageClassification.from_pretrained(repo_name)
|
12 |
|
13 |
# Streamlit UI
|
14 |
+
st.title("Bottomwear Image Classification with Streamlit")
|
15 |
|
16 |
# Option to select image input method
|
17 |
method = st.radio("Select input method", ("Upload Image", "Paste Image URL"))
|
|
|
30 |
image = Image.open(BytesIO(response.content))
|
31 |
|
32 |
if image:
|
33 |
+
resized_image = image.resize((500, 300))
|
34 |
+
st.image(resized_image, caption="Uploaded Image", use_column_width=True)
|
35 |
st.write("")
|
36 |
st.write("Classifying...")
|
37 |
|