diff --git a/craft_utils.py b/craft_utils.py index 43c1357..509c962 100755 --- a/craft_utils.py +++ b/craft_utils.py @@ -236,7 +236,7 @@ def getDetBoxes(textmap, linkmap, text_threshold, link_threshold, low_text, poly def adjustResultCoordinates(polys, ratio_w, ratio_h, ratio_net = 2): if len(polys) > 0: - polys = np.array(polys) + polys = np.array(polys, dtype=object) for k in range(len(polys)): if polys[k] is not None: polys[k] *= (ratio_w * ratio_net, ratio_h * ratio_net)