Skip to content
Snippets Groups Projects

Add predicted objects to predict command

Merged Thibault Lavigne requested to merge 36-add-predicted-objects-to-predict-command into main
All threads resolved!
1 file
+ 3
1
Compare changes
  • Side-by-side
  • Inline
+ 3
1
@@ -2,6 +2,7 @@
import os
import pickle
from pathlib import Path
import cv2
import numpy as np
@@ -100,6 +101,7 @@ class DAN:
extract_objects=False,
word_separators=["\n", " "],
line_separators=["\n"],
start_token=None,
):
"""
Run prediction on an input image.
@@ -352,4 +354,4 @@ def run(
json_filename = f"{output}/{image.stem}.json"
logger.info(f"Saving JSON prediction in {json_filename}")
save_json(json_filename, result)
save_json(Path(json_filename), result)
Loading