What is the difference between reinforcement learning and deep RL?

Christopher Klaus picture Christopher Klaus · Jun 22, 2016 · Viewed 11.7k times · Source

What is the difference between deep reinforcement learning and reinforcement learning? I basically know what reinforcement learning is about, but what does the concrete term deep stand for in this context?

Answer

bakkal picture bakkal · Jun 22, 2016

Reinforcement Learning

In reinforcement learning, an agent tries to come up with the best action given a state.

For example, in the video game Pac-Man, the state space would be the 2D game world you are in, the surrounding items (pac-dots, enemies, walls, etc), and actions would be moving through that 2D space (going up/down/left/right).

So, given the state of the game world, the agent needs to pick the best action to maximise rewards. Through reinforcement learning's trial and error, it accumulates "knowledge" through these (state, action) pairs, as in, it can tell if there would be positive or negative reward given a (state, action) pair. Let's call this value Q(state, action).

A rudimentary way to store this knowledge would be a table like below

state | action | Q(state, action)
---------------------------------
  ... |   ...  |   ...

The (state, action) space can be very big

However, when the game gets complicated, the knowledge space can become huge and it no longer becomes feasible to store all (state, action) pairs. If you think about it in raw terms, even a slightly different state is still a distinct state (e.g. different position of the enemy coming through the same corridor). You could use something that can generalize the knowledge instead of storing and looking up every little distinct state.

So, what you can do is create a neural network, that e.g. predicts the reward for an input (state, action) (or pick the best action given a state, however you like to look at it)

Approximating the Q value with a Neural Network

So, what you effectively have is a NN that predicts the Q value, based on the input (state, action). This is way more tractable than storing every possible value like we did in the table above.

Q = neural_network.predict(state, action)

Deep Reinforcement Learning

Deep Neural Networks

To be able to do that for complicated games, the NN may need to be "deep", meaning a few hidden layers may not suffice to capture all the intricate details of that knowledge, hence the use of deep NNs (lots of hidden layers).

The extra hidden layers allows the network to internally come up with features that can help it learn and generalize complex problems that may have been impossible on a shallow network.

Closing words

In short, the deep neural network allows reinforcement learning to be applied to larger problems. You can use any function approximator instead of an NN to approximate Q, and if you do choose NNs, it doesn't absolutely have to be a deep one. It's just researchers have had great success using them recently.