
Determine the CUDA architecture versionĬMake needs a CUDA_ARCH_BIN flag to be set in order to compile the binaries with the correct CUDA architecture. These modules are required to use the CUDA funcionality with OpenCV. We will also be downloading the OpenCV’s extra modules (CMake flag -D OPENCV_EXTRA_MODULES_PATH) repository. Now, download the OpenCV repository using Git: $ git clone formats: $ sudo apt install libpng-dev libjpeg-dev libopenexr-dev libtiff-dev libwebp-dev The next dependencies are optional but add the latest support for PNG, JPEG, JPEG2000, TIFF, WebP, etc.

GTK is requried for GUI features, Camera support (v4l), Media Support (ffmpeg, gstreamer…), etc.: $ sudo apt install libavcodec-dev libavformat-dev libswscale-dev $ sudo apt install libgstreamer-plugins-base1.0-dev libgstreamer1.0-dev $ sudo apt install libgtk-3-dev To support Python 3 installations, we need Python (it comes pre-installed with most Ubuntu versions), Python-devel and Numpy: $ sudo apt install python3 python3-dev python3-numpy

DependenciesĬMake and GCC are required to configure the installation and compile the project: $ sudo apt install cmake $ sudo apt install gcc g++ Once you are set, let’s continue with the dependencies.
