yempi / snake-game

AI plays Snake. Reinforcement Learning with Pytorch and Pygame

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Table of contents

General info

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.

Technologies

Project is created with:

  • Python 3.9
  • Pygame 2.0.1
  • PyTorch (Stable 1.8.1)
  • Apple's M1 Chip

Setup

To run this project, install it locally using Terminal:

$ python3 agent.py

Sources

This project is inspired by Patrick Loeber's project 'Teach AI to play Snake!'(https://github.com/python-engineer/snake-ai-pytorch)

About

AI plays Snake. Reinforcement Learning with Pytorch and Pygame


Languages

Language:Python 100.0%