GithubHelp home page GithubHelp logo

behdadch / bayesrace Goto Github PK

View Code? Open in Web Editor NEW

This project forked from jainachin/bayesrace

0.0 0.0 0.0 27.7 MB

Learning based control for autonomous racing

License: MIT License

Python 100.00%

bayesrace's Introduction

BayesRace

BayesRace is a model-based planning and control framework for autonomous racing. It focuses on two problems:

  1. Computing the racing line using Bayesian optimization PDF
@InProceedings{JainRaceOpt2020,
  author    = {Jain, Achin and Morari, Manfred},
  title     = {{Computing the racing line using Bayesian optimization}},  
  booktitle = {Proceedings of the 59th IEEE Conference on Decision and Control (CDC)},
  year      = {2020},
}
  1. Designing a self-learning controller that reduces the effort required for system identification by learning from prior experience PDF
@InProceedings{JainBayesRace2020,
  author    = {Jain, Achin and O'Kelly, Matthew and Chaudhari, Pratik and Morari, Manfred},
  title     = {{BayesRace: Learning to race autonomously using prior experience}},  
  booktitle = {Proceedings of the 4th Conference on Robot Learning (CoRL)},
  year      = {2020},
}

Installation

We recommend creating a new conda environment:

conda create --name bayesrace python=3.6
conda activate bayesrace

Then install BayesRace:

git clone https://github.com/jainachin/bayesrace.git
cd bayesrace/
pip install -e .

How to run

The following steps are explained for the 1:43 scale autonomous racing platform at ETH Zurich. We also provide code for the 1:10 scale F1TENTH racing platform at University of Pennsylvania.

  1. Compute the racing line for the track we want to race on.

    cd bayes_race/raceline
    python generate_raceline_ethz.py
    

  2. Run a pure pursuit controller on a different track to log sensor measurements and state estimates. This data resemble true system dynamics.

    cd bayes_race/pp
    python run_pp_orca.py
    

  3. Given a trajectory of states from Step 2, generate an equivalent trajectory using a simpler and easy-to-tune e-kinematic model.

    cd bayes_race/data
    python simulate_kinematic_orca.py
    
  4. Train Gaussian process models to predict mismatch between true system dynamics from Step 2 and e-kinemtic model from Step 3.

    cd bayes_race/gp
    python train_model_orca.py
    
  5. Validate the trained models on the track we want to race.

    cd bayes_race/gp
    python plot_uncertainty_orca.py
    

  6. Run MPC with and without GP correction. By default boundary constraints are turned off for faster execution.

    cd bayes_race/mpc
    python run_nmpc_orca_gp.py
    

    MPC without GP correction is shown on the left, and with GP correction on the right.

  7. Benchmark the performance in Step 6 against MPC with true model dynamics.

    cd bayes_race/mpc
    python run_nmpc_orca_true.py
    

  8. Finally, update the GP models using data collected in Step 6 that is specific to the racing track and re-run MPC with the updated GP models.

    cd bayes_race/gp
    python update_model_orca.py
    
    cd bayes_race/mpc
    python run_nmpc_orca_gp_updated.py
    

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.