This is the same as gh-89 but rebased onto develop.
This PR fixes the situation in which a ZeroDivisionError is thrown when the ROI line is parallel to the X axis and hence the y1 and y2 values are equal, returning 0 in the subtraction.
The error returned was:
Traceback (most recent call last):
File "./script", line 453, in <module>
fileAnns, message = processImages(conn, scriptParams)
File "./script", line 382, in processImages
processLines(conn, scriptParams, image, lines, lineWidth, f)
File "./script", line 264, in processLines
lineWidth, theZ, theC, theT)
File "./script", line 93, in getLineData
rads = math.atan(float(lineX) / lineY)
ZeroDivisionError: float division
To test - check that the values returned from the script make sense.
/cc @will-moore
This is the same as gh-89 but rebased onto develop.
This PR fixes the situation in which a
ZeroDivisionError
is thrown when the ROI line is parallel to the X axis and hence they1
andy2
values are equal, returning 0 in the subtraction.The error returned was:
To test - check that the values returned from the script make sense. /cc @will-moore