5.0 / 5
We will cover the following tasks in 31 minutes:
In this introductory task, we will discuss Neural Networks. I’ll give you a quick history of Machine Learning. I’ll introduce you to the Rhyme Interface, and finally share a little bit about myself.
In this task, we will start by looking at a visual representation of a Tensor. A Tensor is a lot like a multi-dimensional array. We will then move on to create 60,000 Tensors, each with a shape corresponding to our image size in order to create our dataset. We will do this by using the array_reshape function in Keras.
One Hot Encoding
ML algorithms generally need categorical data in what are called “One Hot” encodings. In this encoding, numeric class representations are converted to label vectors whose dimension correspond to the total number of classes given in the dataset. In this task, I will show you how to encode our labels in such a way with a simple function.
Building the Model
In this task we are going to build the architecture for the model. We will be using ReLU (Rectified Linear Unit) activation function, which is one of the most used activation functions right now in Deep Learning, on our hidden layers. We will use the Softmax function as the final layer activations of our neural network-based classifier, which is also very popular when it comes to classifiers. Let’s see how this is done!
Loss Optimizer and Model Run
We need to use a loss optimizer so we can spot when the model starts over-fitting to the training data. We will be using a categorical cross-entropy loss function as our loss function - this is representative of the mistakes the model makes in predicting labels over the training data. Cross-entropy loss increases as the predicted probability diverges from the actual label. As the model trains, an optimization algorithm will gradually adjust values of the model’s internal parameters to try and decrease this loss value, thereby making better predictions.
Test Data and Summary
In this task we will see how the model performs on data it hasn’t seen or hasn’t been trained on. After we test the model, I will run through everything we have learned in this project and we can get on with our next project.