简体   繁体   English

OpenCV 有效,但 PyCharm 找不到参考

[英]OpenCV works but PyCharm can't find referances

I've just starting OpenCV tutorial.我刚刚开始 OpenCV 教程。 But previously I've installed it.但之前我已经安装了它。 The modules work properly, but PyCharm doesn't display any documentation of them and display a warning message:这些模块正常工作,但 PyCharm 不显示它们的任何文档并显示警告消息:

Cannot find reference 'imread' in '__init__.py'在“__init__.py”中找不到引用“imread”

Note 1: I'm using Python 3.5.2 and version of the OpenCV is 3.2 (I checked it from python terminal)注 1:我使用的是 Python 3.5.2,OpenCV 的版本是 3.2(我从 python 终端检查过)

Note 2: Python terminal (Inside the PyCharm IDE) displays doc.注 2:Python 终端(在 PyCharm IDE 内)显示 doc。

情况截图

Hope this will help you希望对你有帮助

  1. when cv2.imshow() in give me this information"Cannot find reference 'imshow' in 'init.py | init.py'".当 cv2.imshow() 在给我这个信息时“在 'init.py | init.py' 中找不到参考 'imshow'”。 'imshow' is deprecated, still you can compile it and it works. 'imshow' 已被弃用,您仍然可以编译它并且它可以工作。
  2. Make sure that you have given the correct file and folder name from where you are going to load the image.确保您提供了正确的文件和文件夹名称,您将从那里加载图像。

And please do not change the ' init .py ' file.请不要更改“ init .py”文件。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM