Files
PythonRobotics/docs/modules/3_mapping/distance_map/distance_map_main.rst
Atsushi Sakai 5392fcff4d Refactor module links and improve code documentation. (#1211)
* Refactor module links and improve code documentation.

Updated documentation to rename "API" sections to "Code Link" for clarity and consistency. Enhanced docstrings for `circle_fitting` and `kmeans_clustering` functions, improving parameter descriptions and adding return value details. Fixed typos in function and file names in the ray casting grid map module.

* Fix import typo in ray casting grid map test module.

Corrected the import statement in the test file by updating the module's name to `ray_casting_grid_map` for consistency with the source file. This ensures proper functionality of the test suite.
2025-05-03 09:25:12 +09:00

27 lines
908 B
ReStructuredText

Distance Map
------------
This is an implementation of the Distance Map algorithm for path planning.
The Distance Map algorithm computes the unsigned distance field (UDF) and signed distance field (SDF) from a boolean field representing obstacles.
The UDF gives the distance from each point to the nearest obstacle. The SDF gives positive distances for points outside obstacles and negative distances for points inside obstacles.
Example
~~~~~~~
The algorithm is demonstrated on a simple 2D grid with obstacles:
.. image:: distance_map.png
Code Link
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.. autofunction:: Mapping.DistanceMap.distance_map.compute_sdf
.. autofunction:: Mapping.DistanceMap.distance_map.compute_udf
References
~~~~~~~~~~
- `Distance Transforms of Sampled Functions <https://cs.brown.edu/people/pfelzens/papers/dt-final.pdf>`_ paper by Pedro F. Felzenszwalb and Daniel P. Huttenlocher.