minimalRL  by seungeunrho

PyTorch implementations of RL algorithms with minimal code

created 6 years ago
3,041 stars

Top 16.1% on sourcepulse

GitHubView on GitHub
Project Summary

This repository provides minimal, single-file PyTorch implementations of fundamental Reinforcement Learning algorithms. It targets RL researchers and students seeking to quickly understand and experiment with core RL concepts without the overhead of complex frameworks. The primary benefit is rapid learning and iteration due to concise, self-contained code.

How It Works

The project implements various RL algorithms, including REINFORCE, Actor-Critic, DQN, PPO, DDPG, A3C, ACER, SAC, and Vtrace, each within a single file of approximately 100-150 lines. This approach prioritizes clarity and conciseness, allowing users to focus solely on the algorithm's logic. All implementations are designed to train within 30 seconds on the "CartPole-v1" environment, even without a GPU.

Quick Start & Requirements

  • Primary install / run command: python3 <algorithm_name>.py (e.g., python3 ppo.py)
  • Prerequisites: PyTorch, OpenAI GYM (> 0.26.2).
  • Setup time: Minimal, as algorithms train quickly.
  • Docs: README

Highlighted Details

  • Each algorithm implemented in a single file (up to 150 lines).
  • Training completes within 30 seconds, even without GPU.
  • Fixed environment: "CartPole-v1".
  • Includes implementations for REINFORCE, DQN, PPO, DDPG, A3C, ACER, SAC, Vtrace, and more.

Maintenance & Community

The repository is maintained by seungeunrho. There are no explicit mentions of community channels or a roadmap in the README.

Licensing & Compatibility

The repository does not explicitly state a license. This lack of a specified license may imply all rights are reserved, potentially restricting commercial use or integration into closed-source projects.

Limitations & Caveats

The project is strictly limited to the "CartPole-v1" environment and does not support previous versions of OpenAI GYM. The absence of a specified license is a significant caveat for any potential adoption.

Health Check
Last commit

2 years ago

Responsiveness

1 week

Pull Requests (30d)
0
Issues (30d)
0
Star History
43 stars in the last 90 days

Explore Similar Projects

Feedback? Help us improve.