Key Moments
Stanford AA274A Principles of Robotic Autonomy | Autumn 2019 | Parametric Filtering
Key Moments
Parametric filters like Kalman filters approximate complex probability distributions with Gaussian ones, simplifying calculations but risking inaccuracy for non-linear systems.
Key Insights
The Bayesian filter, fundamental to probabilistic localization, iteratively refines state estimates by combining action (control) and measurement information in prediction and correction steps.
Parametric filters, such as Kalman filters, simplify the Bayesian filter by assuming a specific structure for the belief distribution, most commonly Gaussian.
The standard Kalman filter is exact for linear systems with Gaussian noise, where the state transition and measurement models are linear and the initial belief is Gaussian.
The Extended Kalman Filter (EKF) approximates non-linear systems by linearizing the state transition and measurement models around the current estimate, introducing potential inaccuracies.
The Unscented Kalman Filter (UKF) offers an alternative to EKF by approximating the Gaussian distribution with particles and passing them through the non-linear transformation, often yielding more robust results.
A key challenge in implementing Kalman filters is accurately estimating process noise (R) and measurement noise (Q), which often requires calibration and can act as tuning parameters.
The Bayesian filter framework for localization
The lecture begins by reiterating the problem of localization: determining a robot's position relative to a given map. The core approach discussed is Bayesian filtering, which iteratively estimates the robot's state (position) by fusing information from its actions (controls) and sensor measurements. The Bayesian filter operates in two key steps: prediction and correction. The prediction step uses the latest control input to forecast the robot's next state without incorporating the latest measurement. The correction step then refines this prediction by incorporating the latest sensor measurement. The intuition behind these steps is crucial: prediction accounts for all possible ways the robot could have reached its current state based on its prior belief and movement model, while correction aligns this belief with the actual observed measurement. This framework forms the foundation for more specific filtering techniques.
Challenges in implementing general Bayesian filters
While conceptually sound, the general Bayesian filter is computationally challenging to implement. The continuous nature of state spaces requires integrals, often in high dimensions, which are generally intractable. For instance, representing the belief state as a continuous probability density function and integrating over all possible states is computationally prohibitive. This complexity necessitates approximations. The lecture introduces two main families of approaches to make the Bayesian filter tractable: parametric filters and non-parametric filters. Parametric filters, the focus of this lecture, impose a specific structure on the belief distribution, such as assuming it's Gaussian. Non-parametric filters, on the other hand, approximate the distribution using methods like Monte Carlo sampling without assuming a specific functional form.
Parametric filtering with Gaussian distributions
Parametric filters, particularly those assuming a Gaussian distribution for the belief state, simplify computations significantly. A Gaussian distribution in one dimension is defined by its mean (μ) and variance (σ²), and in multiple dimensions by a mean vector and a covariance matrix. Assuming a Gaussian belief means the robot's state estimate is characterized by a single most likely position (the mean), and a measure of uncertainty around that position (the variance/covariance). This is a strong assumption because real-world scenarios can often lead to multi-modal beliefs (multiple plausible locations), which a single Gaussian cannot accurately represent. However, Gaussian distributions offer computational advantages: linear transformations of Gaussian variables result in Gaussian variables, and their parameters (mean and covariance) are easily updated. This property is fundamental to the Kalman filter.
The Kalman Filter for linear systems
The Kalman filter is an exact solution for state estimation when the system dynamics (state transition model) and measurement model are linear, and the process and measurement noise are Gaussian with zero mean. In this ideal scenario, if the initial belief is Gaussian, all subsequent belief distributions will also be Gaussian. The Kalman filter iteratively updates the mean and covariance of this Gaussian belief. The prediction step uses the linear state transition model (X_t = A*X_{t-1} + B*u_t + ε_t) to project the current mean and covariance forward. The correction step then incorporates the linear measurement model (z_t = C*x_t + δ_t) using the Kalman gain. This gain optimally balances the confidence in the prediction (based on system model uncertainty) versus the confidence in the measurement (based on sensor noise). The Kalman gain determines how much the measurement influences the updated belief. The filter is considered optimal in the sense of minimizing the mean squared error of the state estimate.
The Extended Kalman Filter (EKF) for non-linear systems
In robotics, system dynamics and sensor models are frequently non-linear. The Extended Kalman Filter (EKF) addresses this by approximating the non-linear models with linear ones. It does this by linearizing the non-linear state transition and measurement functions around the current state estimate (mean). This linearization is achieved using Taylor series expansion, typically up to the first order, resulting in Jacobian matrices that represent the local linear behavior of the system. The EKF then applies the standard Kalman filter equations using these linearized models and their Jacobians. While the EKF allows the Kalman filter framework to be applied to non-linear systems, it introduces approximation errors. The quality of the linearization, and thus the filter's performance, depends heavily on how well the local linear approximation matches the true non-linear function, especially when the uncertainty (variance) is large or the non-linearity is severe.
Challenges and failures of the EKF
The EKF's performance can degrade significantly when the system is highly non-linear or the state uncertainty is large. If the linearized approximation is poor, the filter can produce inaccurate estimates. The lecture highlights two main failure modes: when the probability distribution is too wide, making the local linearization a poor global approximation, or when the non-linearity itself is so strong that even a local approximation is insufficient. Practical issues also arise from determining the process noise (R) and measurement noise (Q) covariances. These are often estimated through calibration and can act as tuning parameters, which can be frustratingly difficult to set correctly. The EKF's tendency to sometimes fail unexpectedly and the difficulty in debugging it are common frustrations in robotics.
The Unscented Kalman Filter (UKF) as a more robust alternative
The Unscented Kalman Filter (UKF) offers an alternative to the EKF for non-linear systems, often providing more robust performance. Instead of linearizing the non-linear functions, the UKF uses a deterministic sampling approach called the unscented transform. It selects a set of carefully chosen points (sigma points) that capture the mean and covariance of the current Gaussian belief. These sigma points are then passed through the true non-linear transformation. A new Gaussian distribution is then fitted to the transformed points. This method can better represent the propagation of uncertainty through non-linearities compared to the EKF's linearization, especially when dealing with wide distributions or strong non-linearities. While generally more complex to implement, the UKF is often preferred for its improved accuracy and robustness in challenging non-linear scenarios.
Implications and future directions
The lecture concludes by emphasizing that both EKF and UKF are approximations for non-linear systems. The choice between them, or even other advanced filtering techniques, depends on the specific application's requirements for accuracy, computational cost, and robustness. The fundamental challenge remains accurately modeling the robot's dynamics and sensor behavior, and effectively managing uncertainty. The discussion sets the stage for applying these filtering concepts to specific robotics problems like localization and simultaneous localization and mapping (SLAM) in subsequent lectures, highlighting the ongoing importance of probabilistic methods in achieving robotic autonomy.
Mentioned in This Episode
●Products
●Software & Apps
●Books
●Concepts
●People Referenced
Common Questions
Bayesian filtering is a probabilistic approach to estimate a system's state (like position) over time by integrating information from control actions and sensor measurements. It's crucial in robotics for tasks like localization, where determining the robot's position relative to a map is essential for navigation and operation.
Topics
Mentioned in this video
A probabilistic approach to state estimation that involves repeatedly estimating the state by integrating information from actions and sensor measurements.
A probability distribution characterized by its bell shape, defined by a mean (mu) and variance (sigma^2). It assigns non-zero probability to all real values.
A general framework for state estimation consisting of two main steps: prediction and correction. It iteratively estimates the state by combining control inputs and measurement data.
An alternative to the Extended Kalman Filter for non-linear systems that approximates the Gaussian distribution using carefully chosen particles (sigma points) and propagates them through the non-linear transformations, often proving more robust.
A widely influential filter, introduced in the 1950s, for estimating the state of a system from a series of measurements that are imperfect or noisy. It relies on linear system dynamics and Gaussian noise.
An extension of the Kalman filter that handles non-linear system dynamics or measurement models by linearizing the system around the current estimate, typically using Taylor series expansion.
More from Stanford Online
View all 157 summaries
104 minStanford CME295 Transformers & LLMs | Autumn 2026 | Lecture 4 - Reinforcement Learning with LLMs
78 minStanford AA274A Principles of Robotic Autonomy | Autumn 2019 | Localization & Filters
80 minStanford AA274A Principles of Robotic Autonomy | Autumn 2019 | Classic Visual Recognition
61 minStanford EE292R AI and Data for Science | Autumn 2026 | Models of Computation in the Retina
Ask anything from this episode.
Save it, chat with it, and connect it to Claude or ChatGPT. Get cited answers from the actual content — and build your own knowledge base of every podcast and video you care about.
Get Started Free