HFUsman commited on
Commit
d5fa4bf
·
verified ·
1 Parent(s): 3295adf

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +9 -4
app.py CHANGED
@@ -84,8 +84,7 @@ def main():
84
 
85
  if uploaded_image is not None:
86
  image = Image.open(uploaded_image)
87
- st.image(image, caption='Uploaded Image', use_container_width=True)
88
-
89
  # Sidebar options
90
  st.sidebar.title("Image Editing Options")
91
 
@@ -115,8 +114,14 @@ def main():
115
  border_thickness = st.sidebar.slider("Border Thickness", 1, 20, 5)
116
  image = add_border(image, border_type, border_color, border_thickness)
117
 
118
- # Display the edited image
119
- st.image(image, caption='Edited Image', use_container_width=True)
 
 
 
 
 
 
120
 
121
  # Download button for edited image
122
  buffered = BytesIO()
 
84
 
85
  if uploaded_image is not None:
86
  image = Image.open(uploaded_image)
87
+
 
88
  # Sidebar options
89
  st.sidebar.title("Image Editing Options")
90
 
 
114
  border_thickness = st.sidebar.slider("Border Thickness", 1, 20, 5)
115
  image = add_border(image, border_type, border_color, border_thickness)
116
 
117
+ # Display the original and edited images side by side
118
+ col1, col2 = st.columns(2)
119
+
120
+ with col1:
121
+ st.image(uploaded_image, caption='Original Image', use_container_width=True)
122
+
123
+ with col2:
124
+ st.image(image, caption='Edited Image', use_container_width=True)
125
 
126
  # Download button for edited image
127
  buffered = BytesIO()