Bug: Python+VSCode-Module 'cv2' has no 'imshow' member

Today in VSCode cv2 in the python module, although the normal operation of the program, but under the code cv2 red wavy line error, the content is "Module 'cv2' has no 'imshow' member"

solution

VSCode open the File -> Preferences -> Settings and enter pylintArgs in search settings, edit settings.json in the "python.linting.pylintArgs": [ "-generate-members"] is written to the right users settings can be.

Reference links:
https://www.jianshu.com/p/ab72e830b2a9
https://www.bilibili.com/video/av33693850/

Published 52 original articles · won praise 4 · Views 2162

Guess you like

Origin blog.csdn.net/qq_42191914/article/details/103369317