Nanoowl Container doesnt open camera

Hi, Im trying to follow the NanoOwl tutorial (NanoOWL - NVIDIA Jetson AI Lab) and getting some critical errors from Gstreamer.

First i was trying to use csi cameras (2 of them), than I saw in github repository instructions to use a USB camera. The 3 cameras are connected at the moment of the print bellow:

The server loads on http://0.0.0.0:7860/ but there is no feed from any cameras.

Hi kikoyah,

Looking at the code of tree_demo.py, it seems it is designed to take camera device ID like this.

With your already connected CSI camera, it is a little difficult to determine which is your USB web camera, but let’s say /dev/video2 is the one.

If that is the case, you can test with;

python3 tree_demo.py --camera 2 ../../data/owl_image_encoder_patch32.engine

Please let us know if this solves your issue.

Hi Cyato, thank you. It works with the usb camera.

Nanoowl github page is clear about using a USB camera, but can you point some direction/modification so it can work with csi cameras? When I try to run with other ids to use csi cameras, the difference in inicialization is the warnings above:

INFO:root:Opening camera.
[ WARN:0@16.220] global cap_gstreamer.cpp:2839 handleMessage OpenCV | GStreamer warning: Embedded video playback halted; module v4l2src0 reported: Internal data stream error.
[ WARN:0@16.221] global cap_gstreamer.cpp:1698 open OpenCV | GStreamer warning: unable to start pipeline
[ WARN:0@16.221] global cap_gstreamer.cpp:1173 isPipelinePlaying OpenCV | GStreamer warning: GStreamer: pipeline have not been created

Hi @kikoyah

It is great to hear it worked with your USB camera.

The tree_demo.py program just uses OpenCV to interface to a USB camera and does not support a CSI camera.

One thing you can try is to use the --csi2webcam option of jetson-containers, as explained in this tutorial.

So that would be you run the container like;

jetson-containers run --csi2webcam --workdir /opt/nanoowl $(autotag nanoowl)

And inside the container, when you ls /dev/video* , you should see an additional device, so use that device id for as your camera.

Hi Cyato,

With the --csi2webcam option, the container requested additional libraries and after installation it worked.

Thanks for the quick support.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.