DeepStream SDK not working on TX2 Jetpack3.2

I did a full install of JetPack3.2 on my TX2
and then i downloaded the DeepStream SDK and followed the directions.
doesnt seem to be working for me…

nvidia@tegra-ubuntu:~/org/downloads/jetsonUtilities$ ./jetsoninfo.py
Hardware Model Name not available
L4T 28.2.0
Board: t186ref
Ubuntu 16.04 LTS
Kernel Version: 4.4.38-tegra

nvidia@tegra-ubuntu:~/org/downloads/DeepStreamSDK$ nvgstiva-app -c ${HOME}/configs/PGIE-FP16-CarType-CarMake-CarColor.txt
** ERROR: <create_osd_bin:62>: Failed to create ‘nvosd0’
** ERROR: <create_osd_bin:100>: create_osd_bin failed
** ERROR: <create_processing_instance:890>: create_processing_instance failed
** ERROR: <create_pipeline:1024>: create_pipeline failed
** ERROR: main:384: Failed to create pipeline
Quitting

(nvgstiva-app:22377): GStreamer-CRITICAL **: gst_element_get_static_pad: assertion ‘GST_IS_ELEMENT (element)’ failed

(nvgstiva-app:22377): GStreamer-CRITICAL **: gst_pad_remove_probe: assertion ‘GST_IS_PAD (pad)’ failed

(nvgstiva-app:22377): GStreamer-CRITICAL **: gst_object_unref: assertion ‘object != NULL’ failed
App run failed

Hi,

Could you test our MMAPI sample which is contained nvosd first?
Thanks.

i dont know what you mean by MMAPI sample and nvosd folder.

I downloaded the Deepstream sdk DeepStream_SDK_on_Jetson_1.0_pre-release.tbz2
from https://developer.nvidia.com/embedded/deepstream-on-jetson-downloads

and followed the directions to install.
it says there to have Jetson Jetpack 3.1 as prerequisite
since Jetpack 3.2 just came out I installed that.

im newb so i dont know what you mean by MMAPI sample and nvosd folder.

so i did a find on nvosd from the nvidia user home directory on the tx2
find . -name “nvosd*”

i found…
./tegra_multimedia_api/include/nvosd.h
./nvgstiva-app_sources/nvgstiva-app/includes/nvosd.h

so i went and "Built the sources by navigating to the nvgstiva-app directory and executing
the below commands:
cd ${HOME}/nvgstiva-app_sources/nvgstiva-app
make
"

and now im getting…

nvidia@tegra-ubuntu:~/nvgstiva-app_sources/nvgstiva-app$ make

/usr/bin/ld: cannot find -lnvid_mapper
Makefile:37: recipe for target ‘nvgstiva-app’ failed

i originally set up my tx2 using the super latest jetpack 3.2 with full install.
then i installed deepstream.
since i got the deepstream error i tried to see if i need to downgrade to earlier versions of gstream and opencv. i used jetpack 3.2 to remove opencv. i also used some apt-get to remove opencv.
not sure if i removed cuda 9. but i think vision works gets removed when you remove opencv from jetpack. i dunno. eventually i ended up running jetpack 3.1 just to get cuda8 that the jetson hacks script is looking for.

so once i had cuda8 from the jetpack 3.1 i ran the jetson hacks script to install opencv.
https://github.com/jetsonhacks/buildOpenCVTX2
i ran it with gstreamer support turned on.
then i ran some internet examples that use opencv and worked.

after all that im still getting the same error from deepstream.
** ERROR: <create_osd_bin:62>: Failed to create ‘nvosd0’

and this error from trying to make nvgstiva-app
/usr/bin/ld: cannot find -lnvid_mapper
Makefile:37: recipe for target ‘nvgstiva-app’ failed

does deepstream still rely on OpenCV4Tegra ?
the new Jetson Jetpack 3.2 seems to go away from OpenCV4Tegra and brings OpenCV3.3

id rather stay with JetPack 3.2 because they added docker support and i need that for part of my application.
i dont want to flash my TX2 to JetPack 3.1 just to get Deepstream to work.

is that the only option to get Deepstream to work is to downgrad to Jetpack 3.1?

i found a sample that used nvosd.h in its code

at…
nvidia@tegra-ubuntu:
~/tegra_multimedia_api/samples/02_video_dec_cuda$

i ran…
./video_dec_cuda ~/sample_720p.h264 H264./video_dec_cuda ~/sample_720p.h264 H264

a video player with parking lot came up… when the clip ended
looks like it processed at 30 framerate so worked.

Hi,

DeepStream SDK is tested and verified on Rel-28.1, which is contained in JetPack3.1.
Please use JetPack3.1 to set-up your environment.

Thanks.

got it to work thanks. can you point me to some guides as to how to use or do i just look at the code?
what C++ IDE do you suggest?

Hi,

You can run this command to find supported feature:

nvgstiva-app --help

And test deepstreamSDK with this command:

nvgstiva-app -c iva_app_cfg.txt

We don’t have too much experience on IDE but here is a related topic for your reference:
https://devtalk.nvidia.com/default/topic/1016158/recommended-ide-for-jetson-tx2-/

Thanks.

I am just wondering if DeepStream SDK has been tested and verified with JetPack 3.2 so far.

Hi,

This topic discuss about DeepStream SDK for Jetson.
It is still limited release and only supports JetPack3.1 currently.

Thanks.

I’ve just installed DeepStream 1.5 and started to get the same error:

** ERROR: <create_osd_bin:62>: Failed to create ‘nvosd0’
** ERROR: <create_osd_bin:100>: create_osd_bin failed
** ERROR: <create_processing_instance:891>: create_processing_instance failed
** ERROR: <create_pipeline:1025>: create_pipeline failed
** ERROR: main:384: Failed to create pipeline
Quitting

(nvgstiva-app:1651): GStreamer-CRITICAL **: gst_element_get_static_pad: assertion ‘GST_IS_ELEMENT (element)’ failed

(nvgstiva-app:1651): GStreamer-CRITICAL **: gst_pad_remove_probe: assertion ‘GST_IS_PAD (pad)’ failed

(nvgstiva-app:1651): GStreamer-CRITICAL **: gst_object_unref: assertion ‘object != NULL’ failed
App run failed

Had a previous release of DeepStream (1.0) working fine before. Can someone from NVidia help to troubleshoot this error?

-albertr

Ok, I managed to get over this error, but hitting another error with libnvinfer4 segfault’ing:

------------> -----------------
------------> 0,128,128:1,0,0:2,0,0:3,0,0:4,0,0:5,0,0: -----------------
------------> 0,1920,1080:1,100,1080:2,1920,1080:3,1920,1080:4,0,0:5,0,0: -----------------
------------> -----------------
CLASS_IDS TO OEPRATE ON gie_id(0) : 2:
------------> 0,128,128:1,0,0:2,0,0:3,0,0:4,0,0:5,0,0:6,0,0:7,0,0:8,0,0:9,0,0:10,0,0:11,0,0: -----------------
------------> 0,1920,1080:1,100,1080:2,1920,1080:3,1920,1080:4,0,0:5,0,0:6,0,0:7,0,0:8,0,0:9,0,0:10,0,0:11,0,0: -----------------
------------> -----------------
CLASS_IDS TO OEPRATE ON gie_id(0) : 2:
------------> 0,128,128:1,0,0:2,0,0:3,0,0:4,0,0:5,0,0:6,0,0:7,0,0:8,0,0:9,0,0:10,0,0:11,0,0:12,0,0:13,0,0:14,0,0:15,0,0:16,128,1920:17,0,100:18,0,1920:19,0,1920:20,0,0:21,0,0:22,0,0:23,0,0: -----------------
------------> 0,1920,1080:1,100,1080:2,1920,1080:3,1920,1080:4,0,0:5,0,0:6,0,0:7,0,0:8,0,0:9,0,0:10,0,0:11,0,0:12,0,0:13,0,0:14,0,0:15,0,0:16,1080,1:17,1080,1:18,1080,4:19,1080,4:20,0,0:21,0,0:22,0,0:23,0,0: -----------------
------------> -----------------
CLASS_IDS TO OEPRATE ON gie_id(0) : 2:
------------> 0,0:1,0:2,0: -----------------
------------> 0,0:1,0:2,0: -----------------
------------> 0,0,0:1,0,0:2,0,0: -----------------
------------> 0,1920,1080:1,100,1080:2,1920,1080: -----------------
------------> 0,0.200000,0.100000,3,0:1,0.200000,0.100000,3,0:2,0.200000,0.100000,3,0: -----------------
------------> 0,0.0,1.0,0.0:1,0.0,1.0,1.0:2,0.0,0.0,1.0:3,1.0,1.0,0.0 -----------------
Deploy Name : /usr/src/deep_stream/Model/IVASecondary_Make_V1/deploy.prototxt
Model Name : /usr/src/deep_stream/Model/IVASecondary_Make_V1/snapshot_iter_6240.caffemodel
Model Cache Name : /usr/src/deep_stream/Model/IVASecondary_Make_V1/snapshot_iter_6240.caffemodel_b2_fp16.cache
Batch_Size 2

Using Cached GIE model /usr/src/deep_stream/Model/IVASecondary_Make_V1/snapshot_iter_6240.caffemodel_b2_fp16.cache crypto flags(0)
Segmentation fault

[ 2535.610608] nvgstiva-app[5422]: unhandled level 2 translation fault (11) at 0x00000000, esr 0x92000006
[ 2535.618626] pgd = ffffffc0795c6000
[ 2535.620738] [00000000] *pgd=00000000a092b003, *pud=00000000a092b003, *pmd=0000000000000000

[ 2535.627934] CPU: 3 PID: 5422 Comm: nvgstiva-app Not tainted 4.4.38-dev-1.0 #65
[ 2535.633853] Hardware name: quill (DT)
[ 2535.636221] task: ffffffc1ecf0b200 ti: ffffffc02e8c4000 task.ti: ffffffc02e8c4000
[ 2535.642398] PC is at 0x7f7ff78c1c
[ 2535.644417] LR is at 0x7f7ff02b94
[ 2535.646423] pc : [<0000007f7ff78c1c>] lr : [<0000007f7ff02b94>] pstate: 20000000
[ 2535.652512] sp : 0000007f57ffdf50
[ 2535.654517] x29: 0000007f57ffdf50 x28: 0000007f54e63f4d
[ 2535.658546] x27: 0000007f57ffe070 x26: 0000007f54e5b4cc
[ 2535.662575] x25: 0000007f57ffe0b0 x24: 0000007f57ffe090
[ 2535.666606] x23: 0000000000000000 x22: 0000007f57ffe140
[ 2535.670636] x21: 0000007f542d7210 x20: 0000000000b84294
[ 2535.674678] x19: 0000007f54e5b4a4 x18: 0000000000000000
[ 2535.678725] x17: 0000007f7ff78c14 x16: 0000007f868e69d0
[ 2535.682765] x15: 0000007f88945cc0 x14: 0000000000000000
[ 2535.686847] x13: 0000000000000000 x12: 0000000000000000
[ 2535.690878] x11: 0000000000000028 x10: 0101010101010101
[ 2535.694945] x9 : 0000000000001150 x8 : 0000007f57ffe140
[ 2535.698977] x7 : 0000000000000001 x6 : 0000007f4c016d8c
[ 2535.703010] x5 : 0000007f57ffde88 x4 : 0000007f4c016d70
[ 2535.707040] x3 : 0000007f54e5b4a4 x2 : 0000000000000000
[ 2535.711070] x1 : 0000000000000000 x0 : 0000000000000000

[ 2535.715287] Library at 0x7f7ff78c1c: 0x7f7fba8000 /usr/lib/aarch64-linux-gnu/libnvinfer.so.4.0.4
[ 2535.722766] Library at 0x7f7ff02b94: 0x7f7fba8000 /usr/lib/aarch64-linux-gnu/libnvinfer.so.4.0.4
[ 2535.730244] vdso base = 0x7f88944000

-albertr

Ok, the later error came from model compatibility. Apparently sample models from Deepstream 1.0 cannot be used with Deepstream 1.5. I have replaced these models and everything seems to be working now.

-albertr

Hi,

Please remember to update the output layer name in the configuration when changing model.
Thanks.

How can you solve the problem?

Hi nguyenngocdat1995,
The issue is clarified in #13