simul-beacons

Generates a synthetic dataset of a robot moving along a predefined path (a circle or a square) in a 2D world with randomly placed beacons, measuring the range to each beacon (range-only sensing, e.g. radio or UWB beacons). Use it to test range-only SLAM and localization methods, such as those in rbpf-slam and ro-localization, with known ground truth.

Usage

simul-beacons <config_file.ini>
  • config_file.ini : the simulation parameters (see below).

  • --help, --version.

Each run uses a different random seed, so the beacon positions and noise change between runs.

Example

Using the sample config file in mrpt_data :

simul-beacons config_files/simul-beacons/example_simul-beacons.ini

This creates the directory OUT with:

  • simBeaconPath.rawlog : the simulated dataset.

  • outSimMap.txt : the ground truth beacon map: one row per beacon, with its ID, X Y Z coordinates and (all zero) covariance terms.

Configuration file

All parameters are read from the [Params] section:

Key

Default

Description

outDir

OUT

Output directory (created if it does not exist).

outFile

out.rawlog

Output rawlog file name, inside outDir.

nBeacons

3

Number of beacons.

min_x, max_x, min_y, max_y

-5, 5, -5, 5

Area (m) where beacons are placed, uniformly at random.

min_z, max_z

0, 0

The z coordinate (m) of the beacons is drawn uniformly in [min_z, max_z].

nSteps

100

Number of time steps to simulate.

circularPath

true

Path type: true for a circle (0.2 m and 5 deg per step), false for a square.

squarePathLength

40

Steps per side of the square path (0.2 m per step); the last 4 steps of each side make a 90 deg turn in place.

odometryNoiseXY_std

0.001

Odometry noise (m, 1 sigma) in x and y per step.

odometryBias_Y

0

Constant bias (m) added to the y odometry increment per step.

minSensorDistance, maxSensorDistance

0, 10

Range (m) within which beacons are detected.

stdError

0.04

Range noise (m, 1 sigma).

ratio_outliers

0

Probability of a range being an outlier.

ratio_outliers_first_step

0

Same, for the first time step only.

outlier_uniform_min, outlier_uniform_max

0, 5

Outliers are generated by adding a uniform random error (m) in this interval.

The robot stays still during the first 4 steps.

Output format

The rawlog is in the “actions-sensory frames” format (see the rawlog format). Each step has:

See also