DriveWorks SDK Reference
3.0.4260 Release
For Test and Development only

LightSourceNet Workflow

Initialization

The LightSourceNet module creates handles of type dwLightSourceNetHandle_t, which is owned by the application and must be released by the application when not needed anymore.

An instance of type dwLightSourceNetParams encodes parameters (currently only network precision) that configure the LightSourceNet module. To initialize default LightSourceNet parameters:

To initialize a pointer to a dwLightSourceNetHandle_t instance with default parameter values:

An example code snippet to initialize required modules with default values:

// Initialize LightSourceNet
dwLightSourceNetParams m_lightSourceNetParams;
CHECK_DW_ERROR(dwLightSourceNet_initDefaultParams(&m_lightSourceNetParams));
CHECK_DW_ERROR(dwLightSourceNet_initialize(&m_lightSourceNet, &m_lightSourceNetParams, m_sdk));

where m_sdk is an initialized instance of dwContextHandle_t.

The initialized handle of LightSourceNet is used to initialize LightSourceDetector module.

Query Network Specs

With initialized handle to the LightSourceNet module, the following functions can be used to query size of expected input blob, size of output blob and network metadata respectively:

dwStatus dwLightSourceNet_getInputBlobSize(dwBlobSize* inputBlobsize, dwLightSourceNetHandle_t lightSourceNetHandle);

Use for Inference and Post-processing

The LightSourceNet is closely coupled with LightSourceDetector. The neural network inference and post-processing is executed via LightSourceDetector APIs.

Reset and Release

The following functions can be used to reset or release the initialized module handles:

Relevant Tutorials

For usage of a sample application, please refer to LightSourcePerception Sample (LightSourceNet).