Hey guys, i'm trying to get the midpoint of my line using this code but it seems wrong. Can anyone advice me please?
M = cv2.moments(ske)
centroid_x = int(M['m10']/M['m00'])
centroid_y = int(M['m01']/M['m00'])
cv2.circle(ske,(centroid_x,centroid_y), 5, (127,0,0), -1)