• Hardware Platform: Jetson
• DeepStream Version 6.1.1 Docker
• JetPack Version 5.0.1
• Issue Type: Bug
Bug in nvvideoconvert on Jetson for nvvideoconvert for num(input_channels) != num(output_channels)
• How to reproduce the issue?
Run deepstream as docker
docker run -it --rm nvcr.io/nvidia/deepstream-l4t:6.1.1-base /bin/bash
gst-launch-1.0 videotestsrc ! video/x-raw,format=NV12,width=1920,height=1080 ! nvvideoconvert ! video/x-raw,format=RGB ! fakesink
Setting pipeline to PAUSED ...
Pipeline is PREROLLING ...
0:00:00.178357712 59 0xaaab1318baa0 ERROR nvvideoconvert gstnvvideoconvert.c:3750:gst_nvvideoconvert_transform: buffer transform failed
ERROR: from element /GstPipeline:pipeline0/GstVideoTestSrc:videotestsrc0: Internal data stream error.
Additional debug info:
gstbasesrc.c(3072): gst_base_src_loop (): /GstPipeline:pipeline0/GstVideoTestSrc:videotestsrc0:
streaming stopped, reason error (-5)
ERROR: pipeline doesn't want to preroll.
Setting pipeline to NULL ...
Freeing pipeline ...
With highlight of course on the critical error:
0:00:00.178357712 59 0xaaab1318baa0 ERROR nvvideoconvert gstnvvideoconvert.c:3750:gst_nvvideoconvert_transform: buffer transform failed
• Additional info
The following pipelines have the same issue:
NV12 → BGR breaks
gst-launch-1.0 videotestsrc ! video/x-raw,format=NV12,width=1920,height=1080 ! nvvideoconvert ! video/x-raw,format=BGR ! fakesink
RGBA → RGB breaks
gst-launch-1.0 videotestsrc ! video/x-raw,format=RGBA,width=1920,height=1080 ! nvvideoconvert ! video/x-raw,format=RGB ! fakesink
The following pipelines don’ have that issue:
NV12 → RGBA works
gst-launch-1.0 videotestsrc ! video/x-raw,format=NV12,width=1920,height=1080 ! nvvideoconvert ! video/x-raw,format=RGBA ! fakesink
NV12 → RGBx works
gst-launch-1.0 videotestsrc ! video/x-raw,format=NV12,width=1920,height=1080 ! nvvideoconvert ! video/x-raw,format=RGBx ! fakesink
NV12 → GRAY8 works
gst-launch-1.0 videotestsrc ! video/x-raw,format=NV12,width=1920,height=1080 ! nvvideoconvert ! video/x-raw,format=GRAY8 ! fakesink
• Apparent issue
It looks like the error occurs whenever the amount of channels is different between input and output. For example RGBA → RGB breaks, but also RGB → RGBA breaks as well.
• Current workaround
gst-launch-1.0 videotestsrc ! video/x-raw,format=NV12,width=1920,height=1080 ! nvvideoconvert ! video/x-raw,format=BGRx ! videoconvert ! video/x-raw,format=RGB ! fakesink
With an additional step involving CPU transform it works.