An open API service indexing awesome lists of open source software.

https://github.com/mohammedrashithkp/drlforsnakegame

This project utilises a Deep Reinforcement Learning specifically Q learning implemented using PyTorch which learns the game by interacting with the pygame environment .I have followed a tutorial on Freecodecamp YouTube Channel and made the initial model.
https://github.com/mohammedrashithkp/drlforsnakegame

deep-reinforcement-learning matplotlib-pyplot numpy pygame python

Last synced: about 1 month ago
JSON representation

This project utilises a Deep Reinforcement Learning specifically Q learning implemented using PyTorch which learns the game by interacting with the pygame environment .I have followed a tutorial on Freecodecamp YouTube Channel and made the initial model.

Awesome Lists containing this project

README

          

# Deep Reinforcemnet Learning For Snake Game
This project utilises a Deep Reinforcement Learning specifically Q learning implemented using PyTorch which learns the game by interacting with the pygame environment .I have followed a tutorial on Freecodecamp YouTube Channel and made the initial model.
## Demo Training Video
https://github.com/user-attachments/assets/0c2ae865-a5fc-4299-8c31-3a7e7a47a919

## Working [TODO]
## How to Use
1. Clone and Change to the project directory by running
```bash
git clone https://github.com/mohammedrashithkp/RNN-for-Snake-Game.git && cd RNN-for-Snake-Game
```
2. Install the dependencies by running
```
pip install -r requirements.txt
```
3.Run the Program
``` bash
python agent.py
```
## Current Highscore Obtained

![Reward for 1000 Runs_page-0001](https://github.com/user-attachments/assets/ae1c21f2-e94f-4adc-a079-a6b92723aa6b)

## References
- [FCC YT Tutorial](https://youtu.be/L8ypSXwyBds?feature=shared)
- [Pygame Tutorial](https://youtu.be/FfWpgLFMI7w?feature=shared)
- [Pytorch Tutorial](https://youtu.be/V_xro1bcAuA?feature=shared)