Upload folder using huggingface_hub
Browse files- postprocessing.py +1 -1
postprocessing.py
CHANGED
|
@@ -20,7 +20,7 @@ def extract_classes_bboxes(text: str):
|
|
| 20 |
|
| 21 |
return classes, bboxes, texts
|
| 22 |
|
| 23 |
-
def transform_bbox_to_original(bbox, original_width, original_height, target_w=
|
| 24 |
# Replicate exact resize logic
|
| 25 |
aspect_ratio = original_width / original_height
|
| 26 |
new_height = original_height
|
|
|
|
| 20 |
|
| 21 |
return classes, bboxes, texts
|
| 22 |
|
| 23 |
+
def transform_bbox_to_original(bbox, original_width, original_height, target_w=1664, target_h=2048):
|
| 24 |
# Replicate exact resize logic
|
| 25 |
aspect_ratio = original_width / original_height
|
| 26 |
new_height = original_height
|