Format Description - Occupancy Grid Map #
An occupancy grid map is a type of map in which each cell is marked with a number that indicates the likelihood of the cell containing an object. The number is often 0 (free space) to 100 (100% likely occupied). Unscanned areas (i.e. by the LIDAR, ultrasonic sensor, or some other object detection sensor) would be marked as -1.
Maps supported by Meili Robots are described in a pair of files. The YAML file describes the map meta-data and names the image file. The image file encodes the occupancy data.
Image Format #
The image describes the occupancy state of each cell of the world in the colour of the corresponding pixel. In the standard configuration, white pixels are free, black pixels are occupied, and pixels in between are unknown. Colour images are accepted, but the colour values are averaged to a grey value.
YAML format #
The YAML format is best explained with a simple, complete example:
Required fields: #
- Image –> Path to the image file containing the occupancy data; can be absolute, or relative to the location of the YAML file
- Resolution –> Resolution of the map, metres / pixel
- Origin –> The 2-D pose of the lower-left pixel in the map, as (x, y, yaw), with yaw as counterclockwise rotation (yaw=0 means no rotation). Many parts of the system currently ignore yaw.
- Occupied_thresh –> Pixels with occupancy probability greater than this threshold are considered completely occupied.
- Free_thresh –> Pixels with occupancy probability less than this threshold are considered completely free.
- Negate –> Whether the white/black free/occupied semantics should be reversed (interpretation of thresholds is unaffected)
Optional parameter: #
- Mode –> Can have one of three values: trinary, scale, or raw. Trinary is the default. More information on how this changes the value interpretation can be found in the next section.
Sample Data #
You can download an example of a map that can be uploaded into Meili FMS: