Skip to content

We apply DQN algorithm to make and artificial agent learn how to land space-craft on moon.

Notifications You must be signed in to change notification settings

ShivankYadav/LunarLander-using-DQN

Repository files navigation

Deep Q-Learning on LunarLander-v2

We apply DQN algorithm to make and artificial agent learn how to land space-craft on moon. The code is explained in the Deep_Q_network.ipynb. You guys are welcome to imporve the hyperparameters or even the algorithm for better performance(check step 5:Explore of the notebook). I have also provided a PDF_research_paper to explain Deep Q-Networks. This project is based on this research paper.

Environment Description

https://gym.openai.com/envs/LunarLander-v2/

Install requirements

Simply execute this on your shell: $pip install -r requirements.txt

Note: The user must install pytorch according to the specifications on his/her workspace. I used torch 1.4.0 and torchvision 0.4.2.

You can skip running the dqn method to avoid train and just run the code using pretrained weights in checkpoint.pth i have provided.

Algorithm used:

"Algorithm_image"

Before training

"Gif"

After training

"Gif"