Please provide complete information as applicable to your setup.
• Hardware Platform (Jetson / GPU)
NVIDIA GTX3080
• DeepStream Version
nvcr.io/nvidia/deepstream:6.0-devel
• NVIDIA GPU Driver Version (valid for GPU only)
NVIDIA-SMI 495.46 Driver Version: 495.46 CUDA Version: 11.5
• Issue Type( questions, new requirements, bugs)
I have found an issue where the NvDsBatchMeta->NvDsFrameMeta->NvDsObjectMeta->parent
pointers are null
if accessed from any element downstream of a Gst-nvvideoconvert
element where the GstCaps of the downstream element is not on the GPU (i.e. not video/x-raw(memory:NVMM)
). This makes it very hard to correlate nested detection inferences.
For example:
- If the GstCaps of the element immediately following the
Gst-nvvideoconvert
is avideo/x-raw
then the all the rest of theNvDsBatchMeta
will be present when read viagst_buffer_get_nvds_batch_meta
function but allNvDsBatchMeta->NvDsFrameMeta->NvDsObjectMeta->parent
pointers will be null. - If the GstCaps of the element immediately following the
Gst-nvvideoconvert
isany
(so theGst-nvvideoconvert
element does not actually copy the data from the GPU) then the relevantNvDsBatchMeta->NvDsFrameMeta->NvDsObjectMeta->parent
pointers will be not-null and the parent object can be read.
It seems like there is an issue with Gst-nvvideoconvert
that is causing this loss of data when copying from the GPU back to the CPU.
• How to reproduce the issue ? (This is for bugs. Including which sample app is using, the configuration files content, the command line used and other details for reproducing)
Here is a modified version of the back-to-back-detectors
example from the deepstream_reference_apps repository.
Modifications:
- added an
avenc_mpeg4
element after thenvvideoconvert
to force thenvvideoconvert
element to copy the data from the GPU to the CPU. - removed the
nsdsosd
andnveglglessink
elements. - added a probe to the the sink of the
nvvideoconvert
(before the GPU->CPU operation) to prove theNvDsBatchMeta->NvDsFrameMeta->NvDsObjectMeta->parent
pointers are still populated. - added a probe to the the sink of the
avenc_mpeg4
(after the GPU->CPU operation) to prove theNvDsBatchMeta->NvDsFrameMeta->NvDsObjectMeta->parent
pointers are no longer present.
Here is sample code for reproduction (link will expire in 2 weeks):
https://pastebin.com/iLHsLswt