From the course: Neural Networks and Convolutional Neural Networks Essential Training
Unlock the full course today
Join today to access over 22,600 courses taught by industry experts or purchase this course individually.
Building the Keras model
From the course: Neural Networks and Convolutional Neural Networks Essential Training
Building the Keras model
- [Instructor] So let's just visualize the model that we are trying to create, and remember that the reason that we're going from 784 nodes, that's the original number of pixels that we had, if you multiply 28 by 28. We then go down to 512 nodes in each of these layers, and then we need to go down to 10 nodes, because our output needs to be one of 10 digits, that's zero to nine, and that's why we end up with 10 nodes in our final output layer. So let's create our neural network, and we use that using Keras' sequential, so you call it model equals sequential, and then we're going to add the fully connected nodes, and we do that by using Keras' model add method, and we want to use a fully connected node, so we use dense. Now if you want to know the parameters that the dense mode is expecting, if we type a shift and a tab twice, you can see that it's expecting an output node. So we specify dense, we know that we're going to have 512 output nodes, we specify what activation function we…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
-
-
-
-
-
(Locked)
Understanding the components in Keras2m 12s
-
(Locked)
Setting up a Microsoft account on Azure1m 57s
-
(Locked)
Introduction to MNIST5m 33s
-
(Locked)
Preprocessing the training data4m 38s
-
(Locked)
Preprocessing the test data1m 58s
-
(Locked)
Building the Keras model2m 23s
-
(Locked)
Compiling the neural network model2m 18s
-
(Locked)
Training the neural network model1m 27s
-
(Locked)
Accuracy and evaluation of the neural network model2m 4s
-
(Locked)
-
-
-
-
-