Source-linked AI summary

KNODE-MPC: A Knowledge-based Data-driven Predictive Control Framework for Aerial Robots

Kong Yao Chee, Tom Z. Jiahao, M. Ani Hsieh

arXiv:2109.04821v3cs.ROcs.LGcs.SYeess.SY

TL;DR

MPC needs accurate dynamic models, but uncertainty in complex systems and environments makes them difficult to obtain. This paper augments a first-principles quadrotor model with a neural network and integrates the hybrid KNODE model into MPC. KNODE-MPC improves median trajectory-tracking errors in simulations and outperforms nominal MPC in physical generalization tests.

  • Problem

    Accurate dynamic models are important to MPC, but uncertainty in complex systems and environments makes them difficult to obtain.

    Source: §I · p. 1
  • Method

    The paper augments a first-principles quadrotor model with a neural network for residual and uncertain dynamics, then integrates the KNODE model into MPC.

    Source: §I · p. 1, B. Knowledge-based Neural ODEs · p. 3
  • Results

    60.2% and 67.8% median trajectory-tracking error improvements for KNODE-MPC versus nominal MPC and GP-MPC, respectively, in simulations; it also outperforms nominal MPC by 21.0% overall across three physical generalization cases.

    Source: B. Simulation Results · p. 6, C. Physical Experimental Results · p. 7
  • Takeaways & Limitations

    The hybrid model provides a more accurate representation of quadrotor dynamics than a state-of-the-art GP model and generalizes beyond its training trajectories.

    Source: §V · p. 7, C. Physical Experimental Results · p. 7

Abstract

from arXiv · show

In this work, we consider the problem of deriving and incorporating accurate dynamic models for model predictive control (MPC) with an application to quadrotor control. MPC relies on precise dynamic models to achieve the desired closed-loop performance. However, the presence of uncertainties in complex systems and the environments they operate in poses a challenge in obtaining sufficiently accurate representations of the system dynamics. In this work, we make use of a deep learning tool, knowledge-based neural ordinary differential equations (KNODE), to augment a model obtained from first principles. The resulting hybrid model encompasses both a nominal first-principle model and a neural network learnt from simulated or real-world experimental data. Using a quadrotor, we benchmark our hybrid model against a state-of-the-art Gaussian Process (GP) model and show that the hybrid model provides more accurate predictions of the quadrotor dynamics and is able to generalize beyond the training data. To improve closed-loop performance, the hybrid model is integrated into a novel MPC framework, known as KNODE-MPC. Results show that the integrated framework achieves 60.2% improvement in simulations and more than 21% in physical experiments, in terms of trajectory tracking performance.

I. INTRODUCTION

Accurate dynamic models are central to MPC, but building first-principles models becomes difficult for complex systems and environments. The paper applies KNODE to quadrotor dynamics and incorporates the resulting hybrid model into MPC to improve predictions and closed-loop performance.

I. INTRODUCTION

  • MPC depends on accurate dynamic models, yet constructing first-principles models can be daunting when systems or operating environments are complex.The task often requires domain expertise and deep physical insight.Source: §I · p. 1
  • KNODE combines first-principles models with neural networks, but its ability to improve real-world robotic closed-loop performance had been unclear.KNODE had been used to improve open-loop prediction accuracy for nonlinear dynamics.Source: §I · p. 1
  • The paper models quadrotor residual and uncertain dynamics with KNODE, integrates it into MPC, and reports improved future-state predictions and closed-loop performance in simulation and real-world experiments.The integrated controller is called KNODE-MPC.Source: §I · p. 1

II. RELATED WORK

The related work discusses data-driven dynamic models and their integration into MPC, then presents the quadrotor system used to illustrate the proposed framework. The paper combines prior system knowledge with a neural ODE and evaluates the resulting model and controller against existing approaches.

II. RELATED WORK

  • Sparse regression can fail when its library lacks the correct basis functions and scales poorly to high-dimensional systems.These limitations make real-world deployment challenging.Source: §II · pp. 1–2
  • Neural networks parameterize dynamic models, while NODE explicitly models differential equations from data and KNODE pairs this approach with first-principles models.KNODE has modeled nonlinear and chaotic systems.Source: §II · p. 2
  • GP regression can require restrictive assumptions and a small training set, while the cited MBRL approaches do not account for prior system-dynamics knowledge.The text identifies computational complexity as a reason GP methods select only a small number of training points.Source: §II · p. 2
  • KNODE combines prior system knowledge with a neural ODE, improves quadrotor state-prediction accuracy over nominal and GP-based models, and is integrated into MPC for closed-loop evaluation.The GP comparison includes a more general variant that does not impose structural assumptions between system uncertainties and true dynamics.Source: §II · p. 2

A. Quadrotor Dynamics

  • The framework is illustrated with a six-degree-of-freedom quadrotor model whose dynamics use mass, moments of inertia, and motor-generated thrust and moments.The model relates the motor forces to the moment vector through the arm length and motor moment-to-thrust coefficient ratio.Source: A. Quadrotor Dynamics · p. 2

B. Knowledge-based Neural ODEs

The KNODE model augments nominal quadrotor dynamics with a neural network that represents uncertainties and residual dynamics. Its parametric form accommodates coupled state and input effects and can be trained on large datasets while keeping the uncertainty model size constant.

B. Knowledge-based Neural ODEs

  • The nominal quadrotor model omits aerodynamic and environmental disturbances, and system parameters such as moments of inertia are difficult to estimate.These uncertainties create deviations between nominal and true dynamics.Source: B. Knowledge-based Neural ODEs · p. 3
  • KNODE parameterizes uncertainty with a neural network and combines it with the nominal model to represent dynamics absent from that model.The framework can couple different state and input components and accommodate uncertain forces and moments.Source: B. Knowledge-based Neural ODEs · p. 3
  • Unlike non-parametric GP regression, the parametric KNODE approach supports large training datasets with constant uncertainty-model size and may enable faster inference.Source: B. Knowledge-based Neural ODEs · p. 3

C. Model Predictive Control

MPC optimizes control inputs over a receding horizon using a system model, constraints, and weighted costs. Because closed-loop performance is sensitive to model accuracy, the section motivates integrating the KNODE hybrid model.

C. Model Predictive Control

  • At each time step, MPC solves an optimization over a sequence of control inputs and applies the first input.The formulation includes system dynamics, state and input constraints, and stage, input, and terminal costs.Source: C. Model Predictive Control · p. 3
  • State and input constraints are represented by the sets X and U, while Q, R, and P weight the stage, input, and terminal costs.The optimization also starts from the current state x(k).Source: C. Model Predictive Control · p. 3
  • Because closed-loop performance is sensitive to model accuracy, the section motivates integrating a hybrid knowledge-based NODE model into MPC.Robust and stochastic MPC approaches require additional assumptions about uncertainty, which can be difficult to ascertain in practice.Source: C. Model Predictive Control · p. 3

D. KNODE Training

The training approach assumes uncertainty can be separated from nominal dynamics and represents it with a neural-network residual. It trains the hybrid model on trajectory data by minimizing one-step prediction error.

D. KNODE Training

  • The hybrid dynamics add a neural-network residual Δθ(x, u) to the nominal model f(x, u).This formulation assumes the uncertainty is separable from the nominal dynamics.Source: D. KNODE Training · p. 3
  • Training uses closed-loop trajectory observations of states and control inputs to make one-step-ahead predictions from each observed state.The observations are paired as (x(t_i), u(t_i)), and the control inputs are injected into the model for prediction.Source: D. KNODE Training · p. 3
  • The one-step state prediction is integrated numerically with an explicit fourth-order Runge-Kutta method.The predictions are compared with ground truth using mean squared error.Source: D. KNODE Training · pp. 3–4
  • The optimization minimizes the training loss, with adjoint sensitivity propagating gradients to network parameters that are iteratively updated using optimizers such as Adam.The adjoint sensitivity method is described as a memory-efficient alternative to conventional backpropagation.Source: D. KNODE Training · p. 4

E. Evaluation and Verification

The evaluation tests state-prediction accuracy, generalization beyond training data, and closed-loop trajectory tracking against nominal and GP-based approaches. The GP benchmark is generalized to remove structural assumptions used in an earlier formulation.

E. Evaluation and Verification

  • The evaluation asks whether KNODE improves state prediction and generalizes beyond training data, and how KNODE-MPC tracking compares with nominal MPC and GP-MPC.These are the stated questions guiding the evaluation.Source: E. Evaluation and Verification · p. 4
  • The GP benchmark removes assumptions that uncertainty-to-dynamics relationships are known, uncertainties are decoupled, and each axis uses only scalar mappings from body velocity to acceleration disturbance.The earlier assumptions are described as often difficult to ascertain in practice.Source: E. Evaluation and Verification · p. 4
  • State-prediction accuracy is evaluated by comparing nominal, KNODE, and GP models under nonlinear components in the true dynamics, using trajectory similarity measured by dynamic time warping.Closed-loop trajectories from KNODE-MPC, nominal MPC, and GP-MPC are compared with the planned trajectory in simulations and physical experiments using the same distance metric.Source: E. Evaluation and Verification · p. 4

A. Setup

The setup evaluates prediction and tracking in simulations with modeled aerodynamic uncertainty and in Crazyflie experiments using motion capture. Training and test trajectories vary by setting, including tests beyond the training conditions.

A. Setup

  • Simulated true dynamics include nonlinear aerodynamic drag absent from the nominal model, and the modeled uncertainty affects translation rather than rotation.The passage identifies uncertain rotational dynamics as future work.Source: A. Setup · p. 4
  • The physical setup routes KNODE-MPC commands through the Crazyflie ROS server to the onboard commander module.The experimental platform operates with a Vicon motion capture system.Source: Figure 2 · p. 5
  • For generalization, models were tested on trajectories beyond training data, including circular and lemniscate paths of different radii and speeds; closed-loop KNODE-MPC was compared with nominal MPC and GP-MPC.Source: A. Setup · p. 5
  • Physical experiments use a 32 g Crazyflie 2.1 with Vicon pose tracking; the base station communicates with the vehicle at an average rate of 500 Hz.Vicon publishes at approximately 98 Hz, and linear velocities are estimated from tracked positions.Source: A. Setup · p. 5
  • Physical training data come from nominal-MPC flights on 0.5 m and 1 m circles at 0.5 m/s, while closed-loop tests use three circular radii and a different speed for velocity generalization.Each training trajectory lasts approximately 76 seconds and contains 39,990 data points; linear velocity data are low-pass filtered before training.Source: A. Setup · p. 5

B. Simulation Results

In simulations, KNODE-based models improve quadrotor state predictions over nominal and GP models, while KNODE-MPC improves closed-loop tracking over nominal MPC and GP-MPC. Results also examine generalization and training-data sample efficiency.

B. Simulation Results

  • KNODE improves overall median prediction error by 19.1% over GP and by more than 80% over the nominal model.On lemniscate trajectories, KNODE's median prediction error is 45.5% lower than GP's; these trajectories differ geometrically from its circular training data.Source: B. Simulation Results · p. 5, Figure 3 · p. 6
  • KNODE-MPC reduces median tracking errors by 60.2% versus nominal MPC and 67.8% versus GP-MPC across simulated test cases.The tests include circular and lemniscate trajectories; the reported comparison is shown in Fig. 4.Source: B. Simulation Results · p. 6, Figure 4 · p. 6
  • KNODE-MPC tracks the planned trajectory more closely than nominal MPC, whose position errors accumulate over time when residual dynamics are unmodeled.The qualitative comparison is illustrated in Fig. 5.Source: B. Simulation Results · p. 6
  • As the training-data fraction approaches 1, tracking errors decrease for both tested radii, while training time scales linearly with training data.The sample-efficiency experiment evaluates closed-loop tracking on circular trajectories with radii of 3 m and 4 m.Source: B. Simulation Results · p. 6

C. Physical Experimental Results

Physical experiments test KNODE-MPC against nominal MPC and GP-MPC on a training trajectory and on trajectories beyond the training data. KNODE-MPC improves tracking errors in both settings.

C. Physical Experimental Results

  • The physical comparison tests nominal MPC, KNODE-MPC, and GP-MPC on a 0.5 m-radius circle at 0.5 m/s, a training trajectory.The experiment comprises 15 runs per framework, 45 runs total.Source: C. Physical Experimental Results · p. 6
  • Figure 5 presents 3D trajectories produced by nominal MPC, GP-MPC, and KNODE-MPC on a circular-trajectory segment with a radius of 6 m and a speed of 1 m/s.Source: Figure 5 · p. 6
  • On the training trajectory, KNODE-MPC improves median tracking error by 34.1% over nominal MPC and 12.4% over GP-MPC.Fig. 6 reports results across 15 runs per framework on a 0.5 m-radius circular trajectory.Source: C. Physical Experimental Results · p. 7, Figure 6 · p. 7
  • On trajectories beyond training, KNODE-MPC improves combined median tracking error by 21.0% over nominal MPC and 14.6% over GP-MPC.The combined median is computed over 135 runs across three scenarios; KNODE-MPC outperforms nominal MPC in each scenario.Source: C. Physical Experimental Results · p. 7

V. CONCLUSION AND FUTURE WORK

KNODE provides a more accurate quadrotor dynamics representation than a state-of-the-art GP model, and KNODE-MPC yields better closed-loop performance. The framework was tested in simulations and physical experiments, with online learning proposed as future work.

V. CONCLUSION AND FUTURE WORK

  • Fig. 7 reports generalization statistics for three frameworks across three scenarios, with 15 runs per framework and scenario and individual DTW errors shown as circles.Bars show medians and error bars show the 25th and 75th percentiles.Source: Figure 7 · p. 7
  • KNODE represents quadrotor dynamics more accurately than a state-of-the-art GP model, and KNODE-MPC yields better closed-loop performance.The framework was tested in simulations and physical experiments.Source: §V · p. 7
  • The authors propose extending KNODE-MPC to online learning, updating and refining KNODE in real time to further improve closed-loop control performance.They also identify marine robots and robotic teams as possible application areas.Source: §V · p. 7
Loading 2109.04821v3…