AMCL finds where a robot is on a map that already exists. It is a particle filter: it keeps many guesses of the robot pose, moves them as the robot moves, and keeps the guesses whose predicted laser scan matches the real scan. The map usually comes from Simultaneous Localisation and Mapping (SLAM).
Particles
- each particle is one guess of the pose on the map, with a weight
- together they represent the belief, which can have one peak or several, unlike a Kalman filter's single Gaussian
One Cycle
Steps:
- motion update: move every particle by the odometry change, plus random noise, so the cloud spreads to cover odometry error
- measurement update: for each particle, compare the laser scan expected from that pose with the real scan, and set the weight by how well they match
- resample: draw a new set of particles, with good particles copied more often and poor ones dropped
- the pose estimate is the weighted mean of the main cluster
Laser Model
- the likelihood field model precomputes, for every map cell, the distance to the nearest obstacle
- a beam ending close to an obstacle in the map scores high, one ending in free space scores low
- only a subset of beams is used (for example 60) to save computation
What Adaptive Means
- the number of particles changes with uncertainty (KLD sampling), for example between 500 and 2000
- many particles when the robot is unsure, few when the cloud has converged
Recovery From A Wrong Pose
- if the scan fit suddenly drops, the filter injects random particles across the map
- the parameters
recovery_alpha_slowandrecovery_alpha_fastcompare long-term and short-term fit to decide when - this helps with the kidnapped robot problem, where the robot is moved without the filter knowing
Key Parameters
alpha1toalpha4: how much rotation and translation noise to add in the motion updateupdate_min_dandupdate_min_a: only update after a set distance or angle of motion, which saves computation when the robot is still- the initial pose, set in the config or from a visualiser
Place In The TF Tree
- AMCL publishes
maptoodom - odometry (often an EKF) publishes
odomtobase_link odomis smooth but drifts,mapjumps slightly when AMCL corrects it but does not drift