Robotic Localization and Mapping
A simulated robot that estimates its position on a floor plan using a particle filter and noisy sensor data.

Overview
For a Harvard artificial intelligence course, a teammate and I built a simulated robot that had a floor plan but did not know its starting position. The goal was to estimate the robot’s location as it moved and sensed its surroundings, then explore how the same system might begin constructing a map when no floor plan was available.
Approach
Our Python simulator converts a floor-plan image into a binary occupancy grid of open space and obstacles. A user steers the simulated robot through the building while noisy odometry and laser-range readings supply observations. The simulation retains the robot’s true position for evaluation and displays the robot, map, and candidate position estimates together. I developed the floor-plan conversion, visualization, and robot agent, and co-developed the localization filter.
For Monte Carlo localization, we initialized particles across the known map to represent possible robot positions. After each move, the filter shifted those hypotheses using a motion model with odometry noise. It then compared the robot’s range readings with readings predicted from each candidate position, weighted the particles, and resampled them. As the robot gathered observations, the distribution narrowed toward its actual location.
Results
On floor plans of Harvard engineering buildings, the particles converged around the correct area after the robot moved through the environment. Larger maps needed many more particles and slowed the simulation; our resampling also sometimes concentrated particles too quickly. We began a simultaneous localization and mapping (SLAM) extension that updates an occupancy map from sensor readings, but did not complete the feedback step that would localize the robot using only its newly built map.