Python OpenCV installation error

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

Python OpenCV installation error

ソリューションへジャンプ
31,934件の閲覧回数
nilutpol_k
Contributor I

I am trying to install OpenCV package for Python on my 8MM NavQ Computer using pip package installer.

I am facing the following error:

Defaulting to user installation because normal site-packages is not writeable
Collecting opencv-python
Using cached opencv-python-4.4.0.44.tar.gz (88.9 MB)
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing wheel metadata ... done
Requirement already satisfied: numpy>=1.17.3 in ./.local/lib/python3.8/site-packages (from opencv-python) (1.19.2)
Building wheels for collected packages: opencv-python
Building wheel for opencv-python (PEP 517) ... error
ERROR: Command errored out with exit status 1:
command: /usr/bin/python3 /home/navq/.local/lib/python3.8/site-packages/pip/_vendor/pep517/_in_process.py build_wheel /tmp/tmpr36bqijd
cwd: /tmp/pip-install-8_6xonp2/opencv-python
Complete output (9 lines):
File "/tmp/pip-build-env-sycby3dp/overlay/lib/python3.8/site-packages/skbuild/setuptools_wrap.py", line 560, in setup
cmkr = cmaker.CMaker(cmake_executable)
File "/tmp/pip-build-env-sycby3dp/overlay/lib/python3.8/site-packages/skbuild/cmaker.py", line 95, in __init__
self.cmake_version = get_cmake_version(self.cmake_executable)
File "/tmp/pip-build-env-sycby3dp/overlay/lib/python3.8/site-packages/skbuild/cmaker.py", line 81, in get_cmake_version
raise SKBuildError(
Traceback (most recent call last):

Problem with the CMake installation, aborting build. CMake executable is cmake
----------------------------------------
ERROR: Failed building wheel for opencv-python
Failed to build opencv-python
ERROR: Could not build wheels for opencv-python which use PEP 517 and cannot be installed directly

 

I am having python 3.8.2 with Linux Ubuntu 20.04.1 LTS.

Command used : pip3 install opencv-python

I have tried to solve the issue with all possible solutions but still the issue is not resolved. Please help

 me out.

0 件の賞賛
返信
1 解決策
31,922件の閲覧回数
yokonav
Contributor III

Use this to install: sudo apt install python3-opencv

元の投稿で解決策を見る

2 返答(返信)
25,428件の閲覧回数
Æ-OpticalAntenna
Contributor I

I believe you need to update setuptools as well.

pip3 install -U setuptools pip

0 件の賞賛
返信
31,923件の閲覧回数
yokonav
Contributor III

Use this to install: sudo apt install python3-opencv