Skip to main content

Yet Another Reinforcement Learning Library

Project description

Yet Another Reinforcement Learning Library (YARLL)

Codacy Badge

Update 25/03/2019: For now, the master branch won't get big changes. Instead, algorithms are adapted for TensorFlow 2 (and new ones may be added) on the TF2 branch.
Update 29/10/2018: New library name.
Update 25/10/2018: Added SAC implementation.

Status

Different algorithms have currently been implemented (in no particular order):

Asynchronous Advantage Actor Critic (A3C)

The code for this algorithm can be found here. Example run after training using 16 threads for a total of 5 million timesteps on the PongDeterministic-v4 environment:

Pong example run

How to run

First, install the library using pip (you can first remove OpenCV from the setup.py file if it is already installed):

pip install yarll

Algorithms/experiments

You can run algorithms by passing the path to an experiment specification (which is a file in json format) to main.py:

python -m yarll.main <path_to_experiment_specification>

Examples of experiment specifications can be found in the experiment_specs folder.

Statistics

Statistics can be plot using:

python -m yarll.misc.plot_statistics <path_to_stats>

<path_to_stats> can be one of 2 things:

  • A json file generated using gym.wrappers.Monitor, in case it plots the episode lengths and total reward per episode.
  • A directory containing TensorFlow scalar summaries for different tasks, in which case all of the found scalars are plot.

Help about other arguments (e.g. for using smoothing) can be found by executing python -m yarll.misc.plot_statistics -h.

Alternatively, it is also possible to use Tensorboard to show statistics in the browser by passing the directory with the scalar summaries as --logdir argument.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for yarll, version 0.0.11
Filename, size File type Python version Upload date Hashes
Filename, size yarll-0.0.11-py3-none-any.whl (86.0 kB) File type Wheel Python version py3 Upload date Hashes View hashes
Filename, size yarll-0.0.11.tar.gz (54.0 kB) File type Source Python version None Upload date Hashes View hashes

Supported by

Elastic Elastic Search Pingdom Pingdom Monitoring Google Google BigQuery Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN SignalFx SignalFx Supporter DigiCert DigiCert EV certificate StatusPage StatusPage Status page