x = coord[i][0]
rois.append(circle(img=img, x=x, y=y, r=radius))
// Draw the circle on the binary image
cv2.circle(all_roi_img, (x, y), radius, 255, -1)
circle_img = cv2.circle(bin_img, (x, y), radius, 255, -1)
overlap_img = overlap_img + circle_img
// Make a list of contours and hierarchies
roi_contour.append(cv2.findContours(np.copy(all_roi_img), cv2.RETR_EXTERNAL,
After Change
x = coord[i][0]
rois.append(circle(img=img, x=x, y=y, r=radius))
// Draw the circle on the binary image
all_roi_img = cv2.circle(all_roi_img, (x, y), radius, 255, -1)
circle_img = cv2.circle(bin_img, (x, y), radius, 255, -1)
overlap_img = overlap_img + circle_img
// Make a list of contours and hierarchies
roi_contour.append(cv2.findContours(np.copy(all_roi_img), cv2.RETR_EXTERNAL,