pip install opencv-python
pip install opencv-contrib-python
#Basic package
pip install opencv-python
#Full package
pip install opencv-contrib-python
sudo pip3 install opencv-contrib-python
pip install opencv-python
# install any one of them to avoid conflicts
# I prefer 2nd one
pip install opencv-python
pip install opencv-contrib-python
# for linux, you may have two python version on your pc
# so -
pip3 install opencv-contrib-python
pip2 install opencv-python==4.2.0.32
! pip install opencv-python
# www.athulmathew.com
sudo apt-get install libopencv-dev # ubuntu c++
download required packages from below link:
https://docs.opencv.org/4.0.1/d7/d9f/tutorial_linux_install.html
NOTE: you can download required packages by "sudo apt-get install <packages>" or
download source code by git using above link
tags: ubuntu, c++, opencv 4 version