End-to-end neural network based optimal quadcopter control

Robin Ferede, Guido de Croon, Christophe De Wagter, Dario Izzo · DOI

TL;DR

This paper introduces an end-to-end neural network controller for quadcopters that directly maps sensor inputs to motor commands, bypassing traditional inner-loop controllers. They demonstrate that unmodeled moments significantly impact flight performance and propose an adaptive neural network that learns to compensate for these disturbances, leading to more robust and energy-efficient flights.

What Problem Does This Paper Address?

Developing optimal control strategies for quadcopters, especially for aggressive, high-speed maneuvers, is a significant challenge. Traditional approaches often rely on complex model-based controllers or neural networks trained for trajectory generation and tracking. A major hurdle is the "reality gap" – the discrepancy between simulated dynamics and real-world physics. This gap often necessitates the use of robust inner-loop controllers, which can limit the quadcopter's performance and the neural network's control authority. Furthermore, unmodeled dynamics, such as external moments, can severely degrade flight performance, leading to deviations from desired trajectories and even crashes. This paper aims to bridge this reality gap by developing an end-to-end neural network controller that directly learns optimal control policies and can adapt to unmodeled disturbances.

Methods

The core of the paper is the G&CNet (Guidance and Control Network), an end-to-end neural network that takes the quadcopter's state (position, velocity, attitude, angular velocities) as input and directly outputs the motor RPM commands. This approach bypasses the need for separate guidance and low-level control modules.

To address the reality gap, the authors propose an adaptive G&CNet. This adaptive version augments the input state with an estimate of external moments (roll, pitch, and yaw). The network is trained on optimal trajectories generated for a quadcopter model that includes these estimated external moments. During flight, the external moments are estimated onboard by comparing measured moments (derived from gyroscope data) with modeled moments. This estimated moment is then fed into the adaptive G&CNet, allowing it to dynamically adjust its control output to compensate for these unmodeled disturbances.

For training, they generate a large dataset of energy-optimal trajectories using a numerical optimization approach (Hermite-Simpson transcription with the SNOPT solver). The neural network architecture consists of three hidden layers with 120 neurons each, using ReLU activation, and a 4-neuron output layer with Sigmoid activation.

As a baseline for comparison, they also implement and test a Differential-Flatness-Based Controller (DFBC), a state-of-the-art method for aggressive trajectory tracking.

Datasets

The paper utilizes a synthetically generated dataset of 100,000 energy-optimal trajectories for training the nominal G&CNet. For the adaptive G&CNet, an additional 100,000 trajectories are generated, incorporating simulated external moments. These datasets are crucial for training the neural networks to learn optimal control policies. No new real-world benchmark datasets are introduced, but the experiments conducted on a Parrot Bebop drone serve as a practical evaluation.

Key Insights and Ideas

  • End-to-end control is viable for aggressive flight: The paper demonstrates that a direct mapping from state to motor commands via a neural network can achieve complex maneuvers, challenging the necessity of traditional inner-loop controllers.
  • Unmodeled moments are a critical reality gap contributor: The experiments clearly show that unmodeled moments, particularly pitch moments, significantly degrade flight performance, causing deviations and overshoots. This highlights a key area where model-based controllers struggle.
  • Adaptive neural networks can learn to compensate for unmodeled dynamics: The adaptive G&CNet successfully mitigates the negative effects of unmodeled moments by incorporating estimated disturbances into its control policy, leading to improved trajectory tracking and robustness.
  • Energy optimality is a key advantage: The adaptive G&CNet consistently outperforms the DFBC in terms of energy efficiency, even when the DFBC is optimized for energy. This suggests that the direct learning approach can find more efficient control strategies.
  • Flexibility in real-time path adjustment: Unlike trajectory-following methods, the G&CNet can dynamically adjust its path without needing a reference trajectory, making it more adaptable to unexpected situations.

Key Results

  • Successful hover-to-hover flights: The nominal G&CNet achieved hover-to-hover flights, but with noticeable deviations due to unmodeled moments.
  • Adaptive G&CNet significantly improves performance: The adaptive G&CNet demonstrated reduced trajectory deviations and overshoots in flight tests, particularly in forward translation maneuvers.
  • Energy efficiency: The adaptive G&CNet used less energy than the DFBC methods for completing the same flight tasks, even when the DFBC was tuned for energy optimality. For example, in a 4-lap flight, the adaptive G&CNet achieved a better energy-time trade-off.
  • Robustness to external disturbances: In a robustness experiment where an external moment was applied, the adaptive G&CNet maintained stable flight while the DFBC controller failed at higher speeds. The adaptive G&CNet also flew faster than all DFBC flights in this scenario.
  • Generalization to varying altitude: The adaptive G&CNet, trained with limited variation in the z-axis, successfully navigated a waypoint with a 1-meter altitude change, demonstrating some degree of generalization.

Limitations and Future Work

  • Lag in moment estimation: The filtering of gyroscope measurements for moment estimation introduces a slight delay, which can affect the performance of the adaptive controller.
  • Assumption of constant external moments: The adaptive method assumes constant external moments. Its effectiveness might be limited for highly dynamic or rapidly changing disturbances.
  • Remaining unmodeled effects: Despite the adaptive approach, flight tests still showed higher arrival times and energy consumption compared to simulations, indicating that other unmodeled effects (e.g., drag, actuator delays) might still be present.

Future work suggested includes:

  • Making current G&CNets time-optimal while retaining robustness.
  • Compensating for other unmodeled effects like thrust, drag, and actuator delays.
  • Using less strict final state constraints in the optimal control problem to improve maneuverability.
  • Training G&CNets with optimal trajectories that account for multiple consecutive waypoints to improve turning performance.

Summary updated

BibTeX
@article{ferede2024end,
  author = {Robin Ferede and Guido de Croon and Christophe De Wagter and Dario Izzo},
  title = {{End-to-end neural network based optimal quadcopter control}},
  journal = {Robotics Auton. Syst.},
  year = {2024},
  doi = {10.1016/j.robot.2023.104588},
}
Figure