Skip to main content

RL4Net

RL4Net is a reinforcement learning platform based on Pytorch and OpenAI Gym.The supported interface algorithms currently include:

  • Sarsa

  • Qlearning

  • Deep Q-Network (DQN)

  • Deep Deterministic Policy Gardient (DDPG)

Installation

Notice: The platform uses pytorch and numpy. It is recommended to use conda to create a new environment and install it.

RL4Net is currently hosted on PyPI. It requires Python >= 3.6.

You can simply install RL4Net from PyPI with the following command:

pip install rl4net

You can also install with the newest version through GitHub:

pip install git+https://github.com/bupt-ipcr/RL4Net.git@master

Or install it after downloading it locally:

git clone https://github.com/bupt-ipcr/RL4Net

Enter folder and install it with pip:

cd RL4Net
pip install .

After installation, run examples :

python examples/ddpg.py

If no error occurs, you have successfully installed RL4Net.

Documentation

Todo

Quick Start

You can create your own reinforcement learning agent through the base class provided in rl4net.agents.The general method is as follows:

# import base class
from rl4net.agents import xxxBase
# inherit and complete necessary methods
class myxxx(xxxBase):  
    def _build_net(self):
        pass

learn more about the usage, by codes examples and annotated documentations under examples/ .

Simple neural networks built on pytorch are also provided in rl4net.models. You can take it as a simple implement of DRL neural network.

from rl4net.models import SimpleDQNNet

Third, if you want to call the attached envs, you should run __init__.py to register to gym. After that you can use standard gym methods to create it.

import rl4net.env  
env = gym.make('Maze-v0')

Contributing

VVALB is still under development. More algorithms and features are going to be added and we always welcome contributions to help make VVLAB better. If you would like to contribute, please check out this link.

Metadata

Release files for rl4net 0.2.6

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for rl4net 0.2.6
File Size Uploaded
rl4net-0.2.6.tar.gz 35.0 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for rl4net 0.2.6
File Interpreter ABI Platform
rl4net-0.2.6-py2.py3-none-any.whl Python 3, Python 2 none any Details

Total release size: 87.2 kB

Release files / rl4net-0.2.6.tar.gz

Download URL rl4net-0.2.6.tar.gz
Size 35.0 kB
Tags Source
SHA-256 checksum
How to use checksums
1c80ec35685d6ebfa6413b7cc7f0accde8d9b544c47eee38136a46bfff83db3b
BLAKE2b-256 checksum
How to use checksums
e76f8d8846e462f4b3dd105caa08d5ce88619920f1eb49b7e18aa456e81becda
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/46.1.3 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.7.6

Release files / rl4net-0.2.6-py2.py3-none-any.whl

Download URL rl4net-0.2.6-py2.py3-none-any.whl
Size 52.2 kB
Tags Python 2 Python 3
SHA-256 checksum
How to use checksums
b0880f4c0426250a5a9b07b723fbcf377b21d7c9bb596037eb50ae8a8e3e53de
BLAKE2b-256 checksum
How to use checksums
0f3ff34cb51ff27d5d11700a97e64e426711add3218e69c2e7369b128e40684e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/46.1.3 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.7.6

Release history Release notifications | RSS feed

This release

0.2.6 This release

2 release files

0.2.5

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page