Failed to open TX1 on-board camera

Hi! :-)

I am sorry and I am new here.
This question may have been asked for many times but I still can’t piece them together well.

I have installed OpenCV-3.1.0 on my TX1 following the link below.
https://devtalk.nvidia.com/default/topic/917386/jetson-tx1/usb-3-0-port-unstable-on-jetson-tx1-/post/4835793/#4835793

I successfully compiled my test C++ code as the entire code below

#include "opencv2/opencv.hpp"
#include <iostream>

using namespace std;
using namespace cv;

int main(int, char**)
{
        putenv("GST_DEBUG=*:3");
        VideoCapture cap("nvcamerasrc ! video/x-raw(memory:NVMM), width=(int)1280, height=(int)720,format=(string)I420, framerate=(fraction)24/1 ! nvvidconv flip-method=2 ! video/x-raw, format=(string)BGRx ! videoconvert ! video/x-raw, format=(string)BGR ! appsink"); //open the default camera

        if(!cap.isOpened()) { // check if we succeeded
                cerr << "Fail to open camera " << endl;
                return -1;
        }
        for(;;)
        {
                Mat frame;
                cap >> frame; // get a new frame from camera
                imshow("original", frame);
                waitKey(1);
        }
        // the camera will be deinitialized automatically in VideoCapture destructor
        cap.release();
}

This is how I compiled the code:

g++ -o test -I /home/ubuntu/opencv-3.1.0/include -O2 -g -Wall test.cpp -L /home/ubuntu/opencv-3.1.0/lib -lopencv_core -lopencv_imgproc -l opencv_flann -l opencv_imgcodecs -lopencv_videoio -lopencv_highgui -lopencv_ml -lopencv_video -lopencv_objdetect -lopencv_photo -lopencv_features2d -lopencv_calib3d -lopencv_stitching -lopencv_videostab -lopencv_shape -lopencv_cudaobjdetect -lopencv_cudawarping -lopencv_cudaimgproc

I only got a warning:

test.cpp: In function ‘int main(int, char**)’:
test.cpp:10:24: warning: deprecated conversion from string constant to ‘char*’ [-Wwrite-strings]
  putenv("GST_DEBUG=*:3");
                        ^

Reference:https://devtalk.nvidia.com/default/topic/943129/jetson-tx1/highgui-error-v4l-v4l2-while-opening-camera-with-opencv4tegra-l4t-r24/post/4921383/#4921383

Furthermore, I can execute following command successfully:

gst-launch-1.0 nvcamerasrc fpsRange="30.0 30.0" ! 'video/x-raw(memory:NVMM), width=(int)1920, height=(int)1080, format=(string)I420, framerate=(fraction)30/1' ! nvtee ! nvvidconv flip-method=2 ! 'video/x-raw(memory:NVMM), format=(string)I420' ! nvoverlaysink -e

Nevertheless, when I execute it, it failed to open the on-board camera…/_\

I don’t know why and I’ve done so much research…

Could anyone help, please?

same problem, while I’m trying opencv-2.4.13

if I change define

VideoCapture cap(“nvcamerasrc ! video/x-raw(memory:NVMM), width=(int)1280, height=(int)720,format=(string)I420, framerate=(fraction)24/1 ! nvvidconv flip-method=2 ! video/x-raw, format=(string)BGRx ! videoconvert ! video/x-raw, format=(string)BGR ! appsink”);

to

VideoCapture cap(0);

the camera can open, but can’t see anything(blackscreen).

and it came an error:
HIGHGUI ERROR: V4L/V4L2: VIDIOC_CROPCAP

Have you enabled gstreamer support when configuring your opencv3.1 build ?

I have no TX1 right now with me for checking, but this simple code runs ok (with some latency) on a TX2 with opencv-3.1.0 and 3.2.0.

It doesn’t work with opencv4tegra-2.4.13, I suppose it doesn’t have gstreamer support.

#include <iostream>

#include <opencv2/opencv.hpp>
#include <opencv2/videoio.hpp>
#include <opencv2/highgui.hpp>

int main()
{
    const char* gst =  "nvcamerasrc ! video/x-raw(memory:NVMM), width=(int)1280, height=(int)720, format=(string)I420, framerate=(fraction)120/1 ! \
			nvvidconv flip-method=6 ! video/x-raw, format=(string)BGRx ! \
			videoconvert ! video/x-raw, format=(string)BGR ! \
			appsink";

    cv::VideoCapture cap(gst);

    if(!cap.isOpened())
    {
	std::cout<<"Failed to open camera."<<std::endl;
	return -1;
    }

    unsigned int width = cap.get(CV_CAP_PROP_FRAME_WIDTH); 
    unsigned int height = cap.get(CV_CAP_PROP_FRAME_HEIGHT); 
    unsigned int pixels = width*height;
    std::cout <<"Frame size : "<<width<<" x "<<height<<", "<<pixels<<" Pixels "<<std::endl;

    cv::namedWindow("MyCameraPreview", CV_WINDOW_AUTOSIZE);
    cv::Mat frame_in(width, height, CV_8UC3);

    while(1)
    {
    	if (!cap.read(frame_in)) {
		std::cout<<"Capture read error"<<std::endl;
		break;
    	}
	else {
   		cv::imshow("MyCameraPreview",frame_in);
    		cv::waitKey(1000/120); // let imshow draw and wait for next frame 8 ms for 120 fps
	}	
    }

    cap.release();

    return 0;
}

Just compiled like you for opencv-3.1.0:

export LD_LIBRARY_PATH=/usr/local/cuda/nvvm/lib:/usr/local/cuda/lib64:/usr/local/opencv-3.1.0/lib
g++ -I/usr/local/opencv-3.1.0/include simple_video.cpp -L/usr/local/opencv-3.1.0/lib -lopencv_core -lopencv_videoio -lopencv_highgui -o simple_video

Can you give it a try ?

Hi Honey_Patouceul,

Thank you so much for your code! However I still failed to open the camera. T_T

I even remaked the OpenCV 3.1.0 for GSTREAMER support using the command below

cmake -DWITH_CUDA=ON -DCUDA_ARCH_BIN="5.3" -DCUDA_ARCH_PTX="" -DBUILD_TESTS=OFF -DBUILD_PERF_TESTS=OFF -DCUDA_FAST_MATH=ON  -DWITH_GSTREAMER=ON -DCMAKE_INSTALL_PREFIX=/usr/local/opencv-3.1.0 ..

I followed your instruction:


<ol>export LD_LIBRARY_PATH=/usr/local/cuda/nvvm/lib:/usr/local/cuda/lib64:/usr/local/opencv-3.1.0/lib :$LD_LIBRARY_PATH
g++ -I/usr/local/opencv-3.1.0/include test.cpp -L/usr/local/opencv-3.1.0/lib -lopencv_core -lopencv_videoio -lopencv_highgui -o test
</ol>

Is there something that I am missing?
Thanks a lot! :-)

This code also works fine on my TX1 (R24.2.1 using opencv-3.2.0) in Ubuntu GUI.

I notice your cmake command for opencv doesn’t set CMAKE_BUILD_TYPE=RELEASE.
Check this link for configuration/build/install : http://dev.t7.ai/jetson/opencv/

Furthermore, what is your L4T release ?

head -1 /etc/nv_tegra_release

In older versions, it might have some problems/limitations, but it should be fine from R24.

Could you post the errors you are seeing ?

If you use a device special file in “/dev/”, e.g., “/dev/video0”, be sure your user has permission, especially if it isn’t the ubuntu account (sometimes people don’t mention using non-default accounts, and sometimes those don’t have GPU permissions). Try sudo.

my L4T version is : R24 (release), REVISION: 2.1,

and I have done the following step:

  1. purge opencv2.4.3
    2 cmake make -j4 install opencv3.2 to TX1 board 。

  2. gst-launch-1.0 nvcamerasrc fpsRange=“30.0 30.0” ! ‘video/x-raw(memory:NVMM), width=(int)1920, height=(int)1080, format=(string)I420, framerate=(fraction)30/1’ ! nvtee ! nvvidconv flip-method=2 ! ‘video/x-raw(memory:NVMM), format=(string)I420’ ! nvoverlaysink -e is work well

  3. but if I try :
    cap = cv2.VideoCapture("v4l2src ! video/x-raw(memory:NVMM), width=(int)1280, height=(int)720,format=(string)I420, framerate=(fraction)24/1 ! nvvidconv flip-method=2 ! video/x-raw, format=(string)BGRx ! videoconvert ! video/x-raw, format=(string)BGR ! xvimagesink ")

    No error with python code ,but nothing is display , who cantell me why ?
    ( usb and IPC camera is work fine with my TX1 board)

    who can help me ?????
    this trouble has block my development process for a long time .thanks a lot! ahead .

For onboard camera, from nvcamerasrc to xvimagesink, you can use :

gst-launch-1.0 nvcamerasrc ! 'video/x-raw(memory:NVMM), width=1280, height=720,format=I420, framerate=24/1' ! nvvidconv flip-method=6 ! 'video/x-raw, format=I420' ! xvimagesink

.

If you want to use it from opencv, you should change the end of the pipe to receive BGR frames into appsink (your opencv application):

cap = cv2.VideoCapture("nvcamerasrc ! video/x-raw(memory:NVMM), width=(int)1280, height=(int)720, format=(string)I420, framerate=(fraction)24/1 ! \
			nvvidconv flip-method=6 ! video/x-raw, format=(string)I420 ! \
			videoconvert ! video/x-raw, format=(string)BGR ! \
			appsink")

and you should be able to process frames in cv::Mat and display these with cv::imshow() as shown in the example above.

The onboard camera is a bayer sensor. If you use v4l2src, you will get frames in bayer format, so you will have to debayer it. nvcamerasrc will do that efficiently with HW.

import sys
import cv2

def read_cam():
cap = cv2.VideoCapture(“nvcamerasrc ! video/x-raw(memory:NVMM), width=(int)1280, height=(int)720, format=(string)I420, framerate=(fraction)24/1 ! nvvidconv flip-method=6 ! video/x-raw, format=(string)I420 ! videoconvert ! video/x-raw, format=(string)BGR ! appsink”)
#cap = cv2.VideoCapture( 1)
if cap.isOpened():
cv2.namedWindow(“demo”, cv2.WINDOW_AUTOSIZE)
while True:
ret_val, img = cap.read();
cv2.imshow(‘demo’,img)
cv2.waitKey(10)
else:
print “camera open failed”

cv2.destroyAllWindows()

if name == ‘main’:
read_cam()

Hi Honey_Patouceul :
thanks a lot ! but with above python code , the On_board camera has no work still ???
if I use cap = cv2.VideoCapture( 1) , the usb camera is work well …what is
wrong with the on board camera ???

Have you enabled gstreamer-1.0 support when building your opencv-3.2 library ?

yeah, when i used cmake-gui for configure , I have checked the configure result , gstreamer-1.0 is enabled , the

detail version is gstreamer_1.8.3 , if have any other items need to check ??

You user must have permission to use the GPU. Most often this would be done by having your user be a member of group “video”. By default users ubuntu and nvidia are members of this group, plus of course root does not need to be a member (using sudo). If your user is not one of these defaults, then add the user to group video.

Do you have opencv4tegra or other opencv version installed (especially in /usr/include and /usr/libs) ?

ls /usr/include/opencv*
ls /usr/lib/libopencv*

I’m not familiar with python interface, but what gives:

cv2.__version__

You have to use the “-l” option to ls or it won’t tell you owner and group. Also, this won’t matter for linked libraries since the system is doing the linking…knowing what user and group ownership matters is for files in “/dev/” (your camera program accesses this directly, not indirectly through a linker). Typically a video program or camera program will name that file when starting up in order to know which camera you are specifying, e.g., directly accessed “/dev/video0” permissions matter, indirectly linker accessed “libopencv.so” does not matter for owner/group. Which device special file in “/dev/” is your camera assigned to?

Sorry if my post was confusing…These ‘ls’ were mainly intended to detect a opencv4tegra remaining installed in this standard path.

If empty and you have installed opencv-3.2.0 elsewhere, it should be ok.

Dear two ,

 thanks for your comments ! I checked these item which you ment!  and post the result  as below:

ubuntu@tegra-ubuntu:~ groups ubuntu # I used system default user "ubuntu" ubuntu : ubuntu adm dialout sudo audio video ubuntu@tegra-ubuntu:~ ls /usr/include/opencv*
ls: cannot access ‘/usr/include/opencv*’: No such file or directory
ubuntu@tegra-ubuntu:~ ls /usr/lib/libopencv* ls: cannot access '/usr/lib/libopencv*': No such file or directory ubuntu@tegra-ubuntu:~ cv2.version
-bash: cv2.version: command not found
ubuntu@tegra-ubuntu:~ pkg-config --modversion opencv 3.2.0 ubuntu@tegra-ubuntu:~ ls /dev |grep video*
video0

It seems no wrong with it,
which items I need to check also ???

Just now , I checked the libopencv* ,the result as below:
if I used the command "sudo apt-get purge to uninstall opencv2.4.3 is not very thorough??

ubuntu@tegra-ubuntu:~$ sudo find / -name libopencv*
/home/ubuntu/OpenCV4Tegra/libopencv4tegra-repo_2.4.13-17-g5317135_arm64_l4t-r24.deb
find: ‘/run/user/1000/gvfs’: Permission denied
/var/cache/apt/archives/libopencv-video2.4v5_2.4.9.1+dfsg-1.5ubuntu1_arm64.deb
/var/cache/apt/archives/libopencv-features2d2.4v5_2.4.9.1+dfsg-1.5ubuntu1_arm64.deb
/var/cache/apt/archives/libopencv-calib3d2.4v5_2.4.9.1+dfsg-1.5ubuntu1_arm64.deb
/var/cache/apt/archives/libopencv-flann2.4v5_2.4.9.1+dfsg-1.5ubuntu1_arm64.deb
/var/cache/apt/archives/libopencv-ml2.4v5_2.4.9.1+dfsg-1.5ubuntu1_arm64.deb
/var/cache/apt/archives/libopencv-legacy2.4v5_2.4.9.1+dfsg-1.5ubuntu1_arm64.deb
/var/cache/apt/archives/libopencv-objdetect2.4v5_2.4.9.1+dfsg-1.5ubuntu1_arm64.deb
/var/cache/apt/archives/libopencv-contrib2.4v5_2.4.9.1+dfsg-1.5ubuntu1_arm64.deb
/var/cache/apt/archives/libopencv-highgui2.4v5_2.4.9.1+dfsg-1.5ubuntu1_arm64.deb
/var/cache/apt/archives/libopencv-core2.4v5_2.4.9.1+dfsg-1.5ubuntu1_arm64.deb
/var/cache/apt/archives/libopencv-photo2.4v5_2.4.9.1+dfsg-1.5ubuntu1_arm64.deb
/var/cache/apt/archives/libopencv-imgproc2.4v5_2.4.9.1+dfsg-1.5ubuntu1_arm64.deb
/var/lib/dpkg/info/libopencv-objdetect2.4v5:arm64.shlibs
/var/lib/dpkg/info/libopencv-legacy2.4v5:arm64.shlibs
/var/lib/dpkg/info/libopencv-imgproc2.4v5:arm64.md5sums
/var/lib/dpkg/info/libopencv-contrib2.4v5:arm64.shlibs
/var/lib/dpkg/info/libopencv-objdetect2.4v5:arm64.triggers
/var/lib/dpkg/info/libopencv-video2.4v5:arm64.list
/var/lib/dpkg/info/libopencv-legacy2.4v5:arm64.triggers
/var/lib/dpkg/info/libopencv-core2.4v5:arm64.triggers
/var/lib/dpkg/info/libopencv-contrib2.4v5:arm64.triggers
/var/lib/dpkg/info/libopencv-calib3d2.4v5:arm64.shlibs
/var/lib/dpkg/info/libopencv-features2d2.4v5:arm64.md5sums
/var/lib/dpkg/info/libopencv-ml2.4v5:arm64.shlibs
/var/lib/dpkg/info/libopencv-flann2.4v5:arm64.md5sums
/var/lib/dpkg/info/libopencv-imgproc2.4v5:arm64.shlibs
/var/lib/dpkg/info/libopencv-calib3d2.4v5:arm64.md5sums
/var/lib/dpkg/info/libopencv-features2d2.4v5:arm64.list
/var/lib/dpkg/info/libopencv-video2.4v5:arm64.md5sums
/var/lib/dpkg/info/libopencv-contrib2.4v5:arm64.list
/var/lib/dpkg/info/libopencv-features2d2.4v5:arm64.triggers
/var/lib/dpkg/info/libopencv-highgui2.4v5:arm64.list
/var/lib/dpkg/info/libopencv-contrib2.4v5:arm64.md5sums
/var/lib/dpkg/info/libopencv-core2.4v5:arm64.list
/var/lib/dpkg/info/libopencv-photo2.4v5:arm64.triggers
/var/lib/dpkg/info/libopencv-core2.4v5:arm64.shlibs
/var/lib/dpkg/info/libopencv-legacy2.4v5:arm64.md5sums
/var/lib/dpkg/info/libopencv-photo2.4v5:arm64.list
/var/lib/dpkg/info/libopencv-calib3d2.4v5:arm64.list
/var/lib/dpkg/info/libopencv-photo2.4v5:arm64.md5sums
/var/lib/dpkg/info/libopencv-features2d2.4v5:arm64.shlibs
/var/lib/dpkg/info/libopencv-ml2.4v5:arm64.triggers
/var/lib/dpkg/info/libopencv-legacy2.4v5:arm64.list
/var/lib/dpkg/info/libopencv-flann2.4v5:arm64.triggers
/var/lib/dpkg/info/libopencv-highgui2.4v5:arm64.triggers
/var/lib/dpkg/info/libopencv-flann2.4v5:arm64.list
/var/lib/dpkg/info/libopencv-flann2.4v5:arm64.shlibs
/var/lib/dpkg/info/libopencv-highgui2.4v5:arm64.shlibs
/var/lib/dpkg/info/libopencv-objdetect2.4v5:arm64.list
/var/lib/dpkg/info/libopencv-objdetect2.4v5:arm64.md5sums
/var/lib/dpkg/info/libopencv-core2.4v5:arm64.md5sums
/var/lib/dpkg/info/libopencv-highgui2.4v5:arm64.md5sums
/var/lib/dpkg/info/libopencv-imgproc2.4v5:arm64.triggers
/var/lib/dpkg/info/libopencv-imgproc2.4v5:arm64.list
/var/lib/dpkg/info/libopencv-ml2.4v5:arm64.list
/var/lib/dpkg/info/libopencv-photo2.4v5:arm64.shlibs
/var/lib/dpkg/info/libopencv-video2.4v5:arm64.triggers
/var/lib/dpkg/info/libopencv-ml2.4v5:arm64.md5sums
/var/lib/dpkg/info/libopencv-video2.4v5:arm64.shlibs
/var/lib/dpkg/info/libopencv-calib3d2.4v5:arm64.triggers
/usr/share/doc/libopencv-calib3d2.4v5
/usr/share/doc/libopencv-highgui2.4v5
/usr/share/doc/libopencv-contrib2.4v5
/usr/share/doc/libopencv-core2.4v5
/usr/share/doc/libopencv-flann2.4v5
/usr/share/doc/libopencv-video2.4v5
/usr/share/doc/libopencv-imgproc2.4v5
/usr/share/doc/libopencv-ml2.4v5
/usr/share/doc/libopencv-features2d2.4v5
/usr/share/doc/libopencv-legacy2.4v5
/usr/share/doc/libopencv-photo2.4v5
/usr/share/doc/libopencv-objdetect2.4v5
/usr/local/lib/libopencv_video.so
/usr/local/lib/libopencv_cudaimgproc.so.3.2
/usr/local/lib/libopencv_cudaobjdetect.so.3.2.0
/usr/local/lib/libopencv_ml.so.3.2
/usr/local/lib/libopencv_videoio.so.3.2
/usr/local/lib/libopencv_video.so.3.2
/usr/local/lib/libopencv_highgui.so.3.2.0
/usr/local/lib/libopencv_videoio.so.3.2.0
/usr/local/lib/libopencv_ml.so.3.2.0
/usr/local/lib/libopencv_cudastereo.so.3.2.0
/usr/local/lib/libopencv_cudafilters.so
/usr/local/lib/libopencv_cudev.so.3.2
/usr/local/lib/libopencv_cudev.so
/usr/local/lib/libopencv_cudawarping.so
/usr/local/lib/libopencv_shape.so.3.2.0
/usr/local/lib/libopencv_cudalegacy.so
/usr/local/lib/libopencv_cudabgsegm.so
/usr/local/lib/libopencv_imgcodecs.so.3.2
/usr/local/lib/libopencv_stitching.so.3.2.0
/usr/local/lib/libopencv_superres.so
/usr/local/lib/libopencv_cudabgsegm.so.3.2
/usr/local/lib/libopencv_cudafeatures2d.so.3.2.0
/usr/local/lib/libopencv_videoio.so
/usr/local/lib/libopencv_cudawarping.so.3.2.0
/usr/local/lib/libopencv_cudev.so.3.2.0
/usr/local/lib/libopencv_cudaimgproc.so
/usr/local/lib/libopencv_photo.so.3.2
/usr/local/lib/libopencv_videostab.so.3.2.0
/usr/local/lib/libopencv_highgui.so.3.2
/usr/local/lib/libopencv_cudafeatures2d.so.3.2
/usr/local/lib/libopencv_cudacodec.so.3.2.0
/usr/local/lib/libopencv_ml.so
/usr/local/lib/libopencv_core.so
/usr/local/lib/libopencv_cudastereo.so
/usr/local/lib/libopencv_highgui.so
/usr/local/lib/libopencv_cudaoptflow.so.3.2
/usr/local/lib/libopencv_calib3d.so
/usr/local/lib/libopencv_imgcodecs.so
/usr/local/lib/libopencv_flann.so.3.2
/usr/local/lib/libopencv_features2d.so.3.2
/usr/local/lib/libopencv_calib3d.so.3.2.0
/usr/local/lib/libopencv_cudaobjdetect.so.3.2
/usr/local/lib/libopencv_shape.so.3.2
/usr/local/lib/libopencv_features2d.so
/usr/local/lib/libopencv_video.so.3.2.0
/usr/local/lib/libopencv_objdetect.so.3.2.0
/usr/local/lib/libopencv_shape.so
/usr/local/lib/libopencv_objdetect.so
/usr/local/lib/libopencv_cudaobjdetect.so
/usr/local/lib/libopencv_cudaarithm.so.3.2.0
/usr/local/lib/libopencv_cudawarping.so.3.2
/usr/local/lib/libopencv_imgcodecs.so.3.2.0
/usr/local/lib/libopencv_imgproc.so.3.2.0
/usr/local/lib/libopencv_cudaarithm.so
/usr/local/lib/libopencv_stitching.so
/usr/local/lib/libopencv_features2d.so.3.2.0
/usr/local/lib/libopencv_cudafilters.so.3.2
/usr/local/lib/libopencv_imgproc.so
/usr/local/lib/libopencv_superres.so.3.2.0
/usr/local/lib/libopencv_core.so.3.2.0
/usr/local/lib/libopencv_cudaarithm.so.3.2
/usr/local/lib/libopencv_cudacodec.so
/usr/local/lib/libopencv_cudalegacy.so.3.2.0
/usr/local/lib/libopencv_imgproc.so.3.2
/usr/local/lib/libopencv_cudalegacy.so.3.2
/usr/local/lib/libopencv_superres.so.3.2
/usr/local/lib/libopencv_calib3d.so.3.2
/usr/local/lib/libopencv_cudabgsegm.so.3.2.0
/usr/local/lib/libopencv_cudafilters.so.3.2.0
/usr/local/lib/libopencv_cudaoptflow.so
/usr/local/lib/libopencv_photo.so
/usr/local/lib/libopencv_cudastereo.so.3.2
/usr/local/lib/libopencv_stitching.so.3.2
/usr/local/lib/libopencv_videostab.so.3.2
/usr/local/lib/libopencv_photo.so.3.2.0
/usr/local/lib/libopencv_flann.so.3.2.0
/usr/local/lib/libopencv_objdetect.so.3.2
/usr/local/lib/libopencv_cudafeatures2d.so
/usr/local/lib/libopencv_flann.so
/usr/local/lib/libopencv_core.so.3.2
/usr/local/lib/libopencv_cudaoptflow.so.3.2.0
/usr/local/lib/libopencv_cudaimgproc.so.3.2.0
/usr/local/lib/libopencv_videostab.so
/usr/local/lib/libopencv_cudacodec.so.3.2
/usr/lib/aarch64-linux-gnu/libopencv_video.so.2.4
/usr/lib/aarch64-linux-gnu/libopencv_photo.so.2.4.9
/usr/lib/aarch64-linux-gnu/libopencv_video.so.2.4.9
/usr/lib/aarch64-linux-gnu/libopencv_imgproc.so.2.4.9
/usr/lib/aarch64-linux-gnu/libopencv_ml.so.2.4.9
/usr/lib/aarch64-linux-gnu/libopencv_objdetect.so.2.4.9
/usr/lib/aarch64-linux-gnu/libopencv_core.so.2.4
/usr/lib/aarch64-linux-gnu/libopencv_features2d.so.2.4
/usr/lib/aarch64-linux-gnu/libopencv_objdetect.so.2.4
/usr/lib/aarch64-linux-gnu/libopencv_contrib.so.2.4
/usr/lib/aarch64-linux-gnu/libopencv_ml.so.2.4
/usr/lib/aarch64-linux-gnu/libopencv_legacy.so.2.4.9
/usr/lib/aarch64-linux-gnu/libopencv_calib3d.so.2.4.9
/usr/lib/aarch64-linux-gnu/libopencv_flann.so.2.4
/usr/lib/aarch64-linux-gnu/libopencv_calib3d.so.2.4
/usr/lib/aarch64-linux-gnu/libopencv_legacy.so.2.4
/usr/lib/aarch64-linux-gnu/libopencv_photo.so.2.4
/usr/lib/aarch64-linux-gnu/libopencv_flann.so.2.4.9
/usr/lib/aarch64-linux-gnu/libopencv_highgui.so.2.4.9
/usr/lib/aarch64-linux-gnu/libopencv_contrib.so.2.4.9
/usr/lib/aarch64-linux-gnu/libopencv_imgproc.so.2.4
/usr/lib/aarch64-linux-gnu/libopencv_features2d.so.2.4.9
/usr/lib/aarch64-linux-gnu/libopencv_core.so.2.4.9
/usr/lib/aarch64-linux-gnu/libopencv_highgui.so.2.4

It seems that opencv4tegra-2.4.13 has been correctly removed, but another opencv-2.4.9 is also there.
cv2.version is to be run in python after ‘import cv2’, it will allow to know which version is found by python.

Hi honey_Patouceul,

you are right , I add a line to python code " print cv2.__version__",

and get the print is 2.4.9.1

the python really bind with opencv2.4.9.1

how to solve it ??