In this project we can teach an AI to play Snake, creating the game with Pygame and the Deep Learning algorithm with PyTorch. We release the agent into the environment with zero knowledge about how to play the game and implement a reward system in order to teach it how to keep increasing the top score.
Project is created with:
- Python 3.9
- Pygame 2.0.1
- PyTorch (Stable 1.8.1)
- Apple's M1 Chip
To run this project, install it locally using Terminal:
$ python3 agent.py
This project is inspired by Patrick Loeber's project 'Teach AI to play Snake!'(https://github.com/python-engineer/snake-ai-pytorch)