Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Problem install opencv 4.0 on windows 7 with pytho

Download newest package from https://sourceforge.net/projects/opencvlibrary/files/4.0.0/opencv-4.0.0-vc14_vc15.exe/download.

Open a cmd and cd to pathtoopencv\build\python

RUN:

python setup.py install

SUCCESS Installed

Question:

If path doesn't, import cv2 can be done!

IF path changed, import cv2 fail.

error

['C:\ProgramData\Anaconda3\lib\site-packages\opencv-4.0.0-py3.7.egg\cv2\. ./../python/cv2/python-3.7', '', 'C:\ProgramData\Anaconda3\Scripts', 'C:\Pro gramData\Anaconda3\python37.zip', 'C:\ProgramData\Anaconda3\DLLs', 'C:\Pro gramData\Anaconda3\lib', 'C:\ProgramData\Anaconda3', 'C:\ProgramData\Anaco nda3\lib\site-packages', 'C:\ProgramData\Anaconda3\lib\site-packages\open cv-4.0.0-py3.7.egg', 'C:\ProgramData\Anaconda3\lib\site-packages\win32', 'C :\ProgramData\Anaconda3\lib\site-packages\win32\lib', 'C:\ProgramData\An aconda3\lib\site-packages\Pythonwin', 'C:\ProgramData\Anaconda3\lib\site- packages\IPython\extensions', 'C:\Users\Administrator\.ipython']

ImportError: ERROR: recursion is detected during loading of "cv2" binary extensi ons. Check OpenCV installation.

It seems like 'C:\ProgramData\Anaconda3\lib\site-packages\opencv-4.0.0-py3.7.egg\cv2\. ./../python/cv2/python-3.7' is set to wrong location.

So, how can i install with right command.

click to hide/show revision 2
None

updated 2018-11-22 04:50:20 -0600

berak gravatar image

Problem install opencv 4.0 on windows 7 with pytho

Download newest package from https://sourceforge.net/projects/opencvlibrary/files/4.0.0/opencv-4.0.0-vc14_vc15.exe/download.

Open a cmd and cd to pathtoopencv\build\python

RUN:

python setup.py install

SUCCESS Installed

python setup.py installQuestion:

SUCCESS Installed

Question:

If path doesn't, import cv2 can be done!

IF path changed, import cv2 fail.

error

['C:\ProgramData\Anaconda3\lib\site-packages\opencv-4.0.0-py3.7.egg\cv2\. ./../python/cv2/python-3.7', '', 'C:\ProgramData\Anaconda3\Scripts', 'C:\Pro gramData\Anaconda3\python37.zip', 'C:\ProgramData\Anaconda3\DLLs', 'C:\Pro gramData\Anaconda3\lib', 'C:\ProgramData\Anaconda3', 'C:\ProgramData\Anaco nda3\lib\site-packages', 'C:\ProgramData\Anaconda3\lib\site-packages\open cv-4.0.0-py3.7.egg', 'C:\ProgramData\Anaconda3\lib\site-packages\win32', 'C :\ProgramData\Anaconda3\lib\site-packages\win32\lib', 'C:\ProgramData\An aconda3\lib\site-packages\Pythonwin', 'C:\ProgramData\Anaconda3\lib\site- packages\IPython\extensions', 'C:\Users\Administrator\.ipython']error:

['C:\\ProgramData\\Anaconda3\\lib\\site-packages\\opencv-4.0.0-py3.7.egg\\cv2\\.
./../python/cv2/python-3.7', '', 'C:\\ProgramData\\Anaconda3\\Scripts', 'C:\\Pro
gramData\\Anaconda3\\python37.zip', 'C:\\ProgramData\\Anaconda3\\DLLs', 'C:\\Pro
gramData\\Anaconda3\\lib', 'C:\\ProgramData\\Anaconda3', 'C:\\ProgramData\\Anaco
nda3\\lib\\site-packages', 'C:\\ProgramData\\Anaconda3\\lib\\site-packages\\open
cv-4.0.0-py3.7.egg', 'C:\\ProgramData\\Anaconda3\\lib\\site-packages\\win32', 'C
:\\ProgramData\\Anaconda3\\lib\\site-packages\\win32\\lib', 'C:\\ProgramData\\An
aconda3\\lib\\site-packages\\Pythonwin', 'C:\\ProgramData\\Anaconda3\\lib\\site-
packages\\IPython\\extensions', 'C:\\Users\\Administrator\\.ipython']

ImportError: ERROR: recursion is detected during loading of "cv2" binary extensi
ons. Check OpenCV installation.

installation.

It seems like 'C:\ProgramData\Anaconda3\lib\site-packages\opencv-4.0.0-py3.7.egg\cv2\. ./../python/cv2/python-3.7' is set to wrong location.

So, how can i install with right command.