Opencv install script

=== Ubuntu ===
https://gist.github.com/raulqf/f42c718a658cddc16f9df07ecc627be7 300 stars 
https://gist.github.com/jet-c-21/81bae95b60f0ab3f3b616715e1a76994 nonfree option, cudnn , cuda 10.1 , ubuntu 20.04 
https://gist.github.com/syneart/3e6bb68de8b6390d2eb18bff67767dcb syneart/OpenCV3.2withContrib.sh 
https://gist.github.com/amir-saniyan/b3d8e06145a8569c0d0e030af6d60bea 
https://gist.github.com/YashasSamaga/6d37bc403c0934329b078b4bad98c7f2 cuda fast math option 
https://gist.github.com/graphific/5df4a3a8ba580cabf8e4 test cuda 
https://gist.github.com/okanon/c09669f3ff3351c864742bc2754b01ea list of opencv options 
https://gist.github.com/avtomaton/e410fc17b5e0b17735a2 leveldb, cuda install opencv , ffmpeg 
https://gist.github.com/clamytoe/3424d0201bba0073ff1313e80ffc6328 anaconda virtual environment 
https://gist.github.com/svpino/6840b088bb26975a5291eb5ca59271ff conda 
https://gist.github.com/svcavallar/a95c290cd59b057a904023d8e57db6b6 symlink virtual env 
------------
https://gist.github.com/lukicdarkoo/feffa76b69f0142a4a20de6e3d5f4539 compiler version 
https://gist.github.com/Lauszus/c8ce73f3177d6455c27c neon for rasp 
https://gist.github.com/vietanhdev/97ea3aef3dd44c3bae670c5f75194140 precompiled headers 
https://gist.github.com/piiswrong/87ef716a421f0405e5d09415e54fe8cd mxnet 
---------
https://gist.github.com/OndraZizka/0e08e3931dcc587db92ce0723d7f23e8 picamera links 
https://gist.github.com/rgstephens/fd53e63901586c81029c869ff7786d9d rasa 
https://gist.github.com/Mahedi-61/33f937cc20deefe9d19883917f46e283 centos 
https://gist.github.com/NicolasGoeddel/f809779f02167c565af3457a217b7e42 pose estimation 
https://gist.github.com/jetsonhacks/7a84e3c4b7c3b7fc25d8 jetsonhacks 
https://gist.github.com/jetsonhacks/bec32dccf61528fa658821ef145aa08c canny 
https://gist.github.com/mtc-20/c1f324f70fad774ca6f381c07cb3f19a jetson tx2 
-------
https://gist.github.com/roxlu/1322204eabbd5d42c2d0 build unix dependencies 
https://gist.github.com/lasagnaphil/3e0099816837318e8e8bcab7edcfd5d9 pytorch from source , cuda 
https://gist.github.com/denti/7205065c8f0ce67cf368b9a2d5f76b00 ubuntu 16 
https://gist.github.com/kylehounslow/73c9e5b22c0421a27a17891b9064b0e7 ubuntu 16 
https://gist.github.com/kerryeon/d04aec141b6b7f9c84c9b6d339e11576 openvslam , Slam 
https://gist.github.com/hansheng0512/63959b49014c4d6e53d36e6026a66b4a gstreamer 
------
https://gist.github.com/willprice/abe456f5f74aa95d7e0bb81d5a710b60 raspberry buster install 
https://gist.github.com/gaborvecsei/ad216f214731441bd66a34ae9a2dc3f3 rasp 3b install 
https://gist.github.com/willprice/c216fcbeba8d14ad1138 raspberry jesse 
https://gist.github.com/Mahedi-61/804a663b449e4cdb31b5fea96bb9d561 ubuntu 18 
# opencv’s Python binary (cv2.so) can be installed either in directory site-packages or dist-packages
# for finding corrent location enter
find /usr/local/lib/ -type f -name "cv2*.so"
# my binary is installed in dist-packages. above command shows following output
#/usr/local/lib/python3.6/dist-packages/cv2.cpython-36m-x86_64-linux-gnu.so
# now we need to rename it to cv2.so
cd /usr/local/lib/python3.6/dist-packages/
sudo mv cv2.cpython-36m-x86_64-linux-gnu.so cv2.so 
https://gist.github.com/raulqf/f42c718a658cddc16f9df07ecc627be7 v4.5 with cuda 11 links to https://github.com/keaneflynn/RazerBlade14_OpenCVBuild 
https://gist.github.com/demid5111/6faa590e4fc5813550dd95cc1c538893 
https://gist.github.com/eungbean/0880de7604472219c7e3f6ddb7cebde5 
https://gist.github.com/rodrigobaron/072a85460e46c48e3bee24fe140b9fdb based on milq repo 
https://pastebin.com/urphBrCM , version 3.4.0. mod from https://www.learnopencv.com/install-opencv3-on-ubuntu/. Force Python version
* http://www.python36.com/how-to-install-opencv340-on-ubuntu1604/ 
* https://github.com/jayrambhia/Install-OpenCV/blob/master/Ubuntu/dependencies.sh
* https://docs.opencv.org/3.4.1/d2/de6/tutorial_py_setup_in_ubuntu.html apt packages to install
=== opencv compiled with cuda ===
See cuda opencv compiled with cuda
=== gcc version ===
Install with gcc 4.8.5 for cuda9.2 , gcc7 works with cuda 10. 
=== lfs ===
http://www.linuxfromscratch.org/blfs/view/svn/general/opencv.html
https://stackoverflow.com/questions/46584000/cmake-error-variables-are-set-to-notfound cuda version larger than 8 don't compile
=== windows ===
https://stackoverflow.com/questions/42994813/installing-opencv-on-windows-10-with-python-3-6-and-anaconda-3-6
=== script ===
https://pastebin.com/ZsBMX9xH from http://www.pyimagesearch.com/2016/10/24/ubuntu-16-04-how-to-install-opencv/
=== raspberry pi ===
https://www.pyimagesearch.com/2017/10/09/optimizing-opencv-on-the-raspberry-pi/ Read this first
* https://pastebin.com/KLpEdQ4D Raspberry pi install http://pklab.net/?id=392&lang=EN
* https://pastebin.com/tQwYGmfs if opencv and extras already in folder
* https://gist.github.com/willprice/c216fcbeba8d14ad1138
* https://github.com/jayrambhia/Install-OpenCV
* http://docs.opencv.org/3.1.0/d7/d9f/tutorial_linux_install.html
* https://pastebin.com/0PW0iAbw general scripts, htop, glances etc.
* uses alias file for python to py3.5, no symlinking
* motion
=== opencv 2.4.1 ===
* https://pastebin.com/yQdaWrFz ffmpeg in working
* Ffmpeg install instructions 
* Jasper pastebin install Version 2.4.13
* opencv2.4 install script needs jasper as dependency.
https://github.com/cgwalters/texinfo-git-mirror makeinfo needed for https://github.com/libffi/libffi. 
* http://www.linuxfromscratch.org/blfs/view/cvs/general/libjpeg.html check out jpeg8 for use with opencv https://github.com/libjpeg-turbo/libjpeg-turbo
=== install ===
pip3 install moviepy pillow
* http://pyyaml.org/wiki/LibYAML . Install from source http://pyyaml.org/wiki/PyYAMLDocumentation for faster bindings. Pytorch depends on Yaml. 
* https://pypi.python.org/pypi/PyYAML/3.08
=== pyqt4 ===
* https://pastebin.com/JhcAnjzw install pyqt4, sip, scintilla from source globally for both python2 and three. See https://stackoverflow.com/questions/19856927/how-to-install-sip-and-pyqt-on-a-virtual-environment 
* https://pastebin.com/vXGH0Ch0 newer pyqt4 
* https://gist.github.com/0x414A/8b64178e69d9f8331938.
=== openBlas ===
https://stackoverflow.com/questions/36676449/lapack-blas-openblas-proper-installation-from-source-replace-system-libraries
* https://stackoverflow.com/questions/20328991/can-cmake-findblas-find-openblas
* http://www.netlib.org/blas/. http://www.netlib.org/blas/blas-3.7.0.tgz 
https://stackoverflow.com/questions/20328991/can-cmake-findblas-find-openblas
* https://gist.github.com/rmcgibbo/4950848 Intel MKL libraries, Pytorch looks for these. export variables so pip can find it. his document will walk you through compiling your own scientific python distribution from source, without sudo, on a linux machine. The core numpy and scipy libraries will be linked against Intel MKL for maximum performance
* https://github.com/01org/mkl-dnn
=== ffmpeg enableshared ===
Download ffmpeg from http://ffmpeg.mplayerhq.hu/download.html. 11 The ffmpeg
program has a lesser general public license (LGPL). To use it with non-GPL software
(such as OpenCV), build and use a shared ffmpg library:
$> ./configure --enable-shared
$> make
$> sudo make install
You will end up with: /usr/local/lib/libavcodec.so.*, /usr/local/lib/libavformat.so.*,
/usr/local/lib/libavutil.so.*, and include files under various /usr/local/include/libav*.
To build OpenCV once it is downloaded: 12
$>
$>
$>
$>
mkdir build && cd build
cmake .. && make
sudo make install
sudo ldconfig
After installation is complete, the default installation path is /usr/local/lib/ and
/usr/local/include/opencv2/. Hence you need to add /usr/local/lib/ to /etc/ld.so.conf (and
run ldconfig afterwards) or add it to the LD_LIBRARY_PATH environment variable;
then you are done.
=== package contents ===
https://stackoverflow.com/questions/1157192/what-do-the-dev-packages-in-the-linux-package-repositories-actually-contain
dpkg -L pkgname , libvidxcore-dev
=== links ===
Opencv
Category:Opencv
Category:Linux package installs
Category:Pastebin.com