Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -144,9 +144,11 @@ def main():
|
|
144 |
|
145 |
# Apply the perspective warp
|
146 |
transformed_chessboard = cv2.warpPerspective(image, matrix, (chessboard_size, chessboard_size))
|
|
|
147 |
|
148 |
# Convert images to RGB for display
|
149 |
new_img = cv2.cvtColor(transformed_chessboard, cv2.COLOR_BGR2RGB)
|
|
|
150 |
|
151 |
|
152 |
# Resize the image to 224x224
|
|
|
144 |
|
145 |
# Apply the perspective warp
|
146 |
transformed_chessboard = cv2.warpPerspective(image, matrix, (chessboard_size, chessboard_size))
|
147 |
+
|
148 |
|
149 |
# Convert images to RGB for display
|
150 |
new_img = cv2.cvtColor(transformed_chessboard, cv2.COLOR_BGR2RGB)
|
151 |
+
st.image(new_img, caption="Segmented Chessboard", use_column_width=True)
|
152 |
|
153 |
|
154 |
# Resize the image to 224x224
|