Skip to content

Commit f219177

Browse files
committed
Fix issue clovaai#194: added dtype as object inorder to allow creation of array incompatible types, which was causing the error
1 parent e332dd8 commit f219177

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

craft_utils.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -236,7 +236,7 @@ def getDetBoxes(textmap, linkmap, text_threshold, link_threshold, low_text, poly
236236

237237
def adjustResultCoordinates(polys, ratio_w, ratio_h, ratio_net = 2):
238238
if len(polys) > 0:
239-
polys = np.array(polys)
239+
polys = np.array(polys, dtype=object)
240240
for k in range(len(polys)):
241241
if polys[k] is not None:
242242
polys[k] *= (ratio_w * ratio_net, ratio_h * ratio_net)

0 commit comments

Comments
 (0)