Merge pull request #1537 from kevin-keraudren/ellipse-round-radius

the output of hough_ellipse needs to be rounded before being truncated
This commit is contained in:
Juan Nunez-Iglesias
2015-06-01 10:58:33 +10:00
@@ -127,11 +127,8 @@ result = hough_ellipse(edges, accuracy=20, threshold=250,
result.sort(order='accumulator')
# Estimated parameters for the ellipse
best = result[-1]
yc = int(best[1])
xc = int(best[2])
a = int(best[3])
b = int(best[4])
best = list(result[-1])
yc, xc, a, b = [int(round(x)) for x in best[1:5]]
orientation = best[5]
# Draw the ellipse on the original image