Skip to content

DevCharanSaiP/Reinforcement-Learning-Algorithms

Repository files navigation

Reinforcement Learning Implementations

This repository contains a collection of Reinforcement Learning (RL) implementations in Jupyter notebooks. Each notebook demonstrates a different RL algorithm or problem, providing hands-on examples and clear explanations.

Notebooks

Below is a list of the notebooks included in this repository, along with a brief description of each.

1. DQN CartPole-v1

  • Description: This notebook implements a Deep Q-Network (DQN) to solve the CartPole-v1 environment from OpenAI Gym. The goal is to balance a pole on a cart by applying forces to the cart.
  • Algorithm: Deep Q-Network (DQN)
  • Environment: CartPole-v1

2. Deep Deterministic Policy Gradient (DDPG)

  • Description: This notebook demonstrates the Deep Deterministic Policy Gradient (DDPG) algorithm, which is designed for continuous action spaces. It is applied to the Pendulum-v1 environment.
  • Algorithm: Deep Deterministic Policy Gradient (DDPG)
  • Environment: Pendulum-v1

3. Frozen Lake Problem using Dynamic Programming

  • Description: This notebook solves the Frozen Lake environment using Dynamic Programming. It demonstrates how to find the optimal policy in a grid-based environment where the agent must navigate from a starting point to a goal while avoiding holes.
  • Algorithm: Dynamic Programming (Policy Iteration)
  • Environment: FrozenLake-v1

4. Grid World Problem

  • Description: This notebook implements a simple Grid World environment and solves it using Q-learning. The agent learns to navigate a grid to reach a goal state while receiving rewards and penalties.
  • Algorithm: Q-Learning
  • Environment: Custom Grid World

5. Q-Learning Vs SARSA - LunarLander-v2

  • Description: This notebook compares the performance of Q-Learning and SARSA on the LunarLander-v2 environment. It showcases the differences between these two temporal-difference learning algorithms in a more complex environment.
  • Algorithms: Q-Learning, SARSA
  • Environment: LunarLander-v2

Getting Started

To run these notebooks, you will need to have Python and Jupyter installed. You can install the required libraries using pip:

```bash pip install numpy gym torch matplotlib ```

After installing the dependencies, you can launch Jupyter Notebook and open the desired .ipynb file.

Contributions

Contributions are welcome! If you have any improvements or new implementations to add, feel free to open a pull request.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •