Autoencoders Tutorial _ What Are Autoencoders_ _ Edureka
Autoencoders Tutorial _ What Are Autoencoders_ _ Edureka
| Edureka
Sayantini
A Data Science Enthusiast with in-hand skills in programming languages such as...
Arti cial Intelligence encircles a wide range of technologies and techniques that enable computer systems to solve problems like
Data Compression which is used in computer vision, computer networks, computer architecture, and many other
elds. Autoencoders are unsupervised neural networks that use machine learning to do this compression for us. This
Autoencoders Tutorial will provide you with a complete insight into autoencoders in the following sequence:
Let’s begin with the most fundamental and essential question, What are autoencoders?
We have a similar machine learning algorithm ie. PCA which does the same task. So you might be thinking why do we need
Autoencoders then? Let’s continue this Autoencoders Tutorial and nd out the reason behind using Autoencoders.
YouTube 2M
Applications of Autoencoders
https://www.edureka.co/blog/autoencoders-tutorial/ 1/10
9/4/2020 Autoencoders Tutorial | What are Autoencoders? | Edureka
Image Coloring
Feature variation
It extracts only the required features of an image and
generates the output by removing any noise or
unnecessary interruption.
Dimensionality Reduction
The reconstructed image is the same as our input but
with reduced dimensions. It helps in providing the
similar image with a reduced pixel value.
Denoising Image
The input seen by the autoencoder is not the raw input
Watermark Removal
Architecture of Autoencoders
An Autoencoder consist of three layers:
1. Encoder
2. Code
3. Decoder
https://www.edureka.co/blog/autoencoders-tutorial/ 2/10
9/4/2020 Autoencoders Tutorial | What are Autoencoders? | Edureka
Explore Curriculum
Encoder: This part of the network compresses the input into a latent space representation. The encoder
layer encodes the input image as a compressed representation in a reduced dimension. The compressed image is the
distorted version of the original image.
Code: This part of the network represents the compressed input which is fed to the decoder.
Decoder: This layer decodes the encoded image back to the original dimension. The decoded image is a lossy
reconstruction of the original image and it is reconstructed from the latent space representation.
The layer between the encoder and decoder, ie. the code is also known as Bottleneck.
This is a well-designed approach to decide which aspects of observed data are relevant
information and what aspects can be discarded. It does this by balancing two criteria :
Now that you have an idea of the architecture of an Autoencoder. Let’s continue our Autoencoders Tutorial and understand the
di erent properties and the Hyperparameters involved while training Autoencoders.
Data-speci c: Autoencoders are only able to compress data similar to what they have been trained on.
Lossy: The decompressed outputs will be degraded compared to the original inputs.
https://www.edureka.co/blog/autoencoders-tutorial/ 3/10
9/4/2020 Autoencoders Tutorial | What are Autoencoders? | Edureka
Learned automatically from examples: It is easy to train specialized instances of the algorithm that will perform well on a
speci c type of input.
Hyperparameters of Autoencoders:
Code size: It represents the number of nodes in the middle layer. Smaller size
results in more compression.
Number of layers: The autoencoder can consist of as many layers as we want.
Number of nodes per layer: The number of nodes per layer decreases with
each subsequent layer of the encoder, and increases back in the decoder. The
decoder is symmetric to the encoder in terms of the layer structure.
Loss function: We either use mean squared error or binary cross-entropy. If
the input values are in the range [0, 1] then we typically use cross-entropy,
otherwise, we use the mean squared error.
Now that you know the properties and hyperparameters involved in the training of Autoencoders. Let’s move forward with our
Autoencoders Tutorial and understand the di erent types of autoencoders and how they di er from each other.
Types of Autoencoders
Convolution Autoencoders
Autoencoders in their traditional formulation does not take into account the fact that a signal can be seen as a sum of other
signals. Convolutional Autoencoders use the convolution operator to exploit this observation. They learn to encode the input in a
set of simple signals and then try to reconstruct the input from them, modify the geometry or the re ectance of the image.
Image Reconstruction
Image Colorization
latent space clustering
generating higher resolution images
Sparse Autoencoders
Sparse autoencoders o er us an alternative method for introducing an information bottleneck without requiring a reduction
in the number of nodes at our hidden layers. Instead, we’ll construct our loss function such that we penalize activations within a
layer.
https://www.edureka.co/blog/autoencoders-tutorial/ 4/10
9/4/2020 Autoencoders Tutorial | What are Autoencoders? | Edureka
NATURAL LANGUAGE
PROCESSING WITH GRAPHICAL MODELS
AI & DEEP LEARNING REINFORC
PYTHON CERTIFICATION
WITH TENSORFLOW LEARNING
CERTIFICATION TRAINING
COURSE
Natural Language
AI & Deep Learning with Graphical Models
Processing with Python Reinforcement Lea
TensorFlow Certi cation Training
Certi cation Course
Reviews Reviews Reviews Reviews
Deep Autoencoders
The extension of the simple Autoencoder is the Deep Autoencoder. The rst layer of the Deep Autoencoder is used for rst-
order features in the raw input. The second layer is used for second-order features corresponding to patterns in the
appearance of rst-order features. Deeper layers of the Deep Autoencoder tend to learn even higher-order features.
1. First four or ve shallow layers representing the encoding half of the net.
2. The second set of four or ve layers that make up the decoding half.
Image Search
Data Compression
Topic Modeling & Information Retrieval (IR)
Contractive Autoencoders
A contractive autoencoder is an unsupervised deep learning technique that helps a neural network encode unlabeled training
data. This is accomplished by constructing a loss term which penalizes large derivatives of our hidden layer activations with
respect to the input training examples, essentially penalizing instances where a small change in the input leads to a large
change in the encoding space.
https://www.edureka.co/blog/autoencoders-tutorial/ 5/10
9/4/2020 Autoencoders Tutorial | What are Autoencoders? | Edureka
Now that you have an idea of what Autoencoders is, it’s di erent types and it’s properties. Let’s move ahead with our
Autoencoders Tutorial and understand a simple implementation of it using TensorFlow in Python.
YouTube 2M
1 import numpy as np
2 from keras.layers import Input, Dense
3 from keras.models import Model
4 from keras.datasets import mnist
5 import matplotlib.pyplot as plt
https://www.edureka.co/blog/autoencoders-tutorial/ 6/10
9/4/2020 Autoencoders Tutorial | What are Autoencoders? | Edureka
1 autoencoder.fit(x_train, x_train,
2 epochs=50,
3 batch_size=256,
4 shuffle=True,
5 validation_data=(x_test, x_test))
6 # encode and decode some digits
7 # note that we take them from the *test* set
8 encoded_imgs = encoder.predict(x_test)
9 decoded_imgs = decoder.predict(encoded_imgs)
Visualizing the reconstructed inputs and the encoded representations using Matplotlib
Input
Output
Now with this, we come to an end to this Autoencoders Tutorial. I Hope you guys enjoyed this article and understood the power
of Tensor ow, and how easy it is to decompress images. So, if you have read this, you are no longer a newbie to Autoencoders.
Try out these examples and let me know if there are any challenges you are facing while deploying the code.
Autoencoders Tutorial using TensorFlow | Edureka
https://www.edureka.co/blog/autoencoders-tutorial/ 7/10
9/4/2020 Autoencoders Tutorial | What are Autoencoders? | Edureka
This video provides you with a brief introduction about autoencoders and how they compress unsupervised data.
Enroll Now
Now that you have understood the basics of Autoencoders, check out the AI and Deep Learning With Tensor ow by Edureka, a
trusted online learning company with a network of more than 250,000 satis ed learners spread across the globe. This
Certi cation Training is curated by industry professionals as per the industry requirements & demands. You will master concepts
such as SoftMax function, Autoencoder Neural Networks, Restricted Boltzmann Machine (RBM) and work with libraries like Keras
& TFLearn. Got a question for us? Please mention it in the comments section of “Autoencoders Tutorial” and we will get back to
you.
What Is Deep Learning – Deep Deep Learning Tutorial – Deep Introduction to Mahout
Learning Simpli ed Learning With TensorFlow
https://www.edureka.co/blog/autoencoders-tutorial/ 8/10
9/4/2020 Autoencoders Tutorial | What are Autoencoders? | Edureka
Object Detection Tutorial in Understanding Distance Most Frequently Asked Top 10 Machine Lea
TensorFlow: Real-Time Object Measures in Mahout Arti cial Intelligence Interview You Need to Know A
Detection Questions
‹›
Comments 0 Comments
‹›
Browse Categories
BI and Visualization Big Data Blockchain Cloud Computing Cyber Security Data Science Data Warehousing and ETL Databases
DevOps Digital Marketing Front End Web Development Mobile Development Operating Systems Programming & Frameworks
Project Management and Methodologies Robotic Process Automation Software Testing Systems & Architecture
https://www.edureka.co/blog/autoencoders-tutorial/ 9/10
9/4/2020 Autoencoders Tutorial | What are Autoencoders? | Edureka
TRENDING CERTIFICATION COURSES TRENDING MASTERS COURSES
Big Data Hadoop Certi cation Training Cloud Architect Masters Program
Tableau Training & Certi cation Big Data Architect Masters Program
Python Certi cation Training for Data Science Machine Learning Engineer Masters Program
Selenium Certi cation Training Full Stack Web Developer Masters Program
Robotic Process Automation Training using UiPath Data Analyst Masters Program
Apache Spark and Scala Certi cation Training Test Automation Engineer Masters Program
Microsoft Power BI Training Post-Graduate Program in Arti cial Intelligence & Machine Learning
Online Java Course and Training Post-Graduate Program in Big Data Engineering
About us Careers
Community
DOWNLOAD APP
Sitemap
Blog Sitemap
Community Sitemap
Webinars
CATEGORIES
CATEGORIES
Cloud Computing DevOps Big Data Data Science BI and Visualization Programming & Frameworks Software Testing
Project Management and Methodologies Robotic Process Automation Frontend Development Data Warehousing and ETL Arti cial Intelligence
Blockchain Databases Cyber Security Mobile Development Operating Systems Architecture & Design Patterns Digital Marketing
Spring tutorial PHP interview questions Inheritance in Java Polymorphism in Java Spring interview questions Pointers in C Linux commands
Android tutorial JavaScript tutorial jQuery tutorial SQL interview questions MySQL tutorial Machine learning tutorial Python tutorial
What is machine learning Ethical hacking tutorial SQL injection AWS certi cation career opportunities AWS tutorial What Is cloud computing
What is blockchain Hadoop tutorial What is arti cial intelligence Node Tutorial Collections in Java Exception handling in java
Python Programming Language Python interview questions Multithreading in Java ReactJS Tutorial Data Science vs Big Data vs Data Analyt…
Software Testing Interview Questions R Tutorial Java Programs JavaScript Reserved Words and Keywor… Implement thread.yield() in Java: Exam…
Implement Optical Character Recogniti… All you Need to Know About Implemen…
© 2020 Brain4ce Education Solutions Pvt. Ltd. All rights Reserved. Terms & Conditions
"PMP®","PMI®", "PMI-ACP®" and "PMBOK®" are registered marks of the Project Management Institute, Inc. MongoDB®, Mongo and the leaf logo are the registered trademarks of
MongoDB, Inc.
https://www.edureka.co/blog/autoencoders-tutorial/ 10/10