Book Image

The Deep Learning with Keras Workshop

By : Matthew Moocarme, Mahla Abdolahnejad, Ritesh Bhagwat
1 (1)
Book Image

The Deep Learning with Keras Workshop

1 (1)
By: Matthew Moocarme, Mahla Abdolahnejad, Ritesh Bhagwat

Overview of this book

New experiences can be intimidating, but not this one! This beginner’s guide to deep learning is here to help you explore deep learning from scratch with Keras, and be on your way to training your first ever neural networks. What sets Keras apart from other deep learning frameworks is its simplicity. With over two hundred thousand users, Keras has a stronger adoption in industry and the research community than any other deep learning framework. The Deep Learning with Keras Workshop starts by introducing you to the fundamental concepts of machine learning using the scikit-learn package. After learning how to perform the linear transformations that are necessary for building neural networks, you'll build your first neural network with the Keras library. As you advance, you'll learn how to build multi-layer neural networks and recognize when your model is underfitting or overfitting to the training data. With the help of practical exercises, you’ll learn to use cross-validation techniques to evaluate your models and then choose the optimal hyperparameters to fine-tune their performance. Finally, you’ll explore recurrent neural networks and learn how to train them to predict values in sequential data. By the end of this book, you'll have developed the skills you need to confidently train your own neural network models.
Table of Contents (11 chapters)
Preface

Life Cycle of Model Creation

In this section, we will cover the life cycle of creating performant machine learning models, from engineering features to fitting models to training data, and evaluating our models using various metrics. The following diagram demonstrates the iterative process of building machine learning models. Features are engineered that represent potential correlations between the features and the target, the model is fit, and then models are evaluated.

Depending on how the model is scored according to the model's evaluation metrics, the features are engineered further, and the process continues. Many of the steps that are implemented to create models are highly transferable between all machine learning libraries. We'll start with scikit-learn, which has the advantage of being widely used, and as such, there is a lot of documentation, tutorials, and learning materials to be found across the internet:

Figure 1.22: The life cycle of model creation

Figure 1.22: The life cycle of model creation

Machine Learning Libraries

While this book is an introduction to deep learning with Keras, as we mentioned earlier, we will start by utilizing scikit-learn. This will help us establish the fundamentals of building a machine learning model using the Python programming language.

Similar to scikit-learn, Keras makes it easy to create models in the Python programming language through an easy-to-use API. However, the goal of Keras is the creation and training of neural networks, rather than machine learning models in general. ANNs represent a large class of machine learning algorithms, and they are so-called because their architecture resembles the neurons in the human brain. The Keras library has many general-purpose functions built-in, such as optimizers, activation functions, and layer properties, so that users, like in scikit-learn, do not have to code these algorithms from scratch.