1 | initial version |
problem is here:
image = cv2.imread(image_path)
like any other python noob, you NEVER check, if the image was actually loaded, and then you get errors in the NEXT lines ...
please add a check here:
if image==None:
print("invalid image ! ", filename)
return
2 | No.2 Revision |
problem is here:
image = cv2.imread(image_path)
like any other python noob, you NEVER check, if the image was actually loaded, and then you get errors in the NEXT lines ...
please add a check here:
if image==None:
print("invalid image ! ", filename)
return
return None, None