Skip to content

patrick-gu/ai2048

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

2048 AI

A bot that plays the game 2048.

It consists of two small neural networks for the playing polcy and value function, which are optimized using Proximal Policy Optimization (PPO).

Results

Roughly logarithmic upward trend

The bot's average number of moves per game per batch of training.

After training for a few hours on a CPU, the bot is able to get good enough to sometimes beat the game by building the 2048 block.

Usage

  • main.py is a script to train the bot and periodically write checkpoints.
  • demo.py allows you to view games from the bot. You can use it to see that the bot beats the game by building the 2048 block!
  • game.py is just the game itself.

About

Playing 2048 with Reinforcement Learning

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages