Git Product home page Git Product logo

unitydronesim's Introduction

Unity Drone Simulator

A drone created for Unity with realistic drone physics, intended for Reinforcement Learning Simulation.

Project AutoQuad, Spring 2018, UAVs @ Berkeley & Machine Learning @ Berkeley

alt text


Setup Instructions

  1. Download Blender: https://www.blender.org/download/
  2. Download Unity 2017: https://unity3d.com/get-unity/download/
  3. Clone this repo, master
    1. master: Currently velocity_control, stable (supports ML-Agents)
    2. velocity_control: for development of realistic velocity control for drone, supports ML-Agents interface
      1. ML-Agents v0.3.1b as of right now (0.3 necessary)
    3. custom_physics: Roll, Pitch, Yaw, Throttle PID control [1]
    4. cubedrone: precursor to velocity control branch
  4. Open Up Unity, and select Open and navigate to the root directory of this repository.
  5. Press Play to run the simulation
    1. velocity control branch
      1. I: FORWARD + STRAIGHT (default action in player mode)
      2. J: FORWARD + LEFT
      3. L: FORWARD + RIGHT
    2. custom_physics branch (behind on environment and ml-agents code)
      1. I: PITCH FORWARD
      2. K: PITCH BACKWARD
      3. J: ROLL LEFT
      4. L: ROLL RIGHT
      5. W: THROTTLE UP
      6. S: THROTTLE DOWN
      7. A: YAW LEFT
      8. D: YAW RIGHT
  6. To Build: File -> Build Settings, Build, and then select the
    1. Make sure the build settings are all correct for your environment
  7. See the AutoQuad repository for ML-Agents code to interface with the environment.
    1. Includes sample Imitation Learning and RL approaches

State Spaces

Choose between the following two states by toggling the use_new_state boolean in the DroneAgent.cs script (or in inspector under DroneParent -> DroneAgent).

  1. New state space (5 elements in this order)
    1. Heading (direction, normalized -1 to 1)
    2. Distance from target
    3. forward velocity (normalized)
    4. yaw rate (normalized)
    5. collision (1 or 0)
  2. Old state (13 elements in this order)
    1. (X,Y,Z) velocity
    2. (X,Y,Z) position
    3. (X,Y,Z) Euler angles
    4. (X,Y,Z) Target Position
    5. collision (1 or 0)

Observations are 128x128 grayscale images.


Members

ML@Berkeley:

Project Managers: Suneel Belkhale, Alex Li
Project Members: Gefen Kohavi, Murtaza Dalal, Daniel Ho, Franklin Rice, Allan Levy

UAV's@Berkeley:

Project Managers: Suneel Belkhale
Project Members: Alex Chan, Kevin Yang, Valmik Prabhu, Isabella Maceda, Erin Song, Dilan Bhalla, Asad Abbasi, Jason Kim


References

[1] For RPY PID Controller code: https://github.com/WebdiverShaka/DroneControl

unitydronesim's People

Contributors

suneelbelkhale avatar alexc2684 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.