yangakw yangakw

opencv+python使用cv2.findContours报错ValueError: too many values to unpack

in 记录read (221) 文章转载请注明来源!

http://answers.opencv.org/question/40329/python-valueerror-too-many-values-to-unpack/

I bet you are using the current OpenCV's master branch: here the return statements have changed, see http://docs.opencv.org/trunk/modules/imgproc/doc/structural_analysis_and_shape_descriptors.html?highlight=cv2.findcontours#cv2.findContours.

Thus, change the correspinding line to:

_, contours, _ = cv2.findContours(skin_ycrcb, cv2.RETR_EXTERNAL, cv2.CHAIN_APPROX_SIMPLE)
jrotty WeChat Pay

微信打赏

jrotty Alipay

支付宝打赏

文章二维码

扫描二维码,在手机上阅读!

发表新评论
博客已运行
© 2017 yangakw
PREVIOUS NEXT
雷姆
拉姆