MPPI for F1Tenth
April 2025
Report | Code
F1Tenth platform avoiding obstacles (black boxes) in simulation using MPPI. Race line is red dotted, sampled trajectories are blue dashed, and computed trajectory is red dashed.For CMU 16-663 F1Tenth Autonomous Racing, our group’s final project was to apply Model Predictive Path Integral Control (MPPI) on the F1Tenth platform (with teammates Brian Park and Aman Goel). The goal of the project was to explore MPPI as a control method in comparison to Rapidly Exploring Random Trees (RRT) as MPPI can leverage GPU acceleration for faster computation.
MPPI is a form of model predictive control which solves an optimization problem, takes the first action and repeats every time step. Our implementation consists of three steps: trajectory generation, trajectory evaluation, and trajectory weighting. For trajectory generation, zero-mean gaussian noise added to the current control input sequence, the inputs are clamped, and the trajectories are rolled out using the kinematic bicycle model. Each step in the trajectories are measured using a cost function which adds a quadratic cost to position, orientation, and velocity, and a high penalty for collision with obstacles. Finally, each trajectory is weighted using the optimal information theoretic control law based and a weighted average is performed to update the control input sequence.
Testing in simulation and on the platform, MPPI achieved a faster lap time than RRT with and without obstacles. Qualitatively, MPPI had a smoother performance than RRT due to the weighted average and moving average.