"sample_lane_detection" of Sample Application Doesn't Execute

I’m trying to execute “sample_lane_detection” of sample application, but it doesn’t execute with error as below.


nvidia@nvidia:~$ /usr/local/driveworks/bin/sample_lane_detection --camera-type=c-ov10640-b1 --input-type=camera --csi-port=ab
\Program Arguments:
–camera-index=0
–camera-type=c-ov10640-b1
–csi-port=ab
–height=576
–input-type=camera
–maxDistance=50.0
–rig=…/./data/samples/laneDetection/rig.xml
–slave=0
–threshold=0.3
–video=…/./data/samples/laneDetection/video_lane.h264
–width=960

nvrm_gpu: Bug 200215060 workaround enabled.
Initialize DriveWorks SDK v0.6.67
TimeSource: monotonic epoch time offset is 1529915553022246
TimeSource: PTP ioctl returned error. Synchronized time will not be available.
TimeSource: Could not detect valid PTP time source at ‘eth0’. Fallback to CLOCK_MONOTONIC.
SDK: Resource failed to mount from ‘…/./data/resources’: VirtualFileSystem: Failed to mount ‘…/./data/resources[.pak]’
SDK: Resources mounted from /usr/local/driveworks-0.6/data/resources
SDK: Create NvMediaDevice
SDK: use EGL display as provided
SAL: identified board as DrivePX2-TegraA
SensorFactory::createSensor() -> camera.gmsl, camera-type=c-ov10640-b1,csi-port=ab,slave=0,serialize=false,camera-count=4,output-format=yuv,camera-mask=0001
CameraGMSL: required FPS = 30, resolution = 1280x1080
***** aurix state *****
CAM_PWR_ON: 0x0
TEGRA_GMSL: TEGRA B
TEGRA_FPDL: TEGRA B
TEGRA_A_HDMI: MXM
TEGRA_B_HDMI: MXM
TEGRA_PCI: TEGRA B
FAN_STATE: UNKNOWN


***** aurix state *****
CAM_PWR_ON: 0x1
TEGRA_GMSL: UNKNOWN
TEGRA_FPDL: UNKNOWN
TEGRA_A_HDMI: UNKNOWN
TEGRA_B_HDMI: UNKNOWN
TEGRA_PCI: UNKNOWN
FAN_STATE: UNKNOWN


NvMediaACPCreate: No Sensor Specifc Config File found in NvPlugin
NvMediaACPCreate: Camera module is not characterized and tuned
Camera image with 1280x1080 at 30 FPS
Driveworks exception thrown: DW_FILE_NOT_FOUND: pugi: file not found:, …/./data/samples/laneDetection/rig.xml

Error dwRigConfiguration_initialize: DW_FILE_NOT_FOUND
Cannot initialize DW subsystems
Driveworks exception thrown: DW_INVALID_ARGUMENT: Cannot cast handle, given instance is a nullptr

Driveworks exception thrown: DW_INVALID_ARGUMENT: Cannot cast handle, given instance is a nullptr

Driveworks exception thrown: DW_INVALID_ARGUMENT: Cannot cast handle, given instance is a nullptr

***** aurix state *****
CAM_PWR_ON: 0x0
TEGRA_GMSL: UNKNOWN
TEGRA_FPDL: UNKNOWN
TEGRA_A_HDMI: UNKNOWN
TEGRA_B_HDMI: UNKNOWN
TEGRA_PCI: UNKNOWN
FAN_STATE: UNKNOWN


Driveworks exception thrown: DW_INVALID_ARGUMENT: Cannot cast handle, given instance is a nullptr

SDK: Release NvMediaDevice

Could you provide me any solution?

Dear hiroyasu.takase,
Can you please check running the sample from /usr/local/driveworks/bin directory.

Dear SivaRamaKrishna,

I checked that sample_hello_world from /usr/local/driveworks/bin directory is able to run.

I want to know solution for following message “Driveworks exception thrown: DW_FILE_NOT_FOUND: pugi: file not found:, …/./data/samples/laneDetection/rig.xml”.

Despite rig.xml file is in /usr/local/driveworks/data/samples/laneDetection directory, that error message shown.

Dear hiroyasu.takase,
From the output I can see you are running the sample from home directory not /usr/local/driveworks/bin. Please go to /usr/local/driveworks/bin and run sample as ./sample_lane_detection .
The path of rig.xml from bin directory is …/data/samples/laneDetection/rig.xml

Dear SivaRamaKrishna,

A situation a little changed. May be along good way.

Current directory move to /usr/local/driveworks/bin before run application and “file not found” message is resolved.

Next, I would like to solve “FileHeader: file header created with development build (patch = -1), assumingcompatibility” and “readFrameCUDA: DW_NOT_READY”.
Could you please teach me the solution for that error messages?

nvidia@nvidia:/usr/local/driveworks/bin$ cd /usr/local/driveworks/bin/nvidia@nvidia:/usr/local/driveworks/bin$ /usr/local/driveworks/bin/sample_lane_detection --camera-type=c-ov10640-b1 --input-type=camera --csi-port=ab
Program Arguments:
--camera-index=0
--camera-type=c-ov10640-b1
--csi-port=ab
--height=576
--input-type=camera
--maxDistance=50.0
--rig=.././data/samples/laneDetection/rig.xml
--slave=0
--threshold=0.3
--video=.././data/samples/laneDetection/video_lane.h264
--width=960

nvrm_gpu: Bug 200215060 workaround enabled.
Initialize DriveWorks SDK v0.6.67
TimeSource: monotonic epoch time offset is 1529983226155480
TimeSource: PTP ioctl returned error. Synchronized time will not be available.
TimeSource: Could not detect valid PTP time source at 'eth0'. Fallback to CLOCK_MONOTONIC.
SDK: Resources mounted from .././data/resources
SDK: Create NvMediaDevice
SDK: use EGL display as provided
SAL: identified board as DrivePX2-TegraA
SensorFactory::createSensor() -> camera.gmsl, camera-type=c-ov10640-b1,csi-port=ab,slave=0,serialize=false,camera-count=4,output-format=yuv,camera-mask=0001
CameraGMSL: required FPS = 30, resolution = 1280x1080
***** aurix state *****
 CAM_PWR_ON: 0x0
 TEGRA_GMSL: TEGRA B
 TEGRA_FPDL: TEGRA B
 TEGRA_A_HDMI: MXM
 TEGRA_B_HDMI: MXM
 TEGRA_PCI: TEGRA B
 FAN_STATE: UNKNOWN
***********************
***** aurix state *****
 CAM_PWR_ON: 0x1
 TEGRA_GMSL: UNKNOWN
 TEGRA_FPDL: UNKNOWN
 TEGRA_A_HDMI: UNKNOWN
 TEGRA_B_HDMI: UNKNOWN
 TEGRA_PCI: UNKNOWN
 FAN_STATE: UNKNOWN
***********************
NvMediaACPCreate: No Sensor Specifc Config File found in NvPlugin
NvMediaACPCreate: Camera module is not characterized and tuned
Camera image with 1280x1080 at 30 FPS
nvmEglStProducerCreateCommon: Entered
nvmEglStProducerCreateCommon: Entered
FileHeader: file header created with development build (patch = -1), assumingcompatibility
readFrameCUDA: DW_NOT_READY
***** aurix state *****
 CAM_PWR_ON: 0x0
 TEGRA_GMSL: UNKNOWN
 TEGRA_FPDL: UNKNOWN
 TEGRA_A_HDMI: UNKNOWN
 TEGRA_B_HDMI: UNKNOWN
 TEGRA_PCI: UNKNOWN
 FAN_STATE: UNKNOWN
***********************
SDK: Release NvMediaDevice
Driveworks SDK released

Dear hiroyasu.takase,
Could you please share camera and setup details to reproduce it on our side.

Dear SivaRamaKrishna,

Unfortunately, I don’t understand details because I’m using assembled hardware to output camera image.

Dear hiroyasu.takase,

Regarding “readFrameCUDA: DW_NOT_READY”, did you finish CUDA environment setting for DPX2?
If not, could please setup CUDA environment for DPX2? Please refer to below commands. Thanks.

$gedit ~/.bashrc
export PATH=/usr/local/cuda-9.0/bin/:$PATH
export LD_LIBRARY_PATH=/usr/local/cuda/targets/aarch64-linux/lib:$LD_LIBRARY_PATH

source ~/.bashrc nvcc --version