pg_rnn icon indicating copy to clipboard operation
pg_rnn copied to clipboard

There are few caveats when you want to use a Recurrent Neural Network (RNN) policy with Policy Gradient Algorithms. This repository explains them and provide a solution for them. Please see the blog f...

Policy Gradient with Recurrent Neural Network (RNN)

Modular implementation of Vanila Policy Gradient (VPG) algorithm with an RNN policy.

Dependencies

Features

  • Using an RNN policy for giving the action probabilities for a reinforcement learning problem
  • Using a sampler that reshape the trajectory to be feed into an RNN policy
  • Using gradient clipping to solve the exploding gradient problem
  • Using GRU to solve the vanishing gradient problem

Usage

To train a model for Cartpole-v0:

$ python run_pg_rnn.py 

To view the tensorboard

$tensorboard --logdir .

Results

  • Tensorboard Progress Bar