Opencv incompatible

I compiled opencv 3.4.1 on jetson nano,the build info in the below.

but ,I write a sample c++ code to use check envirment it tell INCOMPATIBLE.

General configuration for OpenCV 3.4.1 =====================================
Version control: unknown

Extra modules:
Location (extra): /root/opencv_contrib-3.4.1/modules
Version control (extra): unknown

Timestamp: 2019-09-23T16:53:13Z
Host: Linux 4.9.140-tegra aarch64
CMake: 3.10.2
CMake generator: Unix Makefiles
CMake build tool: /usr/bin/make
Configuration: Release

CPU/HW features:
Baseline: NEON FP16
required: NEON
disabled: VFPV3

Built as dynamic libs?: YES
C++11: YES
C++ Compiler: /usr/bin/c++ (ver 7.4.0)
C++ flags (Release): -fsigned-char -W -Wall -Werror=return-type -Werror=non-virtual-dtor -Werror=address -Werror=sequence-point -Wformat -Werror=format-security -Wmissing-declarations -Wundef -Winit-self -Wpointer-arith -Wshadow -Wsign-promo -Wuninitialized -Winit-self -Wno-narrowing -Wno-delete-non-virtual-dtor -Wno-comment -Wno-implicit-fallthrough -fdiagnostics-show-option -pthread -fomit-frame-pointer -ffunction-sections -fdata-sections -fvisibility=hidden -fvisibility-inlines-hidden -O3 -DNDEBUG -DNDEBUG
C++ flags (Debug): -fsigned-char -W -Wall -Werror=return-type -Werror=non-virtual-dtor -Werror=address -Werror=sequence-point -Wformat -Werror=format-security -Wmissing-declarations -Wundef -Winit-self -Wpointer-arith -Wshadow -Wsign-promo -Wuninitialized -Winit-self -Wno-narrowing -Wno-delete-non-virtual-dtor -Wno-comment -Wno-implicit-fallthrough -fdiagnostics-show-option -pthread -fomit-frame-pointer -ffunction-sections -fdata-sections -fvisibility=hidden -fvisibility-inlines-hidden -g -O0 -DDEBUG -D_DEBUG
C Compiler: /usr/bin/cc
C flags (Release): -fsigned-char -W -Wall -Werror=return-type -Werror=non-virtual-dtor -Werror=address -Werror=sequence-point -Wformat -Werror=format-security -Wmissing-declarations -Wmissing-prototypes -Wstrict-prototypes -Wundef -Winit-self -Wpointer-arith -Wshadow -Wuninitialized -Winit-self -Wno-narrowing -Wno-comment -Wno-implicit-fallthrough -fdiagnostics-show-option -pthread -fomit-frame-pointer -ffunction-sections -fdata-sections -fvisibility=hidden -O3 -DNDEBUG -DNDEBUG
C flags (Debug): -fsigned-char -W -Wall -Werror=return-type -Werror=non-virtual-dtor -Werror=address -Werror=sequence-point -Wformat -Werror=format-security -Wmissing-declarations -Wmissing-prototypes -Wstrict-prototypes -Wundef -Winit-self -Wpointer-arith -Wshadow -Wuninitialized -Winit-self -Wno-narrowing -Wno-comment -Wno-implicit-fallthrough -fdiagnostics-show-option -pthread -fomit-frame-pointer -ffunction-sections -fdata-sections -fvisibility=hidden -g -O0 -DDEBUG -D_DEBUG
Linker flags (Release):
Linker flags (Debug):
ccache: NO
Precompiled headers: NO
Extra dependencies: dl m pthread rt /usr/lib/aarch64-linux-gnu/ cudart nppc nppial nppicc nppicom nppidei nppif nppig nppim nppist nppisu nppitc npps cublas cufft -L/usr/local/cuda-10.0/lib64
3rdparty dependencies:

OpenCV modules:
To be built: aruco bgsegm bioinspired calib3d ccalib core cudaarithm cudabgsegm cudacodec cudafeatures2d cudafilters cudaimgproc cudalegacy cudaobjdetect cudaoptflow cudastereo cudawarping cudev datasets dnn dnn_objdetect dpm face features2d flann freetype fuzzy hfs highgui img_hash imgcodecs imgproc java_bindings_generator line_descriptor ml objdetect optflow phase_unwrapping photo plot python2 python_bindings_generator reg rgbd saliency shape stereo stitching structured_light superres surface_matching text tracking ts video videoio videostab xfeatures2d ximgproc xobjdetect xphoto
Disabled: js python3 world
Disabled by dependency: -
Unavailable: cnn_3dobj cvv dnn_modern hdf java matlab ovis sfm viz
Applications: tests perf_tests apps
Documentation: NO
Non-free algorithms: NO

GTK+: YES (ver 2.24.32)
GThread : YES (ver 2.56.4)
GtkGlExt: NO

Media I/O:
ZLib: zlib (ver 1.2.11)
JPEG: libjpeg (ver 90)
WEBP: build (ver encoder: 0x020e)
PNG: /usr/lib/aarch64-linux-gnu/ (ver 1.6.34)
TIFF: /usr/lib/aarch64-linux-gnu/ (ver 42 / 4.0.9)
JPEG 2000: build (ver 1.900.1)

Video I/O:
avcodec: YES (ver 57.107.100)
avformat: YES (ver 57.83.100)
avutil: YES (ver 55.78.100)
swscale: YES (ver 4.8.100)
avresample: NO
base: YES (ver 1.14.5)
video: YES (ver 1.14.5)
app: YES (ver 1.14.5)
riff: YES (ver 1.14.5)
pbutils: YES (ver 1.14.5)
libv4l/libv4l2: NO
v4l/v4l2: linux/videodev2.h
gPhoto2: NO

Parallel framework: TBB (ver 2017.0 interface 9107)

Trace: YES (built-in)

Other third-party libraries:
Lapack: NO
Eigen: YES (ver 3.3.4)
Custom HAL: YES (carotene (ver 0.0.1))
Protobuf: build (3.5.1)

NVIDIA GPU arch: 62

Python 2:
Interpreter: /usr/bin/python2.7 (ver 2.7.15)
Libraries: /usr/lib/aarch64-linux-gnu/ (ver 2.7.15+)
numpy: /usr/lib/python2.7/dist-packages/numpy/core/include (ver 1.13.3)
packages path: lib/python2.7/dist-packages

Python (for build): /usr/bin/python2.7

ant: NO
Java wrappers: NO
Java tests: NO

Matlab: NO

Install to: /usr

invoking >>>cv::cuda::getCudaEnabledDeviceCount()
return -1,
and some info from opencv :

OpenCV(3.4.1) Error: Gpu API call (CUDA driver version is insufficient for CUDA runtime version) in allocate, file /root/opencv-3.4.1/modules/core/src/cuda/, line 116
terminate called after throwing an instance of ‘cv::Exception’
what(): OpenCV(3.4.1) /root/opencv-3.4.1/modules/core/src/cuda/ error: (-217) CUDA driver version is insufficient for CUDA runtime version in function allocate


Does OpenCV 3.4.1 support CUDA 10.0? Are we sure that all versions are compatible?

hi leef918:
from error message: cuda driver insufficient . check it first
for CUDA 10.0 (10.0.130) driver version should >= 410.48

How to detemine the driver verion on jetson nano?
No tools like nvidia-smi on jetson nano.

I check the driver of Jetson plantform, the GPU driver for Jetson platform is integrated into the OS image.

So, do you flash the system and install OpenCV from the same JetPack version?
“insufficient error” in Jetson usually occurs when the system and packages comes from different version, which leads to incompatible issue.

Hi FelipeVW:
in Jetson, the OS and install OpenCV MUST come from the same JetPack version which make version compatible, otherwise no guarantee provided from NV

1 Like