Trouble testing the sample programs on TX2 with custom input

Hi, I’ve got DeepStream SDK V1.5 installed on a TX2. When I try to run the sample application with

$ nvgstiva-app -c ${HOME}/configs/PGIE-FP16-CarType-CarMake-CarColor.txt

it runs successfully, no problems. But when I try to run the sample application with custom video without the GUI with this command:

$ nvgstiva-app -c /home/nvidia/configs/PGIE-FP16-CarType-CarMake-CarColor.txt -i '/dev/video1'

I get the following error:

Error from source: Could not read from resource.
Debug info: gstfilesrc.c(400): gst_file_src_fill (): /GstPipeline:pipeline/GstBin:multi_src_bin/GstBin:src_sub_bin0/GstURIDecodeBin:src_elem/GstFileSrc:source:

When I try to run the sample application with the GUI with this command:

$ nvgstiva-app-gui -c ${HOME}/configs/PGIE-FP16-CarType-CarMake-CarColor.txt -i '/dev/video1' -g ${HOME}/configs/gui_cfg.txt

I get the following error:

** ERROR: <main:1781>: Unknown option -i
App run failed

To test the input video source, I tested GStreamer with:

$ gst-launch-1.0 v4l2src device="/dev/video1" ! "video/x-raw,width=640,height=480,format=I420" ! nvoverlaysink

and I had no problems, the video is displayed correctly.

The full outputs can be found here:

The system configuration for the TX2 is as follows:
Linux tegra-ubuntu 4.4.38-tegra #1
R28 (release), REVISION: 2.0, GCID: 10567845, BOARD: t186ref, EABI: aarch64


Could you clean the GPU cache and try it again?

sudo rm -rf ~/-cache/*


I tried it, no luck, same errors.


Please noticed that the default input type of PGIE-FP16-CarType-CarMake-CarColor.txt is url.
If you want to use live camera, please update the type configure in the [source#] module.

You can find this information in our document:
➤ Application Configuration
➤ Source Group
The type of the source. The other properties of the sourced depend on this type.

1=Camera - NV Proprietary path (nvcamerasrc)
2=Camera - Open source V4L2 path (v4l2src) bypassing the ISP; this is suitable for use with USB cameras or CSI cameras that output in RGB or YUV formats.
3=URI - URI where an encoded stream is available (file/http/rtsp)


Thanks AastaLLL.

I modified the file as mentioned in the docs, but then I got a plain red screen when I ran the script. I looked around and stumbled across this: I reduced the resolution incrementally to 1080x720 then to 640x480. I also revised the sink to EglSink instead of OverlaySink. Now I’m getting this error with nvgstiva-app:

ERROR:/dvs/git/dirty/git-master_linux/multimedia/nvgstreamer/gst-nvegltransform/gstnvegltransform.c:215:gst_nvegl_transform_decide_allocation: assertion failed: (gst_query_get_n_allocation_pools (query) > 0)

The GUI version gives this error:

Failed to connect to Mir: Failed to connect to server socket: No such file or directory
Unable to init server: Could not connect: Connection refused

(nvgstiva-app-gui:20960): Gtk-WARNING **: cannot open display:

Thanks for your help.


Could you try this:

export DISPLAY=:0


Hi jtillett86,

Have you tried with our suggestion “export DISPLAY=:0” to remove the error?
Or you have resolved the problem in another way?
Please help to update the status.