Understanding Neural Networks

Neural networks(NN)

Understanding the representation

  • Input layer — It is used to pass in our input(an image, text or any suitable type of data for NN).
  • Hidden Layer — These are the layers in between the input and output layers. These layers are responsible for learning the mapping between input and output. (i.e. in the dog and cat gif above, the hidden layers are the ones responsible to learn that the dog picture is linked to the name dog, and it does this through a series of matrix multiplications and mathematical transformations to learn these mappings).
  • Output Layer — This layer is responsible for giving us the output of the NN given our inputs.

The engine of Neural Networks:

All rights reserved to Deep learning with python by François Chollet
  • Take a fixed batch of training samples x and corresponding targets y.
  • Run the network on x (a step called forward pass) to obtain predictions y_pred.
  • Calculate the loss of the network on the batch, a measure of the distance between y_pred and y (loss function also called objective function= y_pred -y).
  • Update all weights of the network in a way that slightly reduces the loss on this batch.

“Learning means finding the set of values for the weights of all layers in a network, such that the network will correctly map example inputs to their associated targets.”

“These are simple mechanisms that, once scaled, ends up looking like magic.”

The first step in the right direction

Example of training an NN

“To succeed, one must be creative and persistent.” — John H. Johnson

From theory to practice

All rights reserved to Deep learning with python by François Chollet
  1. Load the MNIST dataset in Keras
All rights reserved to Deep learning with python by François Chollet
All rights reserved to Deep learning with python by François Chollet

CHALLENGE

References

--

--

--

Computer Engineering Student, Web Dev. & AI/ML dev

Love podcasts or audiobooks? Learn on the go with our new app.

Recommended from Medium

The Need for Real-time Contextual Awareness in Enterprise Chatbots

How to derive the core features of a chatbot

Can AI Take Over Cognitive Jobs? Will Robots Take Over Human Jobs?

FlexiGAN: An End-to-End Solution for FPGA Acceleration of Generative Adversarial Networks

Is Ethical AI Even Possible?

Intriguing Benefits of AI for Digital Marketers

When and where will we enter the metaverse?

What to expect from AI and Machine Learning in 2017

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Prince Canuma

Prince Canuma

Computer Engineering Student, Web Dev. & AI/ML dev

More from Medium

CNN for Autonomous Driving

CONVOLUTION NEURAL NETWORKS(CNN)- All you need to know

Types of Neural Networks And Their Classification

The concepts of Deep Learning, Neural Networks, Linear regression