We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 260b283 commit 026d1ecCopy full SHA for 026d1ec
python/rapidocr/utils/typings.py
@@ -22,7 +22,11 @@ def __post_init__(self):
22
def to_json(self):
23
pass
24
25
- def to_paddleocr_format(self):
+ def to_paddleocr_format(self) -> List[List[List[float]], List[Tuple[str, float]]]:
26
rec_res = list(zip(self.txts, self.scores))
27
+ dt_boxes = [v.tolist() for v in self.boxes]
28
- print("ok")
29
+ final_res = []
30
+ for box, rec in zip(dt_boxes, rec_res):
31
+ final_res.append([box, list(rec)])
32
+ return final_res
0 commit comments