DriveWorks SDK Reference
3.5.78 Release
For Test and Development only

Localization Interface

Detailed Description

Localization module for HD maps.

The localization module uses sensor data from camera, radar, or lidar to localize the vehicle to a precise pose on an HD map.

Note
SW Release Applicability: These APIs are available in NVIDIA DRIVE Software releases.

Data Structures

struct  dwLocalizationCameraParameters
 Parameters for initializing the camera localization module. More...
 
struct  dwLocalizationRadarParameters
 Parameters for initializing the radar / lidar localization module. More...
 
struct  dwLocalizationResult
 Output structure obtained from any of the localization modules (camera, radar, lidar, fusion). More...
 

Modules

 Localization Fusion Interface
 Localization fusion module for HD maps.
 

Macros

#define DW_LOCALIZATION_MAX_CAMERA_COUNT   8
 

Typedefs

typedef struct dwLocalizationObject * dwLocalizationHandle_t
 Handle to a localization module object. More...
 
typedef dwLocalizationRadarParameters dwLocalizationLidarParameters
 

Enumerations

enum  dwLocalizationResultIndicator {
  DW_LOCALIZATION_RESULT_INDICATOR_NORMAL = 0,
  DW_LOCALIZATION_RESULT_INDICATOR_BAD_SENSOR_DATA0 = (1u << 0),
  DW_LOCALIZATION_RESULT_INDICATOR_BAD_SENSOR_DATA1 = (1u << 1),
  DW_LOCALIZATION_RESULT_INDICATOR_BAD_SENSOR_DATA2 = (1u << 2),
  DW_LOCALIZATION_RESULT_INDICATOR_BAD_SENSOR_DATA3 = (1u << 3),
  DW_LOCALIZATION_RESULT_INDICATOR_BAD_SENSOR_DATA4 = (1u << 4),
  DW_LOCALIZATION_RESULT_INDICATOR_BAD_SENSOR_DATA5 = (1u << 5),
  DW_LOCALIZATION_RESULT_INDICATOR_BAD_SENSOR_DATA6 = (1u << 6),
  DW_LOCALIZATION_RESULT_INDICATOR_BAD_SENSOR_DATA7 = (1u << 7),
  DW_LOCALIZATION_RESULT_INDICATOR_BAD_SENSOR_CALIBRATION0 = (1u << 8),
  DW_LOCALIZATION_RESULT_INDICATOR_BAD_SENSOR_CALIBRATION1 = (1u << 9),
  DW_LOCALIZATION_RESULT_INDICATOR_BAD_SENSOR_CALIBRATION2 = (1u << 10),
  DW_LOCALIZATION_RESULT_INDICATOR_BAD_SENSOR_CALIBRATION3 = (1u << 11),
  DW_LOCALIZATION_RESULT_INDICATOR_BAD_SENSOR_CALIBRATION4 = (1u << 12),
  DW_LOCALIZATION_RESULT_INDICATOR_BAD_SENSOR_CALIBRATION5 = (1u << 13),
  DW_LOCALIZATION_RESULT_INDICATOR_BAD_SENSOR_CALIBRATION6 = (1u << 14),
  DW_LOCALIZATION_RESULT_INDICATOR_BAD_SENSOR_CALIBRATION7 = (1u << 15),
  DW_LOCALIZATION_RESULT_INDICATOR_BAD_GLOBAL_EGOMOTION = (1u << 16),
  DW_LOCALIZATION_RESULT_INDICATOR_BAD_RELATIVE_EGOMOTION = (1u << 17),
  DW_LOCALIZATION_RESULT_INDICATOR_BAD_MAP_CORE = (1u << 18),
  DW_LOCALIZATION_RESULT_INDICATOR_BAD_MAP_SENSOR_LAYER = (1u << 19)
}
 Defines all the possible localization result indicators, set via bits. More...
 

Functions

DW_API_PUBLIC dwStatus dwLocalization_cameraInitialize (dwLocalizationHandle_t *localization, dwConstMapHandle_t map, const dwLocalizationCameraParameters *params, dwContextHandle_t context)
 Create a new camera localization module. More...
 
DW_API_PUBLIC dwStatus dwLocalization_cameraInitParamsFromRig (dwLocalizationCameraParameters *params, dwConstRigHandle_t rig, uint32_t numCameras, const uint32_t cameraIndices[], const dwCameraModelHandle_t cameraHandles[])
 Initializes a camera localization parameters struct for an existing rig. More...
 
DW_API_PUBLIC dwStatus dwLocalization_cameraLocalize (dwLocalizationResult *localizationResult, const dwLaneDetection laneDetectionsPerCamera[], const dwLandmarkDetection poleDetectionsPerCamera[], const dwObjectArray signAndLightDetectionsPerCamera[], const dwGlobalEgomotionResult *globalEgoResult, const dwGlobalEgomotionUncertainty *globalEgoUncertainty, const dwTransformation3f *currToPrev, const dwEgomotionRelativeUncertainty *currToPrevUncertainty, dwTime_t timestamp, dwLocalizationHandle_t localization)
 Localize the rig based on the latest measurements with camera. More...
 
DW_API_PUBLIC dwStatus dwLocalization_cameraSetExtrinsics (uint32_t cameraIndex, const dwTransformation3f *cameraToRig, dwLocalizationHandle_t localization)
 Sets the camera-to-rig extrinsic transformation for a specified camera. More...
 
DW_API_PUBLIC dwStatus dwLocalization_getCUDAStream (cudaStream_t *stream, dwLocalizationHandle_t localization)
 Gets the CUDA stream used by all landmark detections. More...
 
DW_API_PUBLIC dwStatus dwLocalization_lidarInitialize (dwLocalizationHandle_t *localization, dwConstMapHandle_t map, dwMapProviderHandle_t mapProvider, const dwMapsContentLayerBuffer *contentLayers, const dwLocalizationLidarParameters *params, dwContextHandle_t context)
 Create a new lidar localization module. More...
 
DW_API_PUBLIC dwStatus dwLocalization_lidarLocalize (dwLocalizationResult *localizationResult, const dwPointCloud *lidarPoints, const dwGlobalEgomotionResult *globalEgoResult, const dwGlobalEgomotionUncertainty *globalEgoUncertainty, const dwTransformation3f *currToPrev, const dwEgomotionRelativeUncertainty *currToPrevUncertainty, dwTime_t timestamp, dwLocalizationHandle_t localization)
 Localize the rig based on the latest measurements with lidar. More...
 
DW_API_PUBLIC dwStatus dwLocalization_radarInitialize (dwLocalizationHandle_t *localization, dwConstMapHandle_t map, dwMapProviderHandle_t mapProvider, const dwMapsContentLayerBuffer *contentLayers, const dwLocalizationRadarParameters *params, dwContextHandle_t context)
 Create a new radar localization module. More...
 
DW_API_PUBLIC dwStatus dwLocalization_radarLocalize (dwLocalizationResult *localizationResult, const dwVector4f *radarPoints, size_t numPoints, const dwGlobalEgomotionResult *globalEgoResult, const dwGlobalEgomotionUncertainty *globalEgoUncertainty, const dwTransformation3f *currToPrev, const dwEgomotionRelativeUncertainty *currToPrevUncertainty, dwTime_t timestamp, dwLocalizationHandle_t localization)
 Localize the rig based on the latest measurements with radar. More...
 
DW_API_PUBLIC dwStatus dwLocalization_release (dwLocalizationHandle_t localization)
 Releases the localization module. More...
 
DW_API_PUBLIC dwStatus dwLocalization_reset (dwLocalizationHandle_t localization)
 Resets all internal state of the localization module; does not modify properties specified in each initialization function. More...
 
DW_API_PUBLIC dwStatus dwLocalization_setCUDAStream (cudaStream_t stream, dwLocalizationHandle_t localization)
 Sets the CUDA stream for CUDA related operations. More...
 
DW_API_PUBLIC dwStatus dwLocalization_setMap (dwConstMapHandle_t map, dwLocalizationHandle_t localization)
 Sets a new HD Map to localize to. More...
 

Data Structure Documentation

◆ dwLocalizationCameraParameters

struct dwLocalizationCameraParameters
Data Fields
dwCameraModelHandle_t cameraModels[DW_LOCALIZATION_MAX_CAMERA_COUNT] The camera model of each camera.

Note: internally the localization routine will clone these handles, hence the handles can be reused right after the initialization

dwTransformation3f camerasToRig[DW_LOCALIZATION_MAX_CAMERA_COUNT] The extrinsic transformations of each camera to the rig.
uint32_t numCameras The number of cameras to use for localization.

◆ dwLocalizationRadarParameters

struct dwLocalizationRadarParameters
Data Fields
bool asyncLoading Load maps in background thread.
uint32_t pointSkip Optional additional point filtering.

◆ dwLocalizationResult

struct dwLocalizationResult
Data Fields
float32_t confidence A [0, 1] floating point number that indicates the confidence of the localization result.

Note that this feature is not available yet in this release and is set to 1.

dwQuaterniond globalOrientation Global orientation (quaternion) in the local ENU frame set at globalPosition.

When isMapAvailable is true, globalOrientation is computed by combining relativeOrientation and the rotation from the local ENU frame set at the road segment origin to the local ENU frame set at globalPosition. Otherwise, globalOrientation corresponds to the passed-in global egomotion orientation.

dwMapsGeoPoint globalPosition Global WGS84 position (LLA).

When isMapAvailable is true, globalPosition is computed by combining relativePosition and the ENU origin of the road segment. Otherwise, globalPosition corresponds to the passed-in global egomotion position.

dwLocalizationResultIndicator indicator Localization indicator indicates whether there are any problems.

Note that this feature is not available yet in this release and set to DW_LOCALIZATION_RESULT_INDICATOR_NORMAL.

bool isMapAvailable A boolean flag indicating if map is available in the surrounding of the vehicle.

If true, then roadSegmentId, relativePosition, and relativeOrientation are valid. Otherwise, these three fields are invalid.

dwMatrix3d orientationUncertainty A 3x3 covariance matrix indicating orientation uncertainty with respect to the rig frame itself (order: rotation around x, y, z axes) [rad].
dwMatrix3d positionUncertainty A 3x3 covariance matrix indicating position uncertainty with respect to the rig frame itself (order: x,y,z) [m].
dwQuaterniond relativeOrientation Relative orientation in a local ENU frame set at the road segment origin.
dwVector3f relativePosition Relative position in a local ENU frame set at the road segment origin.
dwMapsRoadSegmentId roadSegmentId ID of the road segment that relative pose is with respect to.
dwTime_t timestamp Timestamp that localization was run on.

Macro Definition Documentation

◆ DW_LOCALIZATION_MAX_CAMERA_COUNT

#define DW_LOCALIZATION_MAX_CAMERA_COUNT   8

Definition at line 150 of file Localization.h.

Typedef Documentation

◆ dwLocalizationHandle_t

typedef struct dwLocalizationObject* dwLocalizationHandle_t

Handle to a localization module object.

Definition at line 71 of file Localization.h.

◆ dwLocalizationLidarParameters

Enumeration Type Documentation

◆ dwLocalizationResultIndicator

Defines all the possible localization result indicators, set via bits.

Enumerator
DW_LOCALIZATION_RESULT_INDICATOR_NORMAL 
DW_LOCALIZATION_RESULT_INDICATOR_BAD_SENSOR_DATA0 
DW_LOCALIZATION_RESULT_INDICATOR_BAD_SENSOR_DATA1 
DW_LOCALIZATION_RESULT_INDICATOR_BAD_SENSOR_DATA2 
DW_LOCALIZATION_RESULT_INDICATOR_BAD_SENSOR_DATA3 
DW_LOCALIZATION_RESULT_INDICATOR_BAD_SENSOR_DATA4 
DW_LOCALIZATION_RESULT_INDICATOR_BAD_SENSOR_DATA5 
DW_LOCALIZATION_RESULT_INDICATOR_BAD_SENSOR_DATA6 
DW_LOCALIZATION_RESULT_INDICATOR_BAD_SENSOR_DATA7 
DW_LOCALIZATION_RESULT_INDICATOR_BAD_SENSOR_CALIBRATION0 
DW_LOCALIZATION_RESULT_INDICATOR_BAD_SENSOR_CALIBRATION1 
DW_LOCALIZATION_RESULT_INDICATOR_BAD_SENSOR_CALIBRATION2 
DW_LOCALIZATION_RESULT_INDICATOR_BAD_SENSOR_CALIBRATION3 
DW_LOCALIZATION_RESULT_INDICATOR_BAD_SENSOR_CALIBRATION4 
DW_LOCALIZATION_RESULT_INDICATOR_BAD_SENSOR_CALIBRATION5 
DW_LOCALIZATION_RESULT_INDICATOR_BAD_SENSOR_CALIBRATION6 
DW_LOCALIZATION_RESULT_INDICATOR_BAD_SENSOR_CALIBRATION7 
DW_LOCALIZATION_RESULT_INDICATOR_BAD_GLOBAL_EGOMOTION 
DW_LOCALIZATION_RESULT_INDICATOR_BAD_RELATIVE_EGOMOTION 
DW_LOCALIZATION_RESULT_INDICATOR_BAD_MAP_CORE 
DW_LOCALIZATION_RESULT_INDICATOR_BAD_MAP_SENSOR_LAYER 

Definition at line 76 of file Localization.h.

Function Documentation

◆ dwLocalization_cameraInitialize()

DW_API_PUBLIC dwStatus dwLocalization_cameraInitialize ( dwLocalizationHandle_t localization,
dwConstMapHandle_t  map,
const dwLocalizationCameraParameters params,
dwContextHandle_t  context 
)

Create a new camera localization module.

Parameters
[out]localizationHandle to the camera localization module being initialized.
[in]mapHandle to the maps module used for map data.
[in]paramsLocalization initialization parameters.
[in]contextHandle to the current driveworks context.
Returns
DW_INVALID_ARGUMENT - if given arguments are invalid
DW_FAILURE - if localization library could not be initialized
DW_SUCCESS

◆ dwLocalization_cameraInitParamsFromRig()

DW_API_PUBLIC dwStatus dwLocalization_cameraInitParamsFromRig ( dwLocalizationCameraParameters params,
dwConstRigHandle_t  rig,
uint32_t  numCameras,
const uint32_t  cameraIndices[],
const dwCameraModelHandle_t  cameraHandles[] 
)

Initializes a camera localization parameters struct for an existing rig.

Parameters
[out]paramsPointer to the camera localization parameters struct being initialized.
[in]rigHandle to a vehicle rig configuration instance.
[in]numCamerasThe number of cameras to use for localization.
[in]cameraIndicesThe indices of the cameras to use from the vehicle rig handle.
[in]cameraHandlesThe camera handles initialized from the vehicle rig handle.
Returns
DW_INVALID_ARGUMENT - if given arguments are invalid
DW_INVALID_HANDLE - if a given handle is invalid
DW_NOT_SUPPORTED - if given camera models are not supported
DW_SUCCESS

◆ dwLocalization_cameraLocalize()

DW_API_PUBLIC dwStatus dwLocalization_cameraLocalize ( dwLocalizationResult localizationResult,
const dwLaneDetection  laneDetectionsPerCamera[],
const dwLandmarkDetection  poleDetectionsPerCamera[],
const dwObjectArray  signAndLightDetectionsPerCamera[],
const dwGlobalEgomotionResult globalEgoResult,
const dwGlobalEgomotionUncertainty globalEgoUncertainty,
const dwTransformation3f currToPrev,
const dwEgomotionRelativeUncertainty currToPrevUncertainty,
dwTime_t  timestamp,
dwLocalizationHandle_t  localization 
)

Localize the rig based on the latest measurements with camera.

Parameters
[out]localizationResultLocalization estimation, including the timestamp, the absolute position in wgs84, orientation to ENU coordinate at the absoulte position of the rig, ID of the closest road segment, relative rotation and translation to the origin of the closest road segment, and a flag indicating validity of the relative pose.
[in]laneDetectionsPerCameraPer-camera detected lanes at the current timestamp. The size of the array is assumed to be equal to the number of the cameras that the module was initialized with.
[in]poleDetectionsPerCameraPer-camera detected poles at the current timestamp (can be null if none exists). The size of the array is assumed to be equal to the number of the cameras that the module was initialized with.
[in]signAndLightDetectionsPerCameraPer-camera detected traffic lights or traffic signs in the current timestamp (can be null if none exists). The size of the array is assumed to be equal to the number of the cameras that the module was initialized with.
[in]globalEgoResultGlobal rig position in LLA and orientation (x, y, z, w) mapping from the rig to ENU at global rig position the rig, both at the same timestamp as the detections. Note that both globalEgoResult.validPosition and globalEgoResult.validOrientation have to be true for localization to run successfully for at least once. Otherwise this function will return DW_NOT_AVAILABLE.
[in]globalEgoUncertaintyUncertainty of global position, represented by a 3x3 covariance in ENU in [m], and uncertainty of global orientation, represented by a 3x3 covariance of the equivalent euler angles (order: roll, pitch, yaw) in [rad].
[in]currToPrevThe relative transformation mapping the current frame's pose to the previous frame's pose. Previous denotes the timestamp of the last time dwLocalization_cameraLocalize was called. If this is the first time calling dwLocalization_cameraLocalize, the identity transformation is expected.
[in]currToPrevUncertaintyThe uncertainty of the relative transformation. If this is the first time calling dwLocalization_lidarLocalize, any arbitrary uncertainty is accepted.
[in]timestampTimestamp for the camera frame that landmark detections are from.
[in]localizationHandle to the localization module.
Returns
DW_INVALID_ARGUMENT - if given arguments are invalid
DW_INVALID_HANDLE - if given handle is invalid
DW_FAILURE - if the measurement could not be used or on any other failure, see logs
DW_SUCCESS

◆ dwLocalization_cameraSetExtrinsics()

DW_API_PUBLIC dwStatus dwLocalization_cameraSetExtrinsics ( uint32_t  cameraIndex,
const dwTransformation3f cameraToRig,
dwLocalizationHandle_t  localization 
)

Sets the camera-to-rig extrinsic transformation for a specified camera.

This only needs to be called if transformations specified in dwLocalizationCameraParameters::camerasToRig need be modified after initialization of the localization module.

Parameters
[in]cameraIndexThe index of the camera to set the extrinsic transformation for. This index must correspond with the camera index inside the dwLocalizationCameraParameters used to initialize the module.
[in]cameraToRigTransformation from the specified camera's coordinate system to the vehicle rig's coordinate system.
[in]localizationA handle to the localization module.
Returns
DW_INVALID_ARGUMENT - if given arguments are invalid.
DW_INVALID_HANDLE - If a given handle is invalid.
DW_SUCCESS

◆ dwLocalization_getCUDAStream()

DW_API_PUBLIC dwStatus dwLocalization_getCUDAStream ( cudaStream_t *  stream,
dwLocalizationHandle_t  localization 
)

Gets the CUDA stream used by all landmark detections.

Parameters
[out]streamThe CUDA stream currently used.
[in]localizationA handle to the localization module.
Returns
DW_INVALID_HANDLE - If the given handle is invalid.
DW_SUCCESS

◆ dwLocalization_lidarInitialize()

DW_API_PUBLIC dwStatus dwLocalization_lidarInitialize ( dwLocalizationHandle_t localization,
dwConstMapHandle_t  map,
dwMapProviderHandle_t  mapProvider,
const dwMapsContentLayerBuffer contentLayers,
const dwLocalizationLidarParameters params,
dwContextHandle_t  context 
)

Create a new lidar localization module.

Parameters
[out]localizationHandle to the localization module being initialized.
[in]mapHandle to the maps module used for map data.
[in]mapProviderHandle to map provider for image data.
[in]contentLayersRequested maps image layers for lidar localization.
[in]paramsLidar localization initialization parameters.
[in]contextHandle to the current driveworks context.
Returns
DW_INVALID_ARGUMENT - if given arguments are invalid
DW_FAILURE - if localization could not be initialized
DW_SUCCESS

◆ dwLocalization_lidarLocalize()

DW_API_PUBLIC dwStatus dwLocalization_lidarLocalize ( dwLocalizationResult localizationResult,
const dwPointCloud lidarPoints,
const dwGlobalEgomotionResult globalEgoResult,
const dwGlobalEgomotionUncertainty globalEgoUncertainty,
const dwTransformation3f currToPrev,
const dwEgomotionRelativeUncertainty currToPrevUncertainty,
dwTime_t  timestamp,
dwLocalizationHandle_t  localization 
)

Localize the rig based on the latest measurements with lidar.

Parameters
[out]localizationResultLocalization estimation including the absolute position in wgs84, orientation to ENU coordinate at the absolute position of the rig, id to the closest road segment, relative rotation and translation to the origin of the closest road segment, and a flag indicating validity of relative pose.
[in]lidarPointsBuffer of lidar points with (x, y, z, intensity) each. The points should be allocated on the CPU.
[in]globalEgoResultGlobal rig position in LLA and orientation (x, y, z, w) mapping from the rig to ENU at global rig position the rig, both at the same timestamp as timestamp. Note that both globalEgoResult.validPosition and globalEgoResult.validOrientation have to be true for localization to run successfully for at least once. Otherwise this function will return DW_NOT_AVAILABLE.
[in]globalEgoUncertaintyUncertainty of global position, represented by a 3x3 covariance in ENU in [m], and uncertainty of global orientation, represented by a 3x3 covariance of the equivalent euler angles (order: roll, pitch, yaw) in [rad].
[in]currToPrevThe relative transformation mapping the current frame's pose to the previous frame's pose. Previous denotes the timestamp of the last time dwLocalization_lidarLocalize was called. If this is the first time calling dwLocalization_lidarLocalize, the identity transformation is expected.
[in]currToPrevUncertaintyThe uncertainty of the relative transformation. If this is the first time calling dwLocalization_lidarLocalize, any arbitrary uncertainty is accepted.
[in]timestampTimestamp of points in lidarPoints buffer.
[in]localizationHandle to the localization module.
Returns
DW_INVALID_ARGUMENT - if given arguments are invalid
DW_INVALID_HANDLE - if given handle is invalid
DW_CALL_NOT_ALLOWED - if maps image is currently locked
DW_FAILURE - if module could not localize
DW_SUCCESS

◆ dwLocalization_radarInitialize()

DW_API_PUBLIC dwStatus dwLocalization_radarInitialize ( dwLocalizationHandle_t localization,
dwConstMapHandle_t  map,
dwMapProviderHandle_t  mapProvider,
const dwMapsContentLayerBuffer contentLayers,
const dwLocalizationRadarParameters params,
dwContextHandle_t  context 
)

Create a new radar localization module.

Parameters
[out]localizationHandle to the localization module being initialized.
[in]mapHandle to the maps module used for map data.
[in]mapProviderHandle to map provider for image data.
[in]contentLayersRequested maps image layers for radar localization.
[in]paramsRadar localization initialization parameters.
[in]contextHandle to the current driveworks context.
Returns
DW_INVALID_ARGUMENTS - if given arguments are invalid
DW_FAILURE - if localization could not be initialized
DW_SUCCESS

◆ dwLocalization_radarLocalize()

DW_API_PUBLIC dwStatus dwLocalization_radarLocalize ( dwLocalizationResult localizationResult,
const dwVector4f radarPoints,
size_t  numPoints,
const dwGlobalEgomotionResult globalEgoResult,
const dwGlobalEgomotionUncertainty globalEgoUncertainty,
const dwTransformation3f currToPrev,
const dwEgomotionRelativeUncertainty currToPrevUncertainty,
dwTime_t  timestamp,
dwLocalizationHandle_t  localization 
)

Localize the rig based on the latest measurements with radar.

Parameters
[out]localizationResultLocalization estimation including the absolute position in wgs84, orientation to ENU coordinate at the absolute position of the rig, id to the closest road segment, relative rotation and translation to the origin of the closest road segment, and a flag indicating validity of relative pose.
[in]radarPointsBuffer of radar points with (x, y, z, rcs) each.
[in]numPointsNumber of radar points in buffer.
[in]globalEgoResultGlobal rig position in LLA and orientation (x, y, z, w) mapping from the rig to ENU at global rig position the rig, both at the same timestamp as timestamp. Note that both globalEgoResult.validPosition and globalEgoResult.validOrientation have to be true for localization to run successfully for at least once. Otherwise this function will return DW_NOT_AVAILABLE.
[in]globalEgoUncertaintyUncertainty of global position, represented by a 3x3 covariance in ENU in [m], and uncertainty of global orientation, represented by a 3x3 covariance of the equivalent euler angles (order: roll, pitch, yaw) in [rad].
[in]currToPrevThe relative transformation mapping the current frame's pose to the previous frame's pose. Previous denotes the timestamp of the last time dwLocalization_radarLocalize was called. If this is the first time calling dwLocalization_radarLocalize, the identity transformation is expected.
[in]currToPrevUncertaintyThe uncertainty of the relative transformation. If this is the first time calling dwLocalization_radarLocalize, any arbitrary uncertainty is accepted.
[in]timestampTimestamp of points in radarPoints buffer.
[in]localizationHandle to the localization module.
Returns
DW_INVALID_ARGUMENT - if given arguments are invalid
DW_INVALID_HANDLE - if given handle is invalid
DW_CALL_NOT_ALLOWED - if maps image is currently locked
DW_FAILURE - if module could not localize
DW_SUCCESS

◆ dwLocalization_release()

DW_API_PUBLIC dwStatus dwLocalization_release ( dwLocalizationHandle_t  localization)

Releases the localization module.

Parameters
[in]localizationHandle to the localization module being released.
Returns
DW_INVALID_HANDLE - if given handle is invalid
DW_SUCCESS

◆ dwLocalization_reset()

DW_API_PUBLIC dwStatus dwLocalization_reset ( dwLocalizationHandle_t  localization)

Resets all internal state of the localization module; does not modify properties specified in each initialization function.

Parameters
[in]localizationHandle to the localization module being reset.
Returns
DW_INVALID_HANDLE - if the provided localization handle is invalid.
DW_SUCCESS

◆ dwLocalization_setCUDAStream()

DW_API_PUBLIC dwStatus dwLocalization_setCUDAStream ( cudaStream_t  stream,
dwLocalizationHandle_t  localization 
)

Sets the CUDA stream for CUDA related operations.

Note
The ownership of the stream remains by the callee.
Parameters
[in]streamThe CUDA stream to be used. Default is the default CUDA stream 0.
[in]localizationA handle to the localization module for which to set CUDA stream.
Returns
DW_INVALID_HANDLE - If the given handle is invalid.
DW_SUCCESS

◆ dwLocalization_setMap()

DW_API_PUBLIC dwStatus dwLocalization_setMap ( dwConstMapHandle_t  map,
dwLocalizationHandle_t  localization 
)

Sets a new HD Map to localize to.

The new map is assumed to have consistent road segment IDs with the old map.

Parameters
[in]mapHandle to the maps module used for map data.
[in]localizationHandle to the localization module.
Returns
DW_INVALID_HANDLE - if given handle is invalid
DW_SUCCESS