/Breakout-Playing-AI

Primary LanguageJupyter NotebookMIT LicenseMIT

Breakout-Playing-AI

This project is implementation of Double Deep Q Learning paper by Hado van Hasselt and Arthur Guez and David Silver.

              ezgif com-gif-maker

Overview

Deep Q Learning is the combination of Deep Learning and Reinforcement Learning. In simple words, the Convolutional Neural Network learns to play the atarti game breakout like humans by Trial and Error.

Reinforcement Learning is Learning Optimal Decision Making by Rewards and Punishment.                image

It has different names in the differnet fields.                image

Requirements

This code was tested on a GPU powered laptop with:

  1. Python v3.8.5
  2. Jupyter Notebook v6.2.0
  3. OpenAI Gym v0.18
  4. Tensorflow GPU v2.3.2
  5. Numpy v1.19.2
  6. Matplotlib v3.3.2

Training

If you want to train the CNN from the random weights then run Breakout_train. This will create new weights file named Breakout_new.hdf5.

Testing

If you dont want to train the CNN and just see the results then run Breakout_test. This will run the code with the given weights file.

Results and Conclusion

Results.mp4

The results of the experiment can be seen in the video above. The performance of the agent is not reached to the level of agent mentioned in the DDQN paper. This could be due to the memory constraints of the machine on which the simulation was done.

The results can be improved by training the agent in a Good Performing Machine for longer time.