OpenCV Contours - need more than 2 values to unpack

前端 未结 9 1697
旧时难觅i
旧时难觅i 2020-12-17 10:39

I am trying to implement contours using the following code..

im = cv2.imread(\'C:\\Users\\Prashant\\Desktop\\T.jpg\')
imgray = cv2.cvtColor(im,cv2.COLOR_BGR2         


        
9条回答
  •  眼角桃花
    2020-12-17 10:43

    • findContours returns only two values. so use just,

    So use

    contours, hierarchy=cv2.findContours(thresh,cv2.RETR_TREE,cv2.CHAIN_APPROX_SIMPLE)
    

提交回复
热议问题