原因:opencv-python 的版本更新影响
文章来源:https://www.toymoban.com/news/detail-739705.html
cv2.drawMarker(image_sgl, (x_co, y_co), (int(color[0]), int(color[1]), int(color[2])), marker_type, 8, thickness = 3)
cv2.error: OpenCV(4.6.0) :-1: error: (-5:Bad argument) in function 'drawMarker'
> Overload resolution failed:
> - Can't parse 'position'. Sequence item with index 0 has a wrong type
> - Can't parse 'position'. Sequence item with index 0 has a wrong type
我原本的版本是4.6.0.66,需要下降版本到4.5.1.48文章来源地址https://www.toymoban.com/news/detail-739705.html
pip install opencv-python==4.5.1.48 -i https://pypi.douban.com/simple
到了这里,关于报错 cv2.error: OpenCV(4.6.0) :-1: error: (-5:Bad argument) in function ‘drawMarker‘的文章就介绍完了。如果您还想了解更多内容,请在右上角搜索TOY模板网以前的文章或继续浏览下面的相关文章,希望大家以后多多支持TOY模板网!