1 | initial version |
the problem is here:
image, contours, heirarchy = cv2.findContours(edged, cv2.RETR_EXTERNAL, cv2.CHAIN_APPROX_NONE)
this will replace your 3 channels image
with a 1 channel one, and you cannot draw something green into that (it'll be invisible)
instead, try:
_, contours, heirarchy = cv2.findContours(edged, cv2.RETR_EXTERNAL, cv2.CHAIN_APPROX_NONE)
now drawContours should work as expected ;)