Nvscistream sample gives incorrect results

As suggested in this thread, I am starting a new thread for the following issue:

I extended the provided nvscistream sample to check the data that is received by the CudaConsumer. It appears to me, that the data received always consists of only 1s, i.e. 255 in byte terms. Attached you find a version of the nvscisteam sample which I modified so it does not crash (which the original version does) and to check if the values received on by the CudaConsumer consist of only 1s (will output " → Received all 1s" or also some 0s (will output " → Received diverse values"). I tried changing the values written to the NvMediaImage to be transferred in the NvMediaProducer, but that did not seem to affect the values received on the other end.

Can others reproduce this behavior and/or am I doing something wrong there?

nvscistream.zip (56.4 KB)

Hardware Platform: DRIVE AGX Pegasus™ Developer Kit
Software Version: DRIVE Software 10
Host Machine Version: native Ubuntu 18.04
SDK Manager Version: 1.1.0.6343

Hi @klaus.kofler,

I saw " → Received diverse values" messages as below. I don’t know why always consists of only 1s on your side.

...
Consumer acquires a packet 9:

Receive PACKET_READY event.
Acquire a packet (cookie = c00c1e6).
Process payload (cookie = c00c1e6).
  --> Received diverse values
Release the packet (cookie = c00c1e6, handle = fffffffffffffffd).


 ========================= Consumer Streaming phase End =========================

Hi @VickNV,

I’ve tried this code on 3 different Drive AGX (both Xavier A and B, 2 of them upgraded from Drive 9, one with a Drive 10 installation from the factory) and compiled on two different host machines. I always received all 1s.

Can you confirm you are also using DriveWorks 2.2, DriveOS 5.1.6.1 and CUDA 10.2? Could you also check if the date you are getting in the receiver is actually the same that was sent by the sender?

I ran the binary in your zip file on XavierA with DRIVE Software 10 installed.
Below are the logs, FYR.

nvidia@tegra-ubuntu:~$ ./nvscistream_sample -p nvscistream_0
NvMedia producer created
Producer channel created
Query max number of sync objects allowed: 4.

Number of waiter sync objects: 1.



 ========================= Producer Connection setup =========================

Connecting over Ipc... waiting for consumer connection

Producer channel connected
========================================= ==================================================


 ========================= Producer Sync requirement setup =========================

Producer creates NvSciSync attributes:

Create signaler's sync attribute list.
Set nvmedia-signaler attribute value.
Create waiter's sync attribute list.
Set nvmedia-waiter attribute value.
Producer sends sync attribute to producer:

Send waiter's sync object requirement.

========================================= ==================================================


 ========================= Producer Packet requirement setup =========================

Producer creates NvSciBuf attributes:

Create NvSciBuf attribute list of element 0.
Set attribute value of element 0.
Producer sends packet requirements to the pool:

Send the number of elements per packet to the pool, 1.

Send buffer attributes of element 0.

========================================= ==================================================


 ========================= Producer finalize requirements and map resources =========================

Pool + Producer receive packet and resource requirements.
and process them once all are received

Receive waiter's sync object requirement.

Producer received producer attributes
Common: Reconcile its signaler attributes and the reveived waiter attributes.

Common: Create NvSciSync object 0 with the reconciled attribute list.

Producer reconciled producer attributes and creates sync object:
        sending sync objects to consumer...
Send number of sync objects, 1.

Send sync object 0.

Pool Receives number of elements per packet from producer: 1.

Receive the number of sync objects, 1.

Pool Receives number of elements per packet from consumer: 1.

Receive sync object 0.

Pool Receives packet capabilities of element 0 from producer.

Pool Receives packet requirements of element 0 from consumer.

Pool received all prod / cons packet Attrs
Query max number of elements per packet allowed: 4.

Determine the number of elements per packet: 1.

Reconcile producer's and consumer's attribute lists of element 0.

Send the reconciled attribute list of element 0 to producer and consumer.

Pool creates a new packet 0:

Create buffer object of element 0 with the reconciled attribute list.

Assign pool cookie 1 to the packet, and
                        send this new packet (handle = fffffffffffffffe) to producer and consumer.

Send buffer object of element 0 to producer and consumer.

Pool creates a new packet 1:

Create buffer object of element 0 with the reconciled attribute list.

Assign pool cookie 2 to the packet, and
                        send this new packet (handle = fffffffffffffffd) to producer and consumer.

Send buffer object of element 0 to producer and consumer.

Pool creates a new packet 2:

Create buffer object of element 0 with the reconciled attribute list.

Assign pool cookie 3 to the packet, and
                        send this new packet (handle = fffffffffffffffc) to producer and consumer.

Send buffer object of element 0 to producer and consumer.

Pool creates a new packet 3:

Create buffer object of element 0 with the reconciled attribute list.

Assign pool cookie 4 to the packet, and
                        send this new packet (handle = fffffffffffffffb) to producer and consumer.

Send buffer object of element 0 to producer and consumer.

Receive the number of elements per packet from pool: 1.

Received PacketStatus (cookie = 1) from consumer, total received = 1.

Receive reconciled attributes of element0from pool.
Received PacketStatus (cookie = 2) from consumer, total received = 2.

Receive a new packet (handle = fffffffffffffffe),
                        1 packet(s) received.

Assign cookie c00c1e5 to the packet (handle = 0x438560).

Received PacketStatus (cookie = 1) from producer, total received = 1.

Receive buffer object of element 0.

Received PacketStatus (cookie = 3) from consumer, total received = 3.

Receive a new packet (handle = fffffffffffffffd),
                        2 packet(s) received.

Assign cookie c00c1e6 to the packet (handle = 0x4385a8).

Received PacketStatus (cookie = 2) from producer, total received = 2.

Receive buffer object of element 0.

Received PacketStatus (cookie = 4) from consumer, total received = 4.

Receive a new packet (handle = fffffffffffffffc),
                        3 packet(s) received.

Assign cookie c00c1e7 to the packet (handle = 0x4385f0).

Received PacketStatus (cookie = 3) from producer, total received = 3.

Receive buffer object of element 0.

Received ElementStatus (cookie = 1, idx = 0) from consumer, total received = 1.

Receive a new packet (handle = fffffffffffffffb),
                        4 packet(s) received.

Assign cookie c00c1e8 to the packet (handle = 0x438638).

Received PacketStatus (cookie = 4) from producer, total received = 4.

Receive buffer object of element 0.

Producer receives consumer's sync object:

Producer initializes NvSciSyncFence:

Producer maps buffer objects:

Producer Mapping element: 0 of cookie c00c1e5.
Accept elements in packet (handle = fffffffffffffffe).

Producer Mapping element: 0 of cookie c00c1e6.
Accept elements in packet (handle = fffffffffffffffd).

Producer Mapping element: 0 of cookie c00c1e7.
Accept elements in packet (handle = fffffffffffffffc).

Producer Mapping element: 0 of cookie c00c1e8.
Accept elements in packet (handle = fffffffffffffffb).

Received ElementStatus (cookie = 1, idx = 0) from producer, total received = 1.

Received ElementStatus (cookie = 2, idx = 0) from producer, total received = 2.

Received ElementStatus (cookie = 3, idx = 0) from producer, total received = 3.

Received ElementStatus (cookie = 4, idx = 0) from producer, total received = 4.

Received ElementStatus (cookie = 2, idx = 0) from consumer, total received = 2.

Received ElementStatus (cookie = 3, idx = 0) from consumer, total received = 3.

Received ElementStatus (cookie = 4, idx = 0) from consumer, total received = 4.

Pool received all prod / cons packet Status
========================================= ==================================================


 ========================= Producer enters Streaming phase =========================

Producer acquires a packet 0:

Producer received PACKET_READY event.
Producer obtained a packet (cookie = c00c1e5) from pool.
Process payload (cookie = c00c1e5).
WARNING: Empty fence supplied as prefence.Skipping prefence insertion
Send the packet (cookie = c00c1e5, handle = fffffffffffffffe).
Producer acquires a packet 1:

Producer received PACKET_READY event.
Producer obtained a packet (cookie = c00c1e6) from pool.
Process payload (cookie = c00c1e6).
WARNING: Empty fence supplied as prefence.Skipping prefence insertion
Send the packet (cookie = c00c1e6, handle = fffffffffffffffd).
Producer acquires a packet 2:

Producer received PACKET_READY event.
Producer obtained a packet (cookie = c00c1e7) from pool.
Process payload (cookie = c00c1e7).
WARNING: Empty fence supplied as prefence.Skipping prefence insertion
Send the packet (cookie = c00c1e7, handle = fffffffffffffffc).
Producer acquires a packet 3:

Producer received PACKET_READY event.
Producer obtained a packet (cookie = c00c1e8) from pool.
Process payload (cookie = c00c1e8).
WARNING: Empty fence supplied as prefence.Skipping prefence insertion
Send the packet (cookie = c00c1e8, handle = fffffffffffffffb).
Producer acquires a packet 4:

Producer received PACKET_READY event.
Producer obtained a packet (cookie = c00c1e5) from pool.
Process payload (cookie = c00c1e5).
Send the packet (cookie = c00c1e5, handle = fffffffffffffffe).
Producer acquires a packet 5:

Producer received PACKET_READY event.
Producer obtained a packet (cookie = c00c1e6) from pool.
Process payload (cookie = c00c1e6).
Send the packet (cookie = c00c1e6, handle = fffffffffffffffd).
Producer acquires a packet 6:

Producer received PACKET_READY event.
Producer obtained a packet (cookie = c00c1e7) from pool.
Process payload (cookie = c00c1e7).
Send the packet (cookie = c00c1e7, handle = fffffffffffffffc).
Producer acquires a packet 7:

Producer received PACKET_READY event.
Producer obtained a packet (cookie = c00c1e8) from pool.
Process payload (cookie = c00c1e8).
Send the packet (cookie = c00c1e8, handle = fffffffffffffffb).
Producer acquires a packet 8:

Producer received PACKET_READY event.
Producer obtained a packet (cookie = c00c1e5) from pool.
Process payload (cookie = c00c1e5).
Send the packet (cookie = c00c1e5, handle = fffffffffffffffe).
Producer acquires a packet 9:

Producer received PACKET_READY event.
Producer obtained a packet (cookie = c00c1e6) from pool.
Process payload (cookie = c00c1e6).
Send the packet (cookie = c00c1e6, handle = fffffffffffffffd).


 ========================= Producer Streaming phase End =========================

Closing Producer channel
nvidia@tegra-ubuntu:~$ ./nvscistream_sample -c nvscistream_1 -q 1
CUDA Consumer Created
Consumer channel created
Query max number of sync objects allowed: 4.

Number of waiter sync objects: 1.



 ========================= Consumer Connection setup =========================

Connecting over Ipc... waiting for producer connection
Consumer channel connected



 ========================= Consumer Sync requirement setup =========================

Consumer creates NvSciSync attributes:

Create signaler's sync attribute list.
Set CUDA-signaler attribute value.
Create waiter's sync attribute list.
Set CUDA-waiter attribute value.
Consumer sends sync attribute to producer:

Send waiter's sync object requirement.

========================================= ==================================================


 ========================= Consumer Packet requirement setup =========================

Consumer creates NvSciBuf attributes:

Create NvSciBuf attribute list of element 0.
Set attribute value of element 0.
Consumer sends packet requirements to the pool:

Send the number of elements per packet to the pool, 1.

Send buffer attributes of element 0.

========================================= ==================================================


 ========================= Consumer finalize requirements and map resources =========================

Receive waiter's sync object requirement.

Consumer received producer attributes
Common: Reconcile its signaler attributes and the reveived waiter attributes.

Common: Create NvSciSync object 0 with the reconciled attribute list.

Consumer reconciled producer attributes and creates sync object:
        sending sync objects to producer...
Send number of sync objects, 1.

Send sync object 0.

Receive the number of sync objects, 1.

Receive sync object 0.

Receive the number of elements per packet from pool: 1.

Receive reconciled attributes of element0from pool.
Receive a new packet (handle = 18446744073709551614),
                        1 packet(s) received.

Assign cookie c00c1e5 to the packet (handle = 0x438340).

Receive buffer object of element 0.

Receive a new packet (handle = fffffffffffffffd),
                        2 packet(s) received.

Assign cookie c00c1e6 to the packet (handle = 0x438388).

Receive buffer object of element 0.

Receive a new packet (handle = fffffffffffffffc),
                        3 packet(s) received.

Assign cookie c00c1e7 to the packet (handle = 0x4383d0).

Receive buffer object of element 0.

Receive a new packet (handle = fffffffffffffffb),
                        4 packet(s) received.

Assign cookie c00c1e8 to the packet (handle = 0x438418).

Receive buffer object of element 0.

Consumer maps sync objects:

Consumer initializes NvSciSyncFence:

Consumer maps buffer objects:

Consumer Mapping element: 0 of cookie c00c1e5.
Accept elements in packet (handle = fffffffffffffffe).

Consumer Mapping element: 0 of cookie c00c1e6.
Accept elements in packet (handle = fffffffffffffffd).

Consumer Mapping element: 0 of cookie c00c1e7.
Accept elements in packet (handle = fffffffffffffffc).

Consumer Mapping element: 0 of cookie c00c1e8.
Accept elements in packet (handle = fffffffffffffffb).

========================================= ==================================================


 ========================= Consumer enters Streaming phase =========================

Consumer acquires a packet 0:

Receive PACKET_READY event.
Acquire a packet (cookie = c00c1e5).
Process payload (cookie = c00c1e5).
  --> Received diverse values
Release the packet (cookie = c00c1e5, handle = fffffffffffffffe).
Consumer acquires a packet 1:

Receive PACKET_READY event.
Acquire a packet (cookie = c00c1e6).
Process payload (cookie = c00c1e6).
  --> Received diverse values
Release the packet (cookie = c00c1e6, handle = fffffffffffffffd).
Consumer acquires a packet 2:

Receive PACKET_READY event.
Acquire a packet (cookie = c00c1e7).
Process payload (cookie = c00c1e7).
  --> Received diverse values
Release the packet (cookie = c00c1e7, handle = fffffffffffffffc).
Consumer acquires a packet 3:

Receive PACKET_READY event.
Acquire a packet (cookie = c00c1e8).
Process payload (cookie = c00c1e8).
  --> Received diverse values
Release the packet (cookie = c00c1e8, handle = fffffffffffffffb).
Consumer acquires a packet 4:

Receive PACKET_READY event.
Acquire a packet (cookie = c00c1e5).
Process payload (cookie = c00c1e5).
  --> Received diverse values
Release the packet (cookie = c00c1e5, handle = fffffffffffffffe).
Consumer acquires a packet 5:

Receive PACKET_READY event.
Acquire a packet (cookie = c00c1e6).
Process payload (cookie = c00c1e6).
  --> Received diverse values
Release the packet (cookie = c00c1e6, handle = fffffffffffffffd).
Consumer acquires a packet 6:

Receive PACKET_READY event.
Acquire a packet (cookie = c00c1e7).
Process payload (cookie = c00c1e7).
  --> Received diverse values
Release the packet (cookie = c00c1e7, handle = fffffffffffffffc).
Consumer acquires a packet 7:

Receive PACKET_READY event.
Acquire a packet (cookie = c00c1e8).
Process payload (cookie = c00c1e8).
  --> Received diverse values
Release the packet (cookie = c00c1e8, handle = fffffffffffffffb).
Consumer acquires a packet 8:

Receive PACKET_READY event.
Acquire a packet (cookie = c00c1e5).
Process payload (cookie = c00c1e5).
  --> Received diverse values
Release the packet (cookie = c00c1e5, handle = fffffffffffffffe).
Consumer acquires a packet 9:

Receive PACKET_READY event.
Acquire a packet (cookie = c00c1e6).
Process payload (cookie = c00c1e6).
  --> Received diverse values
Release the packet (cookie = c00c1e6, handle = fffffffffffffffd).


 ========================= Consumer Streaming phase End =========================

Closing Consumer channel

Thanks for the information @VickNV.

Can you try with this modified cuda_consumer.cpp and tell me how many matches/missmatches are reported? I get only missmatches when I try that.
cuda_consumer.cpp (14.8 KB)

any problem in your previous zip package? What’s the result of using the binary inside on DRIVE Software 10? Why don’t you clarify our different results first?

I downloaded and run the zip package that I posted in this thread and the results did not change.

You find my results of the binary inside the DRIVE Software 10 in this thread. When I compile the provided source code, I do get the same output.

The problem with that is that this version outputs only a minimal amount of information, so I thought maybe having a little bit more information could help to debug. Did you actually run the binary in the zip I posted or did you compile the source code? Do you get the same result in both cases?

Thanks for the clarification!

I didn’t compile the code. I just ran your binary after flashing my target system with DRIVE Software 10 and then provided your the ogs of both sides at my previous post.

Can you confirm that this means you are using Drive OS 5.1.6.1? I have seen that newer versions, e.g. 5.2.0, are available in the developer are available for the NVONLINE program, but I could not find out what Drive Software version they are associated with. May I also know what SDK manager version you have been using to flash the Drive AGX?

I created and compiled a new version of the nvscistream sample to get a bit more output. I see the following output:
On the sender side:

...
Send sync object 0.

  --> Creating packet 0: Checksum 128194560
     First 10 elements: 0 1 2 3 4 5 6 7 8 9
      Last 10 elements: 45 46 47 48 49 50 51 52 53 54

  --> Creating packet 1: Checksum 132341760
     First 10 elements: 1 2 3 4 5 6 7 8 9 10
      Last 10 elements: 46 47 48 49 50 51 52 53 54 55

  --> Creating packet 2: Checksum 136488960
     First 10 elements: 2 3 4 5 6 7 8 9 10 11
      Last 10 elements: 47 48 49 50 51 52 53 54 55 56

  --> Creating packet 3: Checksum 140636160
     First 10 elements: 3 4 5 6 7 8 9 10 11 12
      Last 10 elements: 48 49 50 51 52 53 54 55 56 57

Create NvSciBuf attribute list of element 0.
...

While the receiving side prints :

  --> Received packet 0: Checksum 1069547520
      First 10 elements: 255 255 255 255 255 255 255 255 255 255
       Last 10 elements: 255 255 255 255 255 255 255 255 255 255

for each received packet. The Received values are the same for all packets.

@VickNV could you run this version on your device and share what you get as output? Maybe that can help us to identify the problem.

nvscistream.zip (56.9 KB)

Yes, I’m using DRIVE OS 5.1.6.1. As of today, it’s the latest developer site release and the forum is intended for support of developer site releases. DRIVE OS 5.1.6.1 is included in DRIVE Software 10 (see below table in its release notes).

About SDK Manager, I’m using 1.2.0.6738.

I tried to run the binary in the zip attached in your previous post but got below error. Could you help to check it?

nvidia@tegra-ubuntu:~$ ./nvscistream_sample -p nvscistream_0
!err[L:81]:nvsciipc_ipc_check_end: pid not 0, but process doesn't exist, (pid:8191)
!err[L:614]:nvsciipc_ipc_open_endpoint: init resources is failed: 256
!err[L:286]:NvSciIpcOpenEndpoint: Failed to open nvsciipc [INTER_PROCESS] endpoint: 256
channel_producer.cpp (56), initIpc: NvSci error 100

Thanks for the clarification of the versions.

That is the error you are typically getting if you don’t reset the IPC channels between runs by executing

sudo rm -rf /dev/mqueue/*
sudo rm -rf /dev/shm/*

like you suggested in this post.

Sorry. too many context switch. :P

Below is my result. FYI.

nvidia@tegra-ubuntu:~$ ./nvscistream_sample -p nvscistream_0
NvMedia producer created
Producer channel created
Query max number of sync objects allowed: 4.

Number of waiter sync objects: 1.



 ========================= Producer Connection setup =========================

Connecting over Ipc... waiting for consumer connection

Producer channel connected
========================================= ==================================================


 ========================= Producer Sync requirement setup =========================

Producer creates NvSciSync attributes:

Create signaler's sync attribute list.
Set nvmedia-signaler attribute value.
Create waiter's sync attribute list.
Set nvmedia-waiter attribute value.
Producer sends sync attribute to producer:

Send waiter's sync object requirement.

========================================= ==================================================


 ========================= Producer Packet requirement setup =========================

Producer creates NvSciBuf attributes:

  --> Creating packet 0: Checksum 128194560
     First 10 elements: 0 1 2 3 4 5 6 7 8 9
      Last 10 elements: 45 46 47 48 49 50 51 52 53 54

  --> Creating packet 1: Checksum 132341760
     First 10 elements: 1 2 3 4 5 6 7 8 9 10
      Last 10 elements: 46 47 48 49 50 51 52 53 54 55

  --> Creating packet 2: Checksum 136488960
     First 10 elements: 2 3 4 5 6 7 8 9 10 11
      Last 10 elements: 47 48 49 50 51 52 53 54 55 56

  --> Creating packet 3: Checksum 140636160
     First 10 elements: 3 4 5 6 7 8 9 10 11 12
      Last 10 elements: 48 49 50 51 52 53 54 55 56 57

Create NvSciBuf attribute list of element 0.
Set attribute value of element 0.
Producer sends packet requirements to the pool:

Send the number of elements per packet to the pool, 1.

Send buffer attributes of element 0.

========================================= ==================================================


 ========================= Producer finalize requirements and map resources =========================

Pool + Producer receive packet and resource requirements.
and process them once all are received

Receive waiter's sync object requirement.

Producer received producer attributes
Common: Reconcile its signaler attributes and the reveived waiter attributes.

Common: Create NvSciSync object 0 with the reconciled attribute list.

Producer reconciled producer attributes and creates sync object:
        sending sync objects to consumer...
Send number of sync objects, 1.

Send sync object 0.

Pool Receives number of elements per packet from producer: 1.

Receive the number of sync objects, 1.

Pool Receives number of elements per packet from consumer: 1.

Receive sync object 0.

Pool Receives packet capabilities of element 0 from producer.

Pool Receives packet requirements of element 0 from consumer.

Pool received all prod / cons packet Attrs
Query max number of elements per packet allowed: 4.

Determine the number of elements per packet: 1.

Reconcile producer's and consumer's attribute lists of element 0.

Send the reconciled attribute list of element 0 to producer and consumer.

Pool creates a new packet 0:

Create buffer object of element 0 with the reconciled attribute list.

Assign pool cookie 1 to the packet, and
                        send this new packet (handle = fffffffffffffffe) to producer and consumer.

Send buffer object of element 0 to producer and consumer.

Pool creates a new packet 1:

Create buffer object of element 0 with the reconciled attribute list.

Assign pool cookie 2 to the packet, and
                        send this new packet (handle = fffffffffffffffd) to producer and consumer.

Send buffer object of element 0 to producer and consumer.

Pool creates a new packet 2:

Create buffer object of element 0 with the reconciled attribute list.

Assign pool cookie 3 to the packet, and
                        send this new packet (handle = fffffffffffffffc) to producer and consumer.

Send buffer object of element 0 to producer and consumer.

Pool creates a new packet 3:

Create buffer object of element 0 with the reconciled attribute list.

Assign pool cookie 4 to the packet, and
                        send this new packet (handle = fffffffffffffffb) to producer and consumer.

Send buffer object of element 0 to producer and consumer.

Receive the number of elements per packet from pool: 1.

Received PacketStatus (cookie = 1) from consumer, total received = 1.

Receive reconciled attributes of element0from pool.
Received PacketStatus (cookie = 2) from consumer, total received = 2.

Receive a new packet (handle = fffffffffffffffe),
                        1 packet(s) received.

Assign cookie c00c1e5 to the packet (handle = 0x438560).

Received PacketStatus (cookie = 1) from producer, total received = 1.

Receive buffer object of element 0.

Received PacketStatus (cookie = 4) from consumer, total received = 3.

Receive a new packet (handle = fffffffffffffffd),
                        2 packet(s) received.

Assign cookie c00c1e6 to the packet (handle = 0x4385a8).

Received PacketStatus (cookie = 2) from producer, total received = 2.

Receive buffer object of element 0.

Received PacketStatus (cookie = 3) from consumer, total received = 4.

Receive a new packet (handle = fffffffffffffffc),
                        3 packet(s) received.

Assign cookie c00c1e7 to the packet (handle = 0x4385f0).

Received PacketStatus (cookie = 3) from producer, total received = 3.

Receive buffer object of element 0.

Received ElementStatus (cookie = 1, idx = 0) from consumer, total received = 1.

Receive a new packet (handle = fffffffffffffffb),
                        4 packet(s) received.

Assign cookie c00c1e8 to the packet (handle = 0x438638).

Received PacketStatus (cookie = 4) from producer, total received = 4.

Receive buffer object of element 0.

Producer receives consumer's sync object:

Producer initializes NvSciSyncFence:

Producer maps buffer objects:

Producer Mapping element: 0 of cookie c00c1e5.
Accept elements in packet (handle = fffffffffffffffe).

Producer Mapping element: 0 of cookie c00c1e6.
Accept elements in packet (handle = fffffffffffffffd).

Producer Mapping element: 0 of cookie c00c1e7.
Accept elements in packet (handle = fffffffffffffffc).

Producer Mapping element: 0 of cookie c00c1e8.
Accept elements in packet (handle = fffffffffffffffb).

Received ElementStatus (cookie = 1, idx = 0) from producer, total received = 1.

Received ElementStatus (cookie = 2, idx = 0) from producer, total received = 2.

Received ElementStatus (cookie = 3, idx = 0) from producer, total received = 3.

Received ElementStatus (cookie = 4, idx = 0) from producer, total received = 4.

Received ElementStatus (cookie = 2, idx = 0) from consumer, total received = 2.

Received ElementStatus (cookie = 4, idx = 0) from consumer, total received = 3.

Received ElementStatus (cookie = 3, idx = 0) from consumer, total received = 4.

Pool received all prod / cons packet Status
========================================= ==================================================


 ========================= Producer enters Streaming phase =========================

Producer acquires a packet 0:

Producer received PACKET_READY event.
Producer obtained a packet (cookie = c00c1e5) from pool.
Process payload (cookie = c00c1e5).
WARNING: Empty fence supplied as prefence.Skipping prefence insertion
Send the packet (cookie = c00c1e5, handle = fffffffffffffffe).
Producer acquires a packet 1:

Producer received PACKET_READY event.
Producer obtained a packet (cookie = c00c1e6) from pool.
Process payload (cookie = c00c1e6).
WARNING: Empty fence supplied as prefence.Skipping prefence insertion
Send the packet (cookie = c00c1e6, handle = fffffffffffffffd).
Producer acquires a packet 2:

Producer received PACKET_READY event.
Producer obtained a packet (cookie = c00c1e8) from pool.
Process payload (cookie = c00c1e8).
WARNING: Empty fence supplied as prefence.Skipping prefence insertion
Send the packet (cookie = c00c1e8, handle = fffffffffffffffb).
Producer acquires a packet 3:

Producer received PACKET_READY event.
Producer obtained a packet (cookie = c00c1e7) from pool.
Process payload (cookie = c00c1e7).
WARNING: Empty fence supplied as prefence.Skipping prefence insertion
Send the packet (cookie = c00c1e7, handle = fffffffffffffffc).
Producer acquires a packet 4:

Producer received PACKET_READY event.
Producer obtained a packet (cookie = c00c1e5) from pool.
Process payload (cookie = c00c1e5).
Send the packet (cookie = c00c1e5, handle = fffffffffffffffe).
Producer acquires a packet 5:

Producer received PACKET_READY event.
Producer obtained a packet (cookie = c00c1e6) from pool.
Process payload (cookie = c00c1e6).
Send the packet (cookie = c00c1e6, handle = fffffffffffffffd).
Producer acquires a packet 6:

Producer received PACKET_READY event.
Producer obtained a packet (cookie = c00c1e8) from pool.
Process payload (cookie = c00c1e8).
Send the packet (cookie = c00c1e8, handle = fffffffffffffffb).
Producer acquires a packet 7:

Producer received PACKET_READY event.
Producer obtained a packet (cookie = c00c1e7) from pool.
Process payload (cookie = c00c1e7).
Send the packet (cookie = c00c1e7, handle = fffffffffffffffc).
Producer acquires a packet 8:

Producer received PACKET_READY event.
Producer obtained a packet (cookie = c00c1e5) from pool.
Process payload (cookie = c00c1e5).
Send the packet (cookie = c00c1e5, handle = fffffffffffffffe).
Producer acquires a packet 9:

Producer received PACKET_READY event.
Producer obtained a packet (cookie = c00c1e6) from pool.
Process payload (cookie = c00c1e6).
Send the packet (cookie = c00c1e6, handle = fffffffffffffffd).


 ========================= Producer Streaming phase End =========================

Closing Producer channel
nvidia@tegra-ubuntu:~$ ./nvscistream_sample -c nvscistream_1 -q 1
CUDA Consumer Created
Consumer channel created
Query max number of sync objects allowed: 4.

Number of waiter sync objects: 1.



 ========================= Consumer Connection setup =========================

Connecting over Ipc... waiting for producer connection
Consumer channel connected



 ========================= Consumer Sync requirement setup =========================

Consumer creates NvSciSync attributes:

Create signaler's sync attribute list.
Set CUDA-signaler attribute value.
Create waiter's sync attribute list.
Set CUDA-waiter attribute value.
Consumer sends sync attribute to producer:

Send waiter's sync object requirement.

========================================= ==================================================


 ========================= Consumer Packet requirement setup =========================

Consumer creates NvSciBuf attributes:

Create NvSciBuf attribute list of element 0.
Set attribute value of element 0.
Consumer sends packet requirements to the pool:

Send the number of elements per packet to the pool, 1.

Send buffer attributes of element 0.

========================================= ==================================================


 ========================= Consumer finalize requirements and map resources =========================

Receive waiter's sync object requirement.

Consumer received producer attributes
Common: Reconcile its signaler attributes and the reveived waiter attributes.

Common: Create NvSciSync object 0 with the reconciled attribute list.

Consumer reconciled producer attributes and creates sync object:
        sending sync objects to producer...
Send number of sync objects, 1.

Send sync object 0.

Receive the number of sync objects, 1.

Receive sync object 0.

Receive the number of elements per packet from pool: 1.

Receive reconciled attributes of element0from pool.
Receive a new packet (handle = 18446744073709551614),
                        1 packet(s) received.

Assign cookie c00c1e5 to the packet (handle = 0x438340).

Receive buffer object of element 0.

Receive a new packet (handle = fffffffffffffffd),
                        2 packet(s) received.

Assign cookie c00c1e6 to the packet (handle = 0x438388).

Receive buffer object of element 0.

Receive a new packet (handle = fffffffffffffffb),
                        3 packet(s) received.

Assign cookie c00c1e7 to the packet (handle = 0x4383d0).

Receive buffer object of element 0.

Receive a new packet (handle = fffffffffffffffc),
                        4 packet(s) received.

Assign cookie c00c1e8 to the packet (handle = 0x438418).

Receive buffer object of element 0.

Consumer maps sync objects:

Consumer initializes NvSciSyncFence:

Consumer maps buffer objects:

Consumer Mapping element: 0 of cookie c00c1e5.
Accept elements in packet (handle = fffffffffffffffe).

Consumer Mapping element: 0 of cookie c00c1e6.
Accept elements in packet (handle = fffffffffffffffd).

Consumer Mapping element: 0 of cookie c00c1e7.
Accept elements in packet (handle = fffffffffffffffb).

Consumer Mapping element: 0 of cookie c00c1e8.
Accept elements in packet (handle = fffffffffffffffc).

========================================= ==================================================


 ========================= Consumer enters Streaming phase =========================

Consumer acquires a packet 0:

Receive PACKET_READY event.
Acquire a packet (cookie = c00c1e5).
Process payload (cookie = c00c1e5).
  --> Received packet 0: Checksum 128194560
      First 10 elements: 0 1 2 3 4 5 6 7 8 9
       Last 10 elements: 0 0 0 0 0 0 0 0 0 0

Release the packet (cookie = 201376229, handle = 18446744073709551614).
Consumer acquires a packet 1:

Receive PACKET_READY event.
Acquire a packet (cookie = c00c1e6).
Process payload (cookie = c00c1e6).
  --> Received packet 1: Checksum 139314196
      First 10 elements: 1 2 3 4 5 6 7 8 9 10
       Last 10 elements: 124 85 100 202 102 55 148 172 153 115

Release the packet (cookie = 201376230, handle = 18446744073709551613).
Consumer acquires a packet 2:

Receive PACKET_READY event.
Acquire a packet (cookie = c00c1e7).
Process payload (cookie = c00c1e7).
  --> Received packet 2: Checksum 145377255
      First 10 elements: 3 4 5 6 7 8 9 10 11 12
       Last 10 elements: 0 0 0 0 0 0 249 66 24 169

Release the packet (cookie = 201376231, handle = 18446744073709551611).
Consumer acquires a packet 3:

Receive PACKET_READY event.
Acquire a packet (cookie = c00c1e8).
Process payload (cookie = c00c1e8).
  --> Received packet 3: Checksum 141325840
      First 10 elements: 2 3 4 5 6 7 8 9 10 11
       Last 10 elements: 255 23 222 118 255 151 31 32 3 213

Release the packet (cookie = 201376232, handle = 18446744073709551612).
Consumer acquires a packet 4:

Receive PACKET_READY event.
Acquire a packet (cookie = c00c1e5).
Process payload (cookie = c00c1e5).
  --> Received packet 0: Checksum 128194560
      First 10 elements: 0 1 2 3 4 5 6 7 8 9
       Last 10 elements: 0 0 0 0 0 0 0 0 0 0

Release the packet (cookie = 201376229, handle = 18446744073709551614).
Consumer acquires a packet 5:

Receive PACKET_READY event.
Acquire a packet (cookie = c00c1e6).
Process payload (cookie = c00c1e6).
  --> Received packet 1: Checksum 139314196
      First 10 elements: 1 2 3 4 5 6 7 8 9 10
       Last 10 elements: 124 85 100 202 102 55 148 172 153 115

Release the packet (cookie = 201376230, handle = 18446744073709551613).
Consumer acquires a packet 6:

Receive PACKET_READY event.
Acquire a packet (cookie = c00c1e7).
Process payload (cookie = c00c1e7).
  --> Received packet 2: Checksum 145377255
      First 10 elements: 3 4 5 6 7 8 9 10 11 12
       Last 10 elements: 0 0 0 0 0 0 249 66 24 169

Release the packet (cookie = 201376231, handle = 18446744073709551611).
Consumer acquires a packet 7:

Receive PACKET_READY event.
Acquire a packet (cookie = c00c1e8).
Process payload (cookie = c00c1e8).
  --> Received packet 3: Checksum 141325840
      First 10 elements: 2 3 4 5 6 7 8 9 10 11
       Last 10 elements: 255 23 222 118 255 151 31 32 3 213

Release the packet (cookie = 201376232, handle = 18446744073709551612).
Consumer acquires a packet 8:

Receive PACKET_READY event.
Acquire a packet (cookie = c00c1e5).
Process payload (cookie = c00c1e5).
  --> Received packet 0: Checksum 128194560
      First 10 elements: 0 1 2 3 4 5 6 7 8 9
       Last 10 elements: 0 0 0 0 0 0 0 0 0 0

Release the packet (cookie = 201376229, handle = 18446744073709551614).
Consumer acquires a packet 9:

Receive PACKET_READY event.
Acquire a packet (cookie = c00c1e6).
Process payload (cookie = c00c1e6).
  --> Received packet 1: Checksum 139314196
      First 10 elements: 1 2 3 4 5 6 7 8 9 10
       Last 10 elements: 124 85 100 202 102 55 148 172 153 115

Release the packet (cookie = 201376230, handle = 18446744073709551613).


 ========================= Consumer Streaming phase End =========================

Closing Consumer channel

Hi @VickNV,

it seems the communication works correctly on your device. Therefore I decided to re-flash one of our DriveAGX Pegasus and try again. I realized that there is a new version of DRIVE Software 10.0 available now (called rev.2). I don’t know what the differences are, as there are no release notes. The only thing I noticed are some different folder names on the host machine.

Even with the newly flashed DriveAGX Pegasus, the sample still does not work for me. I downloaded the executable from the forum and still, I get the same output I posted previously. Anybody has any idea what I could try to fix that?

Do you have more than one systems? Do other systems have the same issue?

Yes, we do have 3 systems. All show the same behavior. Two were flashed to DRIVE Software 10 by us, one of them has the original DRIVE Software 10 installation from NVIDIA on it.

I’ll install DRIVE Software 10 onto another system and see if I can reproduce your issue.

1 Like

Right after installed DRIVE Software 10.0 rev. 2 with SDK Manager 1.3.1, I ran the binary from your post #10 (same as post #13) and still worked well. FYI.

I’ll find another system to try and let you know the result.

Hi @klaus.kofler,

I found it’s something to do with dGPU. Please run with below command to use iGPU. Thanks!

CUDA_VISIBLE_DEVICES=1 ./nvscistream_sample -c nvscistream_1 -q 1

dGPU support of the sample application will be available from the next release. Thanks!