Abstract
Trajectory optimization (TO) is one of the most powerful tools for generating feasible motions for humanoid robots. However, including uncertainties and stochasticity in the TO problem to generate robust motions can easily lead to intractable problems. Furthermore, since the models used in TO have always some level of abstraction, it can be hard to find a realistic set of uncertainties in the model space. In this paper we leverage a sample-efficient learning technique (Bayesian optimization) to robustify TO for humanoid locomotion. The main idea is to use data from full-body simulations to make the TO stage robust by tuning the cost weights. To this end, we split the TO problem into two phases. The first phase solves a convex optimization problem for generating center of mass (CoM) trajectories based on simplified linear dynamics. The second stage employs iterative Linear-Quadratic Gaussian (iLQG) as a whole-body controller to generate full body control inputs. Then we use Bayesian optimization to find the cost weights to use in the first stage that yields robust performance in the simulation/experiment, in the presence of different disturbance/uncertainties. The results show that the proposed approach is able to generate robust motions for different sets of disturbances and uncertainties.
Introduction
Humanoid robots present a significant control challenge due to their high degrees of freedom, underactuated nature, and complex contact dynamics. Generating stable walking patterns typically relies on Trajectory Optimization (TO), which often utilizes simplified models such as the Linear Inverted Pendulum Model (LIPM) to maintain computational feasibility. However, these simplifications create a "reality gap"—motions optimized for simplified mathematical models frequently fail when the robot encounters real-world disturbances or variations in surface friction.
Standard TO is often "brittle." To ensure real-time performance, engineers ignore constraints like joint torque limits or exact friction cones. Optimizing purely for performance can push the robot to its physical limits, such as placing the Center of Pressure (CoP) at the very edge of the foot. In such states, a minor external force or a slippery surface can lead to immediate failure. While robust or stochastic TO methods exist, they are often computationally prohibitive or overly conservative. This research proposes a hybrid approach: using Bayesian Optimization (BO) to automatically tune the cost weights of a TO-based controller, bridging the gap between simplified models and full-body dynamics.
Methodology
The proposed framework robustifies humanoid locomotion by nesting a sample-efficient learning loop around a two-stage control architecture.
Control Architecture
The control system is divided into two hierarchical stages:
- Convex Trajectory Optimization: A high-level optimizer generates Center of Mass (CoM) and Zero Moment Point (ZMP) trajectories. It optimizes a cost function that balances three primary objectives: tracking a desired reference velocity ($\alpha$), maximizing ZMP stability margins ($\beta$), and maximizing friction margins ($\gamma$).
- Whole-Body Control: An iterative Linear-Quadratic Gaussian (iLQG) controller serves as the low-level whole-body controller. It maps the high-level CoM/ZMP trajectories to specific joint torques for the full 27-degree-of-freedom humanoid model.
The Learning Loop: Bayesian Optimization
The core innovation is the use of Bayesian Optimization (BO) to tune the hyper-parameters ($\alpha, \beta, \gamma$) of the high-level TO stage. BO treats the entire full-body simulation as a black-box function. It evaluates the robot's performance—considering factors like fall prevention and velocity tracking—and iteratively adjusts the cost weights to find an optimal balance for robustness.
Because BO is highly sample-efficient, it can identify successful weight configurations in just a few dozen simulation trials, making it a viable alternative to more data-intensive reinforcement learning methods.
Experimental Setup
The method was evaluated using a high-fidelity simulation of a 27-degree-of-freedom humanoid robot (1.37m tall, 41kg). Performance was tested across three distinct scenarios designed to challenge the robot's stability:
- Nominal Walking: Walking on flat ground without external disturbances.
- External Pushes: The robot was subjected to lateral and sagittal pushes during its gait.
- Slippery Terrain: Walking on surfaces with a significantly reduced friction coefficient ($\mu = 0.15$).
Results and Discussion
The BO-tuned controller demonstrated superior robustness compared to baseline configurations. By adjusting cost weights, the system effectively created "buffers" against uncertainty.
Push Recovery and Friction Adaptation
In push recovery tests, a baseline controller with a zero weight on ZMP margins ($\beta=0$) failed to recover from a 60N lateral push. The BO process automatically increased the ZMP weight, which forced the high-level optimizer to plan trajectories that kept the ZMP closer to the center of the foot, providing the necessary stability to withstand the push.
Similarly, on slippery terrain, the robot initially slipped and fell. The BO loop responded by increasing the friction margin weight ($\gamma$). This resulted in the generation of more conservative trajectories—such as shorter steps—that reduced the required friction to stay upright.
As shown in the results, the BO-tuned parameters allow the robot to maintain stable locomotion even when the environment deviates significantly from the nominal model. However, this robustness comes with a trade-off: to ensure stability on slippery ground, the robot may not perfectly track the desired reference velocity, as seen in the tracking deviations in the more challenging scenarios.
Conclusion
This work demonstrates that Bayesian Optimization can effectively "robustify" trajectory optimization for humanoid robots by tuning cost weights based on full-body simulation data. This approach avoids the complexity of full stochastic optimization while overcoming the brittleness of simplified models. Future work will focus on "safe" exploration to prevent catastrophic falls during the learning phase on real hardware and exploring the simultaneous tuning of both high-level and low-level control parameters.
Summary updated