Update app.py
Browse files
app.py
CHANGED
@@ -20,7 +20,7 @@ import gradio as gr
|
|
20 |
device = "cuda" if torch.cuda.is_available() else "cpu"
|
21 |
detection_model = YOLO('yolov8/runs/detect/yolov8s-custom-detection/weights/best.pt').to(device)
|
22 |
structure_model = YOLO('yolov8/runs/detect/yolov8s-custom-structure-all/weights/best.pt').to(device)
|
23 |
-
ocr_model = PaddleOCR(use_angle_cls=True, lang="
|
24 |
|
25 |
detection_class_names = ['table', 'table rotated']
|
26 |
structure_class_names = [
|
|
|
20 |
device = "cuda" if torch.cuda.is_available() else "cpu"
|
21 |
detection_model = YOLO('yolov8/runs/detect/yolov8s-custom-detection/weights/best.pt').to(device)
|
22 |
structure_model = YOLO('yolov8/runs/detect/yolov8s-custom-structure-all/weights/best.pt').to(device)
|
23 |
+
ocr_model = PaddleOCR(use_angle_cls=True, lang=uk", det_limit_side_len=1920) # TODO use large det_limit_side_len to get better OCR result
|
24 |
|
25 |
detection_class_names = ['table', 'table rotated']
|
26 |
structure_class_names = [
|