Spaces:
Sleeping
Sleeping
Update src/streamlit_app.py
Browse files- src/streamlit_app.py +1 -1
src/streamlit_app.py
CHANGED
|
@@ -180,7 +180,7 @@ def perform_ocr(image, bbox):
|
|
| 180 |
except Exception as e:
|
| 181 |
return f"OCR Error: {str(e)}"
|
| 182 |
|
| 183 |
-
def scale_image_to_fixed_size(image, max_width=
|
| 184 |
"""Scale image to fit within max dimensions while maintaining aspect ratio - NO PADDING"""
|
| 185 |
# Convert to RGB with proper handling
|
| 186 |
if image.mode not in ('RGB', 'RGBA'):
|
|
|
|
| 180 |
except Exception as e:
|
| 181 |
return f"OCR Error: {str(e)}"
|
| 182 |
|
| 183 |
+
def scale_image_to_fixed_size(image, max_width=800, max_height=1000):
|
| 184 |
"""Scale image to fit within max dimensions while maintaining aspect ratio - NO PADDING"""
|
| 185 |
# Convert to RGB with proper handling
|
| 186 |
if image.mode not in ('RGB', 'RGBA'):
|