Reputation: 79
I want to have Python 3 support in OpenCV, so I read that I need to build my own version with it.
I downloaded OpenCV 3 beta from SourceForge, then I used CMake to create a project, and then compiled it with Visual Studio. It has created lot's of files (not actually the same structure as in precompiled folder from Sourceforge), and also a cv2.pyd. I placed this file into Python34\lib\site-packages, and tried import cv2 in python console, but it says Traceback (most recent call last): File "", line 1, in ImportError: DLL load failed: Module not found.
What I did wrong? Thanks.
Upvotes: 2
Views: 1260
Reputation: 14636
If you want to avoid building your own version, Christoph Gohlke maintains Windows binaries for many Python packages, including the production version of OpenCV 3.0 with Python 3.x bindings, released 4 June 2015:
http://www.lfd.uci.edu/~gohlke/pythonlibs/#opencv
To install, just download the 64-bit or 32-bit .whl
file appropriate for your system, then run pip install [filename]
. Then the instruction import cv2
should work in your Python 3.x interpreter.
Upvotes: 1