Open Source Robotics

A curated collection of high-quality open source robotics projects, tools, and software to propel the robotics community forward.

Particle Filter

  • Also called: sequential Monte Carlo, SMC, bootstrap filter
  • Category: State estimation & navigation › Localisation
  • Tags: state-estimation, localization, bayesian-filtering, probabilistic-robotics, monte-carlo

A state estimation method that represents a belief as a set of weighted samples, moving them with a motion model, weighting them by sensor likelihood and resampling.

Definition

A particle filter is a recursive Bayesian estimator that represents the probability distribution over a system's state with a set of samples, called particles, each carrying a weight. The approach is also known as sequential Monte Carlo; its widely cited form, the bootstrap filter, was published by Gordon, Salmond and Smith in 1993. In robotics it became standard through Monte Carlo localization, developed by Dellaert, Fox, Burgard and Thrun, and is covered in depth in Probabilistic Robotics.

Each update has three steps. In the prediction step, every particle is moved according to the motion model, with noise added to reflect uncertainty in odometry or control. In the update step, each particle is weighted by how well the latest sensor measurement agrees with the state it represents. In the resampling step, a new set of particles is drawn in proportion to the weights, so likely hypotheses are duplicated and unlikely ones disappear. The estimate can be read from the weighted mean, the best particle or a cluster of particles.

Unlike the Kalman filter and its extensions, a particle filter does not assume the belief is Gaussian. It can hold several separate hypotheses at once, such as a robot that could be in one of two identical corridors, or an object held in a hand that could be in several poses consistent with the contacts felt so far. The cost is computational: the number of particles needed grows quickly with the dimension of the state, and if too few particles land near the true state the filter can collapse onto a wrong answer. Practical filters therefore use low-variance resampling, resample only when the effective sample size drops, adapt the particle count, and inject random particles to recover from failures.

Why it matters

Many robot estimation problems are nonlinear and ambiguous, with beliefs that have several peaks rather than one. The particle filter handles these directly, which is why it is the basis of standard 2D localization on mobile robots and a common tool for estimating object pose from contact and touch.

Key applications

  • Mobile robot localization against a known map (Monte Carlo localization)
  • Estimating in-hand object pose from proprioception and tactile contact
  • Tracking people and objects in cluttered or occluded scenes
  • SLAM with Rao–Blackwellized particle filters such as FastSLAM and GMapping
  • Global localization and recovery when a robot is moved without its knowledge

In practice

A warehouse robot running the ROS navigation stack typically localizes with AMCL, an adaptive Monte Carlo localization package. At start-up, the operator gives a rough initial pose, and a few thousand particles are spread around it. As the robot drives, wheel odometry moves the particles and each lidar scan reweights them against the stored occupancy map; the cloud tightens around the true pose within a few metres of travel. Engineers tune the odometry noise parameters to match the real drive train, set minimum and maximum particle counts, and watch the particle cloud in RViz: a cloud that splits into two clusters in a repetitive aisle is a sign the filter is tracking two hypotheses and needs a distinctive feature to resolve them.

Common misconceptions

  • More particles always solve accuracy problems — particle needs grow rapidly with state dimension, so high-dimensional problems need better proposals or structure, not only more samples
  • A particle filter is just a slower Kalman filter — it represents non-Gaussian, multi-peaked beliefs that Kalman-type filters cannot
  • Resampling at every step is always best — resampling too often discards diversity; many filters resample only when the effective sample size falls below a threshold
  • The filter will always recover from a wrong estimate — once particles have collapsed away from the true state they cannot return unless random particles are injected

Who should know this

  • Mobile robot localization and navigation engineers
  • State estimation and SLAM developers
  • Manipulation researchers estimating object pose from touch
  • Robotics students studying probabilistic robotics

Related technologies

  • Monte Carlo Localization (AMCL)
  • Kalman Filter
  • FastSLAM
  • Importance Sampling
  • Occupancy Grid Map

Related terms

  • Extended Kalman Filter
  • SLAM
  • Odometry
  • Sensor Fusion
  • LIDAR
  • Partially Observable Markov Decision Process (POMDP)

Related projects

  • Cartographer: Google's real-time 2D and 3D SLAM system for multi-platform robotics
  • Nav2: ROS 2 navigation stack with path planning and obstacle avoidance for mobile robots
  • GTSAM: Factor-graph optimization library powering many modern SLAM backends
  • OpenVINS: The reference open platform for visual-inertial state estimation research
  • AprilTag: The standard visual fiducial marker system for robot localization and pose estimation
  • GLIM: GPU-accelerated 3D lidar SLAM framework for any range sensor, from AIST

Videos

  • Understanding the Particle Filter | | Autonomous Navigation, Part 2: MATLAB
  • Particle Filter - 5 Minutes with Cyrill: Cyrill Stachniss

Wikipedia

  • Particle filter

This website requires JavaScript to function properly. Please enable JavaScript to explore our collection of open source robotics projects.