Class LocalizationEngine

Class Documentation

class LocalizationEngine

Engine for performing localization using LidarScans and a pre-computed map.

The LocalizationEngine class provides functionality to estimate the pose of a sensor by processing Lidar scans and matching them against a world map. It supports initialization with either a map file or a preloaded map.

See also

LidarScan

Note

Only the “kiss” backend is supported at this time.

Public Functions

LocalizationEngine(const std::vector<std::shared_ptr<ouster::sdk::core::SensorInfo>> &infos, const LocalizationConfig &config, const std::string &map_path)

Constructs the LocalizationEngine.

Parameters:
  • infos[in] – A vector of shared pointers to SensorInfo objects.

  • config[in] – The LocalizationConfig object containing configuration parameters for the localization.

  • map_path[in] – The file path containing the map to be used for localization.

Throws:
  • std::runtime_error – If the specified backend is not supported.

  • std::runtime_error – If the map file cannot be loaded.

LocalizationEngine(const std::vector<std::shared_ptr<ouster::sdk::core::SensorInfo>> &infos, const LocalizationConfig &config, const Eigen::Ref<const ouster::sdk::core::PointCloudXYZf> map)

Constructs the LocalizationEngine.

Parameters:
  • infos[in] – A vector of shared pointers to SensorInfo objects.

  • config[in] – The LocalizationConfig object containing configuration parameters for the localization.

  • map[in] – The preloaded map as a PointCloudXYZf object.

void update(ouster::sdk::core::LidarScanSet &scans)

Let LocalizationEngin process LidarScans and rely on current world map to estimate the new state (pose).

This function processes a set of LidarScans provided as vector of shared pointers of LidarScan, The engine returns these LidarScans with their per-column pose corrected.

Parameters:

scans[inout] – A vector of shared pointers to LidarScan objects to be processed.