Prerequisites: Deep Q-Learning
This article will demonstrate how to do reinforcement learning on a larger environment than previously demonstrated. We will be implementing Deep Q-Learning technique using Tensorflow.
Note: A graphics rendering library is required for the following demonstration. For Windows operating system, PyOpenGl is suggested while for Ubuntu operating system, OpenGl is recommended.
Step 1: Importing the required libraries
Step 2: Building the Environment
Note: A preloaded environment will be used from OpenAI’s gym module which contains many different environments for different purposes. The list of environments can be viewed from their website.
Here, the ‘MountainCar-v0’ environment will be used. In this, a car(the agent) is stuck between two mountains and has to drive uphill on one of them. The car’s engine is not strong enough to drive up on it’s own and thus the car has to build momentum to get uphill
Step 3: Building the learning agent
The learning agent will be built using a deep neural network and for the same purpose, we will be using the Sequential class of the Keras module.
Step 4: Finding the Optimal Strategy
The agent tries different methods to reach the top and thus gaining knowledge from each episode.
Step 5: Testing the Learning Agent
The agent tries to apply it’s knowledge to reach the top.
- Deep Q-Learning
- NLP | Flattening Deep Tree
- Deep Face Recognition
- Introduction to Deep Learning
- ML - List of Deep Learning Layers
- Differential Privacy and Deep Learning
- Deep Learning with PyTorch | An Introduction
- Residual Networks (ResNet) - Deep Learning
- ML - Saving a Deep Learning model in Keras
- Prediction of Wine type using Deep Learning
- ML | Natural Language Processing using Deep Learning
- DLSS - Deep Learning Super Sampling
- Human Activity Recognition - Using Deep Learning Model
- Deep Learning | Introduction to Long Short Term Memory
- DeepPose: Human Pose Estimation via Deep Neural Networks
- Deep Neural net with forward and back propagation from scratch - Python
- Implementing Photomosaics
- ML | Implementing L1 and L2 regularization using Sklearn
- Implementing slicing in __getitem__
- Implementing DBSCAN algorithm using Sklearn
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to email@example.com. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.