NvSci Issue Reconciling Buffer Attribute Lists

Continuing the discussion from Issue Reconciling Buffer attribute lists for NvSci:

Please provide the following info (check/uncheck the boxes after creating this topic):
Software Version
DRIVE OS Linux 5.2.6
DRIVE OS Linux 5.2.0
DRIVE OS Linux 5.2.0 and DriveWorks 3.5
NVIDIA DRIVE™ Software 10.0 (Linux)
NVIDIA DRIVE™ Software 9.0 (Linux)
other DRIVE OS version
other

Target Operating System
Linux
QNX
other

Hardware Platform
NVIDIA DRIVE™ AGX Xavier DevKit (E3550)
NVIDIA DRIVE™ AGX Pegasus DevKit (E3550)
other

SDK Manager Version
1.6.0.8170
other

Host Machine Version
native Ubuntu 18.04
other

Hi,

I am having problems with buffer reconciliation using the NvSci API, specifically using the NvSciBufAttrListReconcile() function. I get the following errors as output:

The function call is done as follows:

The NvMedia Attributes Buffer is setup as follows:

The Cuda Attributes Buffer is setup as follows:

Any advice / hints towards correctly reconciling the buffers would be greatly appreciated!

Best regards,
Mike

Hi @Mike_W,

Please help to share a patch file for the below sample application for us to reproduce the issue on our side.
~/nvidia/nvidia_sdk/DRIVE_Software_10.0_Linux_OS_DRIVE_AGX_*/DRIVEOS/drive-t186ref-linux/samples/nvsci/nvscistream .
Thanks.

For CUDA Attributes: you are using NvSciColor_B8G8R8A8 as the color format
For Image Attributes: you are using RGBA, UINT8, PL ====> NvSciColor_A8B8G8R8 as the color format.

In NvMedia, the formats are defined from least significant to most significant (R-G-B-A), while NvSciColor defines the formats from most significant to least significant (A-B-G-R).

Please try if the error is caused by the difference. Thanks.

Hi @VickNV,

Thanks for your replies.

I have tried out your suggestion with the color formats. It didn’t change the current errors which pop up, although it has probably solved something that would have popped up later.

I need to ask, what do you mean by a patch file in the previous comment?

Hi again,

I have just tried out the base nvscistream sample application on the board (as it is supplied) and also get a runtime error.

I meant if you can provide us a patch for the sample application to reproduce the issue you saw, it will help us to look into it.
Also, could you move to the latest release, say 5.2.6?

Please refer to Samples for NvSci inter thread communication.

@VickNV,

We aren’t currently able to upgrade to the latest release… maybe sometime in the future, but for now I need to work with the version I am using.

The current implementation is a little more convoluted. It isn’t simply a modification of the sample application, but rather using similar functionality to the sample in our own application… because of that its unclear to me how I can provide a patch to you.

I managed to get the sample application running albeit with the runtime error mentioned in the thread.

Please help to create another topic for this failure in running sample application issue.

Based on the other thread you linked previously, the runtime error on the sample application was something that would be patched with a newer version… however this isn’t the original matter at hand and not really something I would specifically like to solve.

The aforementioned issue with the failed Buffer merge still remains open…

Did you see your error (“Failed to find endpoint: 4352”) there? I just curious why the sample application doesn’t work on your side.

Could you share the current output? Or is it still the same?
BTW, please help to share texts instead of screenshots. Thus other developers having the same issue can find this topic. Thanks.

@VickNV,

No problem and good point, I will post text from now on. The latest error is as follows:

[ERROR: MatchPolicy]: Failed to compare
[ERROR: NvSciBufAttrListMergeImgAttr]: Failed to merge Gen Attr Keys
[ERROR: NvSciBufAttrListMergeDataType]: Failed to merge data type attributes
[ERROR: NvSciBufAttrListMerge]: Failed to merge data type
[ERROR: NvSciBufObjAlloc]: Bad parameter supplied to NvSciBufObjAlloc
[ERROR: NvSciBufObjAlloc]: reconciledAttrList: (nil), bufObj: 0x7fccfc2ad8

The output for the sample application is as follows:
For the producer:
Producer Mapping element: 0 of cookie c00c1e8.
[ERROR: NvSciBufObjDup]: Bad parameter supplied to NvSciBufObjDup
[ERROR: NvSciBufObjDup]: bufObj: (nil), dupObj: 0x43e788
/dvs/git/dirty/git-master_linux/tests/nvsci/nvscistream/sample_app/nvmedia_producer.cpp (84), mapBuffers: NvSci error 100

For the consumer:
Consumer Mapping element: 0 of cookie c00c1e8.
[ERROR: NvSciBufObjGetAttrList]: Bad parameter supplied to NvSciBufObjGetAttrList
[ERROR: NvSciBufObjGetAttrList]: bufObj: (nil), bufAttrList: 0x7fdc8872d8
/dvs/git/dirty/git-master_linux/tests/nvsci/nvscistream/sample_app/cuda_consumer.cpp (70), mapBuffers: NvSci error 100