generated from dopt-python/py311
change array dtype of boxes to more explicit dtype
This commit is contained in:
parent
d5a9071f9d
commit
67e49a47d8
@ -166,7 +166,7 @@ def measure_length(
|
|||||||
# !! should only be newer OpenCV versions
|
# !! should only be newer OpenCV versions
|
||||||
# box = cv2.cv.BoxPoints(rbox) if is_cv2() else cv2.boxPoints(rbox)
|
# box = cv2.cv.BoxPoints(rbox) if is_cv2() else cv2.boxPoints(rbox)
|
||||||
box = cv2.boxPoints(rbox)
|
box = cv2.boxPoints(rbox)
|
||||||
box = np.array(box, dtype="int")
|
box = np.array(box, dtype=np.int32)
|
||||||
# order the points in the contour in top-left, top-right, bottom-right, and bottom-left
|
# order the points in the contour in top-left, top-right, bottom-right, and bottom-left
|
||||||
box = perspective.order_points(box)
|
box = perspective.order_points(box)
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user