Fix get_boxes_img_without_det in the python api (#150)

This commit is contained in:
Aurora authored and GitHub committed 2024-01-30 21:33:36 +08:00
1 parent f6865413ac
commit d05b629a27
1 file changed
+1 -1
+1 -1
View File
@@ -126,7 +126,7 @@ class RapidOCR:
def get_boxes_img_without_det(self, h, w):
x0, y0, x1, y1 = 0, 0, w, h
dt_boxes = np.array([[x0, y0], [x1, y0], [x1, y1], [x0, y1]])
dt_boxes = np.float32([[x0, y0], [x1, y0], [x1, y1], [x0, y1]])
dt_boxes = dt_boxes[np.newaxis, ...]
return dt_boxes