🏕️解决 opencv 在 pycharm 无代码提示的问题
2023-7-20
| 2023-7-20
0  |  0 分钟
type
status
date
Jul 20, 2023 08:47 AM
slug
summary
tags
category
icon
password
引言:
 

问题现象说明

如题
 

解决过程

方案 1. Update 4.8 Release fixs this issue.

pip install opencv-opencv==4.8.0.74.
pip install opencv-contrib-python==4.8.0.74

方案 2.

Workaround: I got a workaround that works well on Mac and Windows with PyCharm.
Go to the ../site-packages/cv2 and copy the binary file from it to its parent folder.

For Mac OS

Copy ../site-packages/cv2/cv2.abi3.so to ../site-packages/cv2.abi3.so enter image description here

For Windows

Copy ../site-packages/cv2/cv2.pyd to ../site-packages/cv2.pyd enter image description here

And for Ubuntu

we should do the same thing.
 
 
 

总结

遗留问题&思考

NOTE: when your update the opencv-python, don't forget to delete the old abi.so file and copy the new binary to the parent folder.
工作学习
  • 图像编程
  • OpenCV
  • 滑动窗口算法 似乎经常用到改了一下键位. 把 office 键位还原为 hyper 了
    目录