Skip to content
Train an agent to play flappy bird game using double DQN model and implement it with pytorch.
Python
Branch: master
Clone or download
Latest commit 0b51b3b Aug 18, 2018
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
tmp Create help.txt Aug 18, 2018
README.md Update README.md Aug 18, 2018
agent.py Add files via upload Aug 18, 2018
dqn2.py Add files via upload Aug 18, 2018
env.py
main.py Add files via upload Aug 18, 2018
replay_buffer.py Add files via upload Aug 18, 2018
result.gif Add files via upload Aug 18, 2018
trainer.py Add files via upload Aug 18, 2018

README.md

Flappy-Bird-Double-DQN-Pytorch

Train an agent to play flappy bird game using double DQN model and implement it with pytorch.

Result

Installations (suggest using virtualenv)

  • Pygame
$ pip install pygame
  • ple
$ git clone https://github.com/ntasfi/PyGame-Learning-Environment.git
$ cd PyGame-Learning-Environment/
$ pip install -e .
  • gym
$ pip install gym
  • gym-ple
$ pip install gym-ple

How to run

  • Train
# If cuda is available, add --cuda Y.
# Add --ckpt [ckpt_file] to train from this checkpoint. 
$ python main.py --mode train 
  • Evaluation
# If cuda is available, add --cuda Y.
$ python main.py --mode eval --ckpt [checkpoint.pth.tar]
You can’t perform that action at this time.