Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -474,8 +474,8 @@ def process_image(image_path, mode="fast", rotation=0):
|
|
| 474 |
logger.warning(f"Hardcore mode failed, falling back to predict: {e}")
|
| 475 |
result = ocr.predict(str(image_path))
|
| 476 |
else:
|
| 477 |
-
|
| 478 |
-
|
| 479 |
|
| 480 |
zones = []
|
| 481 |
|
|
|
|
| 474 |
logger.warning(f"Hardcore mode failed, falling back to predict: {e}")
|
| 475 |
result = ocr.predict(str(image_path))
|
| 476 |
else:
|
| 477 |
+
# Use ocr.predict() method (PaddleOCR 2.8+ API)
|
| 478 |
+
result = ocr.predict(str(image_path))
|
| 479 |
|
| 480 |
zones = []
|
| 481 |
|