Ask Your Question
0

Issues installing OpenCV-Python prebuilts for Windows 10

asked 2020-06-08 08:22:29 -0600

NaBUru38 gravatar image

Hello, I'm trying to install the OpenCV-Python prebuilts. I'm using the latest Visual Studio Code for Windows 10, and following these instructions.

The instructions say: * 5. Goto opencv/build/python/2.7 folder. * 6. Copy cv2.pyd to C:/Python27/lib/site-packages.

Since I'm using Python 3.8, I copied cv2.cp38-win_amd64.pyd from "C:\Program Files\Opencv\build\python\cv2\python-3.8\" to "C:\Program Files\Python\Python38\Lib\site-packages".

When I open a Python terminal and run "import cv2", I get an "ImportError: DLL load failed while importing cv2: The specified module could not be found."

Any suggestions? Thanks!

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
1

answered 2020-06-09 05:39:28 -0600

I ran into the same problem. Later I just used pip to install a module called "opencv-python" and it's working well. Just simply open cmd or powershell and type:

pip install opencv-python

If you have python2 installed alongside python3, you need to type:

pip3 install opencv-python

Hopefully this will work.

edit flag offensive delete link more

Comments

Thank you!

NaBUru38 gravatar imageNaBUru38 ( 2020-06-09 07:43:13 -0600 )edit

Question Tools

1 follower

Stats

Asked: 2020-06-08 08:22:29 -0600

Seen: 2,055 times

Last updated: Jun 08 '20