Skip to content

Solving MountainCar-v0 environment in Keras with Deep Q Learning an Deep Reinforcement Learning algorithm

Notifications You must be signed in to change notification settings

nitish-kalan/MountainCar-v0-Deep-Q-Learning-DQN-Keras

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

35 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MountainCar-v0 with Deep Q-Learning in Keras

MountainCar-v0 is an environment presented by OpenAI Gym. In this repository we have implemeted Deep Q Learning algorithm [1] in Keras for building an agent to solve MountainCar-v0 environment.

Commands to run

  • To train the model

    python train_model.py
    
  • To test the model

    python test_model.py 'path_of_saved_model_weights' (without quotes)
    
  • To test agent with our trained weights

    python test_model.py saved_model/-134.0_agent_.h5
    
The greater the value of the episodic reward achieved, the better is the model.

Results

  • Output of agent taking random actions

    Episode: 0 | width=20

  • Output of our agent at Episode: 550 with score -134.0

    Episode: 550, Score:-134.0

References

[1] Playing Atari with Deep Reinforcement Learning Authors: Volodymyr Mnih, Koray Kavukcuoglu, David Silver, Alex Graves, Ioannis Antonoglou, Daan Wierstra, Martin Riedmiller
Link: https://www.cs.toronto.edu/~vmnih/docs/dqn.pdf

Releases

No releases published

Packages

No packages published

Languages