在使用opencv中的cv2.imshow显示图片的时候总会出现如下错误:
The function is not implemented. Rebuild the library with Windows, GTK+ 2.x or Cocoa support. If you are on Ubuntu or Debian, install libgtk2.0-dev and pkg-config, then re-run cmake or configure script in function ‘cvShowImage’
查找了很多资料发现是在安装opencv的时候安装顺序出现了问题,于是执行下面代码,重新安装
imshow就能成功显示图片了文章来源:https://www.toymoban.com/news/detail-725669.html
pip uninstall opencv-python
pip uninstall opencv-contrib-python
pip install opencv-contrib-python
pip install opencv-python
参考资料:
https://stackoverflow.com/questions/67120450/error-2unspecified-error-the-function-is-not-implemented-rebuild-the-libra文章来源地址https://www.toymoban.com/news/detail-725669.html
到了这里,关于解决opencv中使用cv2.imshow不显示图片问题的文章就介绍完了。如果您还想了解更多内容,请在右上角搜索TOY模板网以前的文章或继续浏览下面的相关文章,希望大家以后多多支持TOY模板网!