DSA5105 Lecture8
DSA5105 Lecture8
Soufiane Hayou
Department of Mathematics
So far
Until now, we have focused on supervised learning
• Datasets comes in input-label pairs
• Goal is to learn their relationship for prediction (the
oracle function)
(Oracle) Cat
Predictive Dog
Model
(Oracle) Cat
Dog
Example goal: learn some task-agnostic patterns from the input data
Examples of Unsupervised Learning
Tasks: Dimensionality Reduction
https://media.geeksforgeeks.org/wp-content/uploads/Dimensionality_Reduction_1.jpg
Examples of Unsupervised Learning
Tasks: Clustering
https://upload.wikimedia.org/wikipedia/commons/thumb/c/c8/Cluster-2.svg/1200px-Cluster-2.svg.png
Examples of Unsupervised Learning
Tasks: Density Estimation
http://www.lherranz.org/wp-content/uploads/2018/07/blog_generativesampling.png
Why unsupervised learning?
• Labelled data is expensive to collect
• Labelled data is impossible to get
• Different application scenarios
Principal Component Analysis
Review: Eigenvalues and Eigenvectors
• For a square matrix , an eigenvector with associated eigenvalue satisfies
Two
Formulations
Find the direction
that minimizes
projection error
Derivation of PCA
(Maximize Variance)
Derivation of PCA
(Minimize Error)
The PCA Algorithm
Simple Example
Choosing The Embedding Dimension
PCA in Feature Space (Example)
PCA in Feature Space
We define a vector of feature maps
Then, !
𝑍 𝑚 = 𝑋 𝑈𝑚 𝑋
𝑑𝑒𝑐𝑜𝑚𝑝 𝑇
= 𝑍𝑚𝑈 𝑀
Encoder Decoder
Latent
Autoencoders
In this sense, the autoencoder is a nonlinear counter-part of PCA
based compression!
PCA: 𝑍 𝑚 = 𝑋 𝑈𝑚 ∗
𝑋 =𝑍 𝑚 𝑈 𝑚
𝑇
∗
AE: 𝑍 𝑚 =𝑇 enc ( 𝑋 ;𝜃) 𝑋 =𝑇 dec ( 𝑍 𝑚 ; 𝜙 )
Neural Network Autoencoders
How do we pick the encoding and decoding and
where
Neural Network Autoencoders
Given a dataset , we solve the empirical risk minimization to
minimize the distance between and