Closed salam104 closed 3 years ago
Above this line can you write:
mid = int(mid)
Yes, that issue is fixed.
Now am facing division by zero warning on this two lines. x_ratio = (end_points[0] - cx)/(cx - end_points[2]) y_ratio = (cy - end_points[1])/(end_points[3] - cy)
Thanks for your response.
Yeah, you can get that warning when their difference is zero. It won't affect the running of the code, however if you still want to eliminate it you can add an if statement to check if the value is zero before dividing.
Traceback (most recent call last): File "eye_tracker.py", line 189, in
eyeball_pos_left = contouring(thresh[:, 0:mid], mid, img, end_points_left)
TypeError: slice indices must be integers or None or have an index method