Skip to content

Isaac Drone Racer is a reinforcement learning framework for high speed autonomous drone racing, built on top of IsaacLab

License

Notifications You must be signed in to change notification settings

kousheekc/isaac_drone_racer

Repository files navigation

Isaac Drone Racer


Isaac Drone Racer

IsaacSim Python pre-commit License

Isaac Drone Racer is an open-source simulation framework for autonomous drone racing, developed on top of IsaacLab. It is designed for training reinforcement learning policies in realistic racing environments, with a focus on accurate physics and modular design.

Autonomous drone racing is an active area of research. This project builds on insights from that body of work, combining them with massively parallel simulation to train racing policies within minutes — offering a fast and flexible platform for experimentation and benchmarking.

You can watch the related video here: https://youtu.be/wLTYtpEUEEk

Features

Key highlights of the Isaac Drone Racer project:

  1. Accurate Physics Modeling — Simulates rotor dynamics, aerodynamic drag, and power consumption to closely match real-world quadrotor behavior.
  2. Low-Level Flight Controller — Built-in attitude and rate controllers.
  3. Manager-Based Design — Modular architecture using IsaacLab's manager based architecture.
  4. Onboard Sensor Suite — Includes simulated fisheye camera, IMU and collision detection.
  5. Track Generator — Dynamically generate custom race tracks.
  6. Logger and Plotter — Integrated tools for monitoring and visualizing flight behavior.

Requirements

This framework has been tested on x64 based Linux systems, specifically Ubuntu 22.04. But it should also work on Windows 10/11.

Prerequisites

Setup

  1. Follow the Isaac Lab pip installation instructions, with the following modifications:
  • After cloning the Isaac Lab repository:
git clone git@github.com:isaac-sim/IsaacLab.git
  • Checkout the v2.1.0 release tag:
cd IsaacLab
git checkout v2.1.0
  1. Clone Isaac Drone Racer:
git clone https://github.com/kousheekc/isaac_drone_racer.git
  1. Install the modules in editable mode
cd isaac_drone_racer
pip3 install -e .

Usage

The drone racing task is registered as a standard Gym environment with the ID: Isaac-Drone-Racer-v0. Training and evaluation are powered by the skrl library.

Training a Policy

To train a policy, run the following command from the root of the isaac_drone_racer repository. This will launch the simulation in headless mode with 4096 agents running parallelly.

python3 scripts/rl/train.py --task Isaac-Drone-Racer-v0 --headless --num_envs 4096

Note

You can pass additional CLI arguments supported by the AppLauncher. Additionally since IsaacLab supports the Hydra Configuration System, task specific parameters can be adjusted from CLI. For example, to disable the motor model during training:

python3 scripts/rl/train.py --task Isaac-Drone-Racer-v0 --headless --num_envs 4096 env.actions.control_action.use_motor_model=False

Playing Back a Trained Policy

To run a trained policy in the simulator:

python3 scripts/rl/play.py --task Isaac-Drone-Racer-Play-v0 --num_envs 1

This will launch a single agent with the latest checkpoint and play the trained policy in the racing environment. All the same CLI and Hydra configuration options used during training are supported here as well.

Next Steps

  • Data-driven aerodynamic model pipeline - integrate tools for data driven system identification, calibration and include the learned aerodynamic forces into the simulation environment.
  • Power consumption model - incorporate a detailed power model that accounts for battery discharge based on current draw.
  • Policy learning using onboard sensors - explore and implement methods to transition away from full-state observations by instead using only onboard sensor data (e.g camera + IMU).

Troubleshooting

  • When running a workflow script, ensure that the IsaacLab conda environment is active:
conda activate env_isaaclab
  • When launching Isaac Sim for the first time, it may take a significant amount of time to load (potentially 10 minutes). This is normal, please be patient.

Acknowledgement

  • Kaufmann, E., Bauersfeld, L., Loquercio, A., Müller, M., Koltun, V., & Scaramuzza, D. (2023). Champion-level drone racing using deep reinforcement learning. https://doi.org/10.1038/s41586-023-06419-4

  • Rudin, N., Hoeller, D., Reist, P., & Hutter, M. (2022). Learning to Walk in Minutes Using Massively Parallel Deep Reinforcement Learning. arXiv:2109.11978

  • Ferede, R., De Wagter, C., Izzo, D., & de Croon, G. C. H. E. (2024). End-to-end Reinforcement Learning for Time-Optimal Quadcopter Flight. https://doi.org/10.1109/ICRA57147.2024.10611665

License

This project is licensed under the BSD 3-Clause License - see the LICENSE file for details.

Contact

Kousheek Chakraborty - kousheekc@gmail.com

Project Link: https://github.com/kousheekc/isaac_drone_racer

If you encounter any difficulties, feel free to reach out through the Issues section. If you find any bugs or have improvements to suggest, don't hesitate to make a pull request.

About

Isaac Drone Racer is a reinforcement learning framework for high speed autonomous drone racing, built on top of IsaacLab

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages