2 files + 6 − 4 Inline Compare changes Side-by-side Inline Show whitespace changes Files 2 dan/ocr/predict/attention.py +5 −3 Original line number Diff line number Diff line Loading @@ -219,15 +219,17 @@ def get_predicted_polygons_with_confidence( max_object_height=max_object_height, size=(resized_sizes[1], resized_sizes[0]), ) start_index += len(text_piece) + offset if not polygon: continue # Apply image resizing to polygon polygon["polygon"] = resize_polygon( polygon=polygon["polygon"], original_image_size=original_sizes, ratios=ratios, ) start_index += len(text_piece) + offset if not polygon: continue polygon["text"] = text_piece polygon["text_confidence"] = confidence polygons.append(polygon) Loading pyproject.toml +1 −1 Original line number Diff line number Diff line Loading @@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta" [project] name = "atr-dan" version = "0.2.2a1" version = "0.2.2b1" description = "Teklia DAN" readme = "README.md" requires-python = ">=3.10" Loading
dan/ocr/predict/attention.py +5 −3 Original line number Diff line number Diff line Loading @@ -219,15 +219,17 @@ def get_predicted_polygons_with_confidence( max_object_height=max_object_height, size=(resized_sizes[1], resized_sizes[0]), ) start_index += len(text_piece) + offset if not polygon: continue # Apply image resizing to polygon polygon["polygon"] = resize_polygon( polygon=polygon["polygon"], original_image_size=original_sizes, ratios=ratios, ) start_index += len(text_piece) + offset if not polygon: continue polygon["text"] = text_piece polygon["text_confidence"] = confidence polygons.append(polygon) Loading
pyproject.toml +1 −1 Original line number Diff line number Diff line Loading @@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta" [project] name = "atr-dan" version = "0.2.2a1" version = "0.2.2b1" description = "Teklia DAN" readme = "README.md" requires-python = ">=3.10" Loading