Hanging, deadlock, or null pointer in custom gst-nvinfer

• Hardware Platform = Jetson and dGPU
• DeepStream Version = 4.0.2
• TensorRT Version = 6
• NVIDIA GPU Driver Version = 440.82

I have a custom function within gst-nvinfer for some custom processing. At exactly the same frame/inference on a video (each video is different) the process either completely hangs when processing gst_buffer_pool_acquire_buffer()

The exact command is:

flow_ret = gst_buffer_pool_acquire_buffer(nvinfer->pool, &conv_gst_buf, nullptr);

or it segfaults after exiting my custom function.

if (nvinfer->process_full_frame) {
    flow_ret = gst_nvinfer_process_full_frame(nvinfer, inbuf, in_surf);
} else {
    //flow_ret = gst_nvinfer_process_objects(nvinfer, inbuf, in_surf);
    flow_ret = gst_nvinfer_process_custom(nvinfer, inbuf, in_surf);

I don’t get any errors or any kind of feedback when getting stuck on gst_buffer_pool_acquire_buffer(). The processing just stops and nothing else happens.

When it exits the custom function I get a segfault but cannot see what the cause might be. My debugger tell me that it cannot access the memory address of the fault. I’m running the debug process as root, but I still get that error.

If I run the application with GST_DEBUG=3 (or even up to 6) I don’t get any additional relevant info. I’m assuming I’m seeing a deadlock of some kind or a null pointer somewhere, but I cannot figure out what might be causing it.


Sorry for the long wait.
Could you please share us more information like:

  1. Your pipeline configurations
  2. Your NvInfer configurations
  3. What have you done to your custom function? Or just send us your modifications
  4. What inference model are you using? Is it possible to share us, or is there an alternative one from the samples that could help us reproduce the same fault?

Thank you very much.