Search icon
Arrow left icon
All Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletters
Free Learning
Arrow right icon
Hands-On Neural Networks with Keras

You're reading from  Hands-On Neural Networks with Keras

Product type Book
Published in Mar 2019
Publisher Packt
ISBN-13 9781789536089
Pages 462 pages
Edition 1st Edition
Languages
Author (1):
Niloy Purkait Niloy Purkait
Profile icon Niloy Purkait

Table of Contents (16) Chapters

Preface Section 1: Fundamentals of Neural Networks
Overview of Neural Networks A Deeper Dive into Neural Networks Signal Processing - Data Analysis with Neural Networks Section 2: Advanced Neural Network Architectures
Convolutional Neural Networks Recurrent Neural Networks Long Short-Term Memory Networks Reinforcement Learning with Deep Q-Networks Section 3: Hybrid Model Architecture
Autoencoders Generative Networks Section 4: Road Ahead
Contemplating Present and Future Developments Other Books You May Enjoy

Building a network

The first architectural constraints that you must consider while building a network with dense layers are its the depth and width. Then, you need to define an input layer with the appropriate shape, and successively choose from different activation functions to use per layer.

As we did for our MNIST example, we simply import the sequential model and the dense layer structure. Then we proceed by initializing an empty sequential model and progressively add hidden layers until we reach the output layer. Do note that our input layer always requires a specific input shape, which for us corresponds to the 12,000 - dimensional one-hot encoded vectors that we will be feeding it. In our current model, the output layer only has one neuron, which will ideally fire if the sentiment in a given review is positive; otherwise, it won't. We will choose Rectified Linear...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $15.99/month. Cancel anytime}