Dark Mode

Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

akashe/DeepReinforcementLearning

Repository files navigation

Deep RL algorithms implemented using Pytorch

Algo list:

  1. DQN
  2. Vanilla policy Gradient
  3. Deep Deterministic Policy Gradient
  4. Twin Delayed Deep Deterministic Policy Gradient
  5. Soft Actor Critic
  6. Proximal Policy Optimization - CLIP
Article on deeper Look into policy gradients

Experimental Results:

Algorithm Discrete Env: LunarLander-v2 Continuous Env: Pendulum-v0
DQN -
VPG -
DDPG -
TD3 -
SAC -
PPO -

Resources:

  1. RL course by David Silver
  2. Lecture slides for above course
  3. Spinning up by OpenAI
  4. More exhaustive RL guide by Deeny Britz

Installation:

Prerequisites:

  • Python 3.8+ (3.8.10 recommended)
  • pyenv (optional but recommended)
  • Homebrew (for macOS users)

Setup:

  1. Clone the repository:

    git clone https://github.com/akashe/DeepReinforcementLearning.git
    cd DeepReinforcementLearning
  2. Set up Python environment:

    # Option A: Using pyenv (recommended)
    pyenv install 3.8.10
    pyenv local 3.8.10

    # Option B: Using system Python 3.8+
    # Make sure you have Python 3.8+ installed
  3. Install system dependencies (for Box2D environments like LunarLander):

    # macOS:
    brew install swig

    # Ubuntu/Debian:
    sudo apt-get install swig

    # Other systems: install swig through your package manager
  4. Create and activate virtual environment:

    python -m venv venv
    source venv/bin/activate # On Windows: venv\Scripts\activate
  5. Install Python dependencies:

    pip install -r requirements.txt

Usage:

Just run the file/algorithm directly. There is no common structures between algorithms as I implemented them as I learnt them. Different algorithms are inspired from different sources.

Examples:

python ddpg.py # Run DDPG on Pendulum-v1
python DQN.py # Run DQN on LunarLander-v2
python td3.py # Run TD3 on Pendulum-v1
python SoftActorCritic.py # Run SAC on Pendulum-v1

About

Deep RL implementations. DQN, SAC, DDPG, TD3, PPO and VPG implemented in pytorch. Tested Env: LunarLander-v2 and Pendulum-v0.

Topics

Resources

Readme

Stars

Watchers

Forks

Releases

No releases published

Packages

Contributors