Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

You are using OpenCV 4.1.0. the error telling you that you must add array at the end of findContours Try this:

contours = cv2.findContours(thresh,cv2.RETR_EXTERNAL,cv2.CHAIN_APPROX_SIMPLE)[0]

You are using OpenCV 4.1.0. the The error telling you that you must add array at the end of findContours Try this:

contours = cv2.findContours(thresh,cv2.RETR_EXTERNAL,cv2.CHAIN_APPROX_SIMPLE)[0]