NvBufSurfTransform errors running Deepstream

Seeing both error code -2 and -3 while running Deepstream on a Jetson Xavier AGX running Jetpack 4.6

Error: gst-stream-error-quark: NvBufSurfTransform failed with error -2 while converting buffer (1): /dvs/git/dirty/git-master_linux/deepstream/sdk/src/gst-plugins/gst-nvinfer/gstnvinfer.cpp(1376): convert_batch_and_push_to_input_thread (): /GstPipeline:pipeline0/GstNvInfer:classifier
ERROR factory bus_call:340 Error: gst-stream-error-quark: NvBufSurfTransform failed with error -3 while converting buffer (1): /dvs/git/dirty/git-master_linux/deepstream/sdk/src/gst-plugins/gst-nvinfer/gstnvinfer.cpp(1376): convert_batch_and_push_to_input_thread (): /GstPipeline:pipeline0/GstNvInfer:classifier

Found some related posts but not sure how to go about resolving the issue. Tried using this is the Deepstream settings but it did not resolve the issue.

"scaling-compute-hw": 1

Please provide complete information as applicable to your setup.

• Hardware Platform (Jetson / GPU)
• DeepStream Version
• JetPack Version (valid for Jetson only)
• TensorRT Version
• NVIDIA GPU Driver Version (valid for GPU only)
• Issue Type( questions, new requirements, bugs)
• 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)
• Requirement details( This is for new requirement. Including the module name-for which plugin or for which sample application, the function description)

Please tell us what app are you working on? If it is not in our sample apps, please provide a reproducing app to us for reproduce and debug the issue.

Jetson Xavier NX
Jetpack 4.6 [L4T 32.6.1]
Deepstream 6.0
TensorRT v8001

NvBufSurfTransform erors occur causing inferencing issues.

Without using the scaling-compute-hw = 1 setting to move NvBufSurfTransform operations from the VIC to the GPU, the error code -2 error, NvBufSurfTransformError_Execution_Error, occurs reproducibly using specific test videos.

Using the scaling-compute-hw = 1 setting results in the error code -2 error, NvBufSurfTransformError_Execution_Error, not occurring using a test video that reliably reproduces the issue.

Error code -3, NvBufSurfTransformError_Invalid_Params, does occasionally occur but not nearly as frequently and there is no test video available to reproduce the error.

Difficulty providing a sample app that reproduces the issue without providing our models and a video that produces the Error code -3, NvBufSurfTransformError_Invalid_Params, issue

Can you try the same case with the JetPack 5.1.2 and DeepStream 6.3 GA?

Currently unable to test using JP 5.1.2.

Recompiled the gst-nvinfer element from the Deepstream SDK and added some logging to show the NvBufSurfTransformParams values being passed to NvBufSurfTransform. Below are logged values for error code -2, error code -3 and some values that succeed without error. Included are the calculated scaling factors using:

width_scaling = src_rect.width / dst_rect.width
height_scaling = src_rect.height/ dst_rect.height

Error code -2

src_rect: { 214, left: 714, width: 78, height: 42 }, dst_rect: { 0, left: 0, width: 128, height: 64 }, width_scaling: .60, height_scaling: .65

Error code -3

src_rect: { 174, left: 362, width: 362, height: 66 }, dst_rect: { 0, left: 0, width: 128, height: 64 }, width_scaling: 2.82, height_scaling: 1.03
src_rect: { 178, left: 368, width: 368, height: 84 }, dst_rect: { 0, left: 0, width: 128, height: 64 }, width_scaling: 2.87, height_scaling: 1.31
src_rect: { 306, left: 364, width: 364, height: 76 }, dst_rect: { 0, left: 0, width: 128, height: 64 }, width_scaling: 2.84, height_scaling: 1.18
src_rect: { 228, left: 366, width: 366, height: 166 }, dst_rect: { 0, left: 0, width: 128, height: 64 }, width_scaling: 2.85, height_scaling: 2.59
src_rect: { 174, left: 364, width: 364, height: 86 }, dst_rect: { 0, left: 0, width: 128, height: 64 }, width_scaling: 2.84, height_scaling: 1.34
src_rect: { 176, left: 368, width: 368, height: 84 }, dst_rect: { 0, left: 0, width: 128, height: 64 }, width_scaling: 2.87, height_scaling: 1.31

No Error

src_rect: { 274, left: 440, width: 102, height: 52 }, dst_rect: { 0, left: 0, width: 128, height: 64 }, width_scaling: .79, height_scaling: .81
src_rect: { 264, left: 440, width: 142, height: 62 }, dst_rect: { 0, left: 0, width: 128, height: 64 }, width_scaling: 1.10, height_scaling: .96
src_rect: { 258, left: 444, width: 254, height: 68 }, dst_rect: { 0, left: 0, width: 128, height: 64 }, width_scaling: 1.98, height_scaling: 1.06
src_rect: { 38, left: 0, width: 720, height: 316 }, dst_rect: { 0, left: 0, width: 128, height: 64 }, width_scaling: 5.62, height_scaling: 4.93
src_rect: { 300, left: 128, width: 140, height: 74 }, dst_rect: { 0, left: 0, width: 128, height: 64 }, width_scaling: 1.09, height_scaling: 1.15
src_rect: { 310, left: 680, width: 38, height: 62 }, dst_rect: { 0, left: 0, width: 128, height: 64 }, width_scaling: .29, height_scaling: .96
src_rect: { 34, left: 0, width: 720, height: 326 }, dst_rect: { 0, left: 0, width: 128, height: 64 }, width_scaling: 5.62, height_scaling: 5.09
src_rect: { 40, left: 0, width: 720, height: 318 }, dst_rect: { 0, left: 0, width: 128, height: 64 }, width_scaling: 5.62, height_scaling: 4.96
src_rect: { 32, left: 0, width: 720, height: 328 }, dst_rect: { 0, left: 0, width: 128, height: 64 }, width_scaling: 5.62, height_scaling: 5.12
src_rect: { 222, left: 0, width: 664, height: 164 }, dst_rect: { 0, left: 0, width: 128, height: 64 }, width_scaling: 5.18, height_scaling: 2.56
src_rect: { 28, left: 0, width: 720, height: 336 }, dst_rect: { 0, left: 0, width: 128, height: 64 }, width_scaling: 5.62, height_scaling: 5.25
src_rect: { 220, left: 0, width: 662, height: 164 }, dst_rect: { 0, left: 0, width: 128, height: 64 }, width_scaling: 5.17, height_scaling: 2.56
src_rect: { 28, left: 0, width: 720, height: 336 }, dst_rect: { 0, left: 0, width: 128, height: 64 }, width_scaling: 5.62, height_scaling: 5.25
src_rect: { 220, left: 0, width: 662, height: 164 }, dst_rect: { 0, left: 0, width: 128, height: 64 }, width_scaling: 5.17, height_scaling: 2.56
src_rect: { 22, left: 0, width: 720, height: 342 }, dst_rect: { 0, left: 0, width: 128, height: 64 }, width_scaling: 5.62, height_scaling: 5.34
src_rect: { 38, left: 0, width: 720, height: 322 }, dst_rect: { 0, left: 0, width: 128, height: 64 }, width_scaling: 5.62, height_scaling: 5.03
src_rect: { 32, left: 0, width: 720, height: 332 }, dst_rect: { 0, left: 0, width: 128, height: 64 }, width_scaling: 5.62, height_scaling: 5.18
src_rect: { 32, left: 0, width: 720, height: 330 }, dst_rect: { 0, left: 0, width: 128, height: 64 }, width_scaling: 5.62, height_scaling: 5.15
src_rect: { 32, left: 0, width: 720, height: 330 }, dst_rect: { 0, left: 0, width: 128, height: 64 }, width_scaling: 5.62, height_scaling: 5.15
src_rect: { 290, left: 0, width: 110, height: 82 }, dst_rect: { 0, left: 0, width: 128, height: 64 }, width_scaling: .85, height_scaling: 1.28
src_rect: { 268, left: 0, width: 164, height: 112 }, dst_rect: { 0, left: 0, width: 128, height: 64 }, width_scaling: 1.28, height_scaling: 1.75
src_rect: { 266, left: 0, width: 422, height: 114 }, dst_rect: { 0, left: 0, width: 128, height: 64 }, width_scaling: 3.29, height_scaling: 1.78
src_rect: { 284, left: 384, width: 212, height: 92 }, dst_rect: { 0, left: 0, width: 128, height: 64 }, width_scaling: 1.65, height_scaling: 1.43
src_rect: { 26, left: 0, width: 720, height: 334 }, dst_rect: { 0, left: 0, width: 128, height: 64 }, width_scaling: 5.62, height_scaling: 5.21
src_rect: { 28, left: 0, width: 720, height: 324 }, dst_rect: { 0, left: 0, width: 128, height: 64 }, width_scaling: 5.62, height_scaling: 5.06

Please tell us what app are you working on? If it is not in our sample apps, please provide a reproducing app to us for reproduce and debug the issue.
You can message us if you don’t want to post your code and models publicly.

There is no update from you for a period, assuming this is not an issue anymore. Hence we are closing this topic. If need further support, please open a new one. Thanks

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.