Summary

Many researchers believe that RL is the best shot we have of creating artificial general intelligence. It is an exciting field, with many unsolved challenges and huge potential. Although it can appear challenging at first, getting started in RL is actually not so difficult. In this chapter, we have described some basic principles of RL.

The main thing we have discussed is the Q-Learning algorithm. Its distinctive feature is the capacity to choose between immediate rewards and delayed rewards. Q-learning at its simplest uses tables to store data. This very quickly loses viability when the size of the state/action space of the system it is monitoring/controlling increases.

We can overcome this problem using a neural network as a function approximator that takes the state and action as input and outputs the corresponding Q-value.

Following this idea, we implemented a Q-learning neural network using the TensorFlow framework and the OpenAI Gym toolkit to win at the FrozenLake game.

In the last part of the chapter, we introduced deep reinforcement learning. In traditional RL, the problem spaces were very limited and there were only a few possible states in an environment. This was one of the major limitations of traditional approaches. Over the years, there have been a couple of relatively successful approaches that were able to deal with larger state spaces by approximating the state.

The advances in deep learning algorithms have led to a new wave of successful applications in RL, because it offers the opportunity to efficiently work with high-dimensional input data (such as images). In this context, trained DNNs can be seen as a kind of end-to-end RL approach, where the agent can learn a state abstraction and a policy approximation directly from its input data. Following this approach, we implemented a DNN to solve the Cart-Pole problem.

Our journey in Deep Learning with TensorFlow ends here. Deep learning is a very productive research area; there are many books, courses, and online resources that may help the reader to go deeper into the theory and programming. In addition, TensorFlow provides a rich set of tools for working with deep learning models. I would like the reader of this book to be a part of the TensorFlow community, which is very active and expects enthusiastic people to join them soon.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset