Localisation & SLAM
Odometry drifts, so a rover has to work out where it is from what it sees. Build the estimators robots actually use: a histogram filter, an EKF with beacons, a particle filter that finds the rover from scratch, ICP scan matching and pose-graph SLAM.
Start the lesson0/6 steps done
What you'll learn
- Model odometry noise and watch uncertainty grow
- Localise with a histogram filter and with an EKF
- Find a lost robot with a particle filter
- Match lidar scans with ICP
- Close a loop with pose-graph SLAM
Before you start
You should be comfortable with basic Python: variables, loops and functions. We'll introduce the robotics and the maths as you go. The first visit downloads the physics engine and Python, about 20 MB, and later visits load from your browser's cache.
Steps
- 1Why odometry isn't enoughModel the wheels' noise, sample it 200 times, and watch the rover's possible poses spread into a banana as it drives.Dead reckoningMotion modelSamplingOpen
- 2Localising in a corridorSplit a corridor into cells and keep a probability for each: predict with every move, correct with every reading, until one cell wins.BeliefLikelihoodBayes filterPro
- 3An EKF with beaconsTrack the rover with one Gaussian: predict with the wheels, correct with each beacon it sees, and watch the uncertainty ellipse breathe.Extended Kalman filterJacobiansInnovationPro
- 4Finding a lost rover with particlesScatter guesses over the whole maze, move them like the wheels, weigh them against the lidar and resample: the cloud collapses onto the rover.Monte Carlo localisationLikelihood fieldResamplingPro
- 5Scan matching with ICPLay each lidar scan over the one before to measure how the rover really moved, and build a far better odometry than the wheels'.ICPKabsch / SVDScan-matching odometryPro
- 6Closing the loopTurn every scan match into an edge of a graph, add one edge that closes the loop, and solve for all the poses at once: the lap closes and the map lines up.Pose graphLoop closureGauss–NewtonPro