Code Monkey home page Code Monkey logo

bananas's Introduction

Bananas RL

Bananas animation

Deep Q-Learning agent learns how to navigate a world full of bananas.

The agent in this project uses the following RL techniques:

  • Prioritized Experience Replay
  • Double DQN (DDQN)
  • Dueling DQN

Overview

To be successful in this environment, the RL agent must learn to collect yellow bananas (reward +1) while avoiding blue bananas (reward -1).

The state has a size of 37 and contains information such as the agent's velocity and ray-based perception of objects in front of the agent.

Action space:

  • 0: Forward
  • 1: Backward
  • 2: Turn left
  • 3: Turn right

The environment is solved if the agent achieves an average score of +13 over 100 consecutive episodes.

Setup

Follow the instructions here to:

  1. Create a conda environment.
  2. Clone the Udacity Deep RL repository.
  3. Install Python packages into the environment.
  4. Create an IPython kernel using the environment.

The OpenAI Gym instructions can be skipped.

In order to watch the agent play the game, you also need to download the environment by following the instructions here.

Notebook

Once you've completed the setup, you can:

  1. Open Navigation.ipynb.
  2. Select the kernel created during setup.
  3. Run all the cells in the notebook to train the agent.

Watching the agent

Follow the instructions here, load the saved neural network weights (checkpoint.pth), and watch the trained agent play the game!

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.