Yet Another Reinforcement Learning Library (YARLL)
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):
- Advantage Actor Critic
- Asynchronous Advantage Actor Critic (A3C)
- Deep Deterministic Policy Gradient (DDPG)
- Proximal Policy Optimization (PPO)
- Soft Actor-Critic (SAC)
- Trust Region Policy Optimization (TRPO)
- REINFORCE (convolutional neural network part has not been tested yet)
- Cross-Entropy Method
- Sarsa with with function approximation and eligibility traces
- Karpathy's policy gradient algorithm (version using convolutional neural networks has not been tested yet)
- (Sequential) knowledge transfer
- Asynchronous knowledge transfer
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:
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.
Metadata
Release files for yarll 0.0.12
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| yarll-0.0.12.tar.gz | 55.6 kB | Without provenance | Details for yarll-0.0.12.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| yarll-0.0.12-py3-none-any.whl | Python 3 | none | any | Details for yarll-0.0.12-py3-none-any.whl |
Total release size: 139.3 kB
Release files / yarll-0.0.12.tar.gz
| Download URL | yarll-0.0.12.tar.gz |
|---|---|
| Size | 55.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
1abf7774e7a6ffc29363d559fa325363c70c579e0eea94613d2b00b76e587a3e
|
|
BLAKE2b-256 checksum How to use checksums |
d78a3f01b1f168a803910af1a617696e82412512cc193e69a48691fa00dc4d29
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.4.0 requests-toolbelt/0.9.1 tqdm/4.38.0 CPython/3.7.4
|
Release files / yarll-0.0.12-py3-none-any.whl
| Download URL | yarll-0.0.12-py3-none-any.whl |
|---|---|
| Size | 83.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
56d2b8b298798c5e30c453ad4fd480adb8c7a7de69418a359422b1559a05524d
|
|
BLAKE2b-256 checksum How to use checksums |
049f1bcf8dd7d6a484ad19599b396b03df70841ca63de2082ea5d13e282959a5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.0.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.4.0 requests-toolbelt/0.9.1 tqdm/4.38.0 CPython/3.7.4
|
Security for yarll 0.0.12
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.