Giter Site home page Giter Site logo

ar-tu-do's Introduction

Autonomous Racing Software Stack and Simulation Enviroment

Build Status

This repository contains software for 1/10th scale autonomous race cars to compete in the F1/10 competition. It is developed by the Autonomous Racing Project Group of TU Dortmund.

Features

We provide several LIDAR based driving algorithms:

  • Fast and efficient wallfollowing based on fitting circles into the LIDAR scan
  • ROS navigation stack based implementation that uses SLAM, a precalculated map and path planning
  • Deep Reinforcement Learning (Q-Learning and Policy Gradient)
  • Neural Networks with evolutionary training

Our software works on physical hardware and in a simulated environment using Gazebo. Further features are:

  • Automatic emergency braking
  • Dead Man's Switch
  • Teleoperation via keyboard, Xbox and Playstation controller
  • Speedometer and Lap Timer

Installation

You need to install the Robot Operating System (ROS) to use our software. We target ROS Kinetic on Ubuntu 16.04, but ROS Melodic seems to work as well.

Note for VM users: Gazebo 7.0.0, which is installed with ROS Kinetic by default, does not work on a virtual machine. To solve this, Gazebo has to be updated to at least 7.4.0 as explained here.

Install dependencies:

sudo pip uninstall pip && sudo apt install python-pip
sudo apt install libsdl2-dev clang-format python-pyqtgraph
pip install torch autopep8 cython circle-fit

# RangeLibc
git clone http://github.com/kctess5/range_libc
cd range_libc/pywrapper
# Either:
./compile.sh            # on VM
# Or:
./compile_with_cuda.sh  # on car - compiles GPU ray casting methods

Clone the repository:

git clone --recurse-submodules https://github.com/Autonomous-Racing-PG/ar-tu-do.git

Install missing ROS dependencies:

cd ar-tu-do/ros_ws
rosdep install -y --from-paths src --ignore-src --rosdistro ${ROS_DISTRO}

Usage

Compile while inside the ros_wsdirectory:

catkin_make

Set up enviroment variables for your shell:

source devel/setup.bash # (or setup.zsh, depending on your shell)

Use a launch file to start ROS and Gazebo:

roslaunch launch/car.launch                   # (Physical car, Wallfollowing)
roslaunch launch/car_navigation_stack.launch  # (Physical car, SLAM & ROS navigation)
roslaunch launch/gazebo.launch                # (Simulation, Wallfollowing)
roslaunch launch/navigation_stack.launch      # (Simulation, SLAM & ROS navigation)
roslaunch launch/q_learning.launch            # (Simulation, Train the Q-Learning model)
roslaunch launch/policy_gradient.launch       # (Simulation, Train the Policy Gradient model)
roslaunch launch/evolutionary.launch          # (Simulation, Train the evolutionary neural network)

Launch file arguments

These arguments can be passed to the launch files above. For example, to use the gazebo.launch file without emergency stop and with car highlighting, run:

roslaunch launch/gazebo.launch emergency_stop:=false car_highlighting:=true

The arguments can be changed permanently by editing the launch files.

Argument Description Supported by launch/<file>.launch
car car_navstack gazebo navigation_stack q_learning, policy_gradient, evolutionary
debug Boolean value whether Gazebo should run in debug mode. Defaults to false.
emergency_stop Boolean value whether the emergency stop should be active. Defaults to true.
gui Boolean value whether Gazebo should show a user interface. Defaults to true.
joystick_type The type of joystick controller. Possible values: ps3, xbox360 and xboxone
map Name of the map to be used by the particle filter. Defaults to a prerecorded map of racetrack_decorated_2.
(no default)
paused Boolean value whether Gazebo should start paused. Defaults to false.
pf_angle_step Angle step of the particle filter. Defaults to 18.
pf_max_particles Maximum amount of particles to be used by the particle filter. Defaults to 500.
pf_squash_factor Squash factor of the particle filter. Defaults to 2.2.
plot_window Integer value indicating the amount of episodes that should be plotted. Defaults to 200. ✓ / ✓ / ✗
realtime_simulation Boolean value whether Gazebo should try to simulate with a real time factor of 1. If false, Gazebo tries to simulate as fast as possible. Defaults to true.
use_gpu Boolean value whether Gazebo should use the GPU when simulating the lidar. Defaults to true.
use_sim_time Boolean value whether all ros nodes should use simulated Gazebo time instead of wall clock time. Defaults to true.
verbose Boolean value whether Gazebo should give verbose standard output. Defaults to true.
visualize_lidar Boolean value whether Gazebo should show the simulated lidar rays. Defaults to false.
world The name of the racetrack. Possible values: racetrack_decorated, racetrack_decorated_2 (default) and racetrack_decorated_2_big

Hardware

Our car is based on a 1/10th scale RC car (Traxxas Ford Fiesta) with these additions:

Documentation

  • For general information and documentation check out our wiki page.
  • For source code documentation check out the auto-generated Doxygen documentation.

License

This project (excluding git submodules) is under MIT and GPLv3 dual licensed - see the MIT.LICENSE and GPLv3.LICENSE file for details.

ar-tu-do's People

Contributors

marian42 avatar nils-jung avatar stefanjva avatar sami19944 avatar dadie avatar luc4sw avatar flyingdutchmanc avatar malikatamne avatar digitalwayfarer avatar nklasf avatar ce-sch avatar

Watchers

James Cloos avatar

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.