← Open Source

Deep Q-learning for playing tetris game.

Model DevelopmentReinforcement LearningPython
Momentum
+0stars in 24 hours0.0%
532
Stars
118
Forks
+0
This week
1
Contributors
Created 2020-03-29 · Updated 2026-11-26 · #22713 today
Top developers
README

[PYTORCH] Deep Q-learning for playing Tetris

Introduction

Here is my python source code for training an agent to play Tetris. It could be seen as a very basic example of Reinforcement Learning's application.


Tetris demo

The demo could also be found at youtube demo

How to use my code

With my code, you can:

  • Train your model from scratch by running python train.py
  • Test your trained model by running python test.py

Trained models

You could find my trained model at trained_models/tetris

Requirements

  • python 3.6
  • PIL
  • cv2
  • pytorch
  • numpy
  • matplotlib
Nearby in the ranking
Similar items

AI Rank for iPhone

Follow AI model rankings

Download on the App Store