Non-linear classifiers Neural networks

Slides:



Advertisements
Similar presentations
Image classification Given the bag-of-features representations of images from different classes, how do we learn a model for distinguishing them?
Advertisements

Object recognition and scene “understanding”
Thesis title: “Studies in Pattern Classification – Biological Modeling, Uncertainty Reasoning, and Statistical Learning” 3 parts: (1)Handwritten Digit.
Aula 5 Alguns Exemplos PMR5406 Redes Neurais e Lógica Fuzzy.
Scale Invariant Feature Transform (SIFT)
Overview of Back Propagation Algorithm
Machine learning Image source:
Machine learning Image source:
Handwritten digit recognition Jitendra Malik. Handwritten digit recognition (MNIST,USPS) LeCun’s Convolutional Neural Networks variations (0.8%, 0.6%
Yang, Luyu.  Postal service for sorting mails by the postal code written on the envelop  Bank system for processing checks by reading the amount of.
Recognition II Ali Farhadi. We have talked about Nearest Neighbor Naïve Bayes Logistic Regression Boosting.
Handwritten digit recognition
Human vision Jitendra Malik U.C. Berkeley. Visual Areas.
Object detection, deep learning, and R-CNNs
ECE 6504: Deep Learning for Perception Dhruv Batra Virginia Tech Topics: –(Finish) Backprop –Convolutional Neural Nets.
CSC321 Lecture 5 Applying backpropagation to shape recognition Geoffrey Hinton.
CSC321: 2011 Introduction to Neural Networks and Machine Learning Lecture 6: Applying backpropagation to shape recognition Geoffrey Hinton.
Object Recognition Tutorial Beatrice van Eden - Part time PhD Student at the University of the Witwatersrand. - Fulltime employee of the Council for Scientific.
Convolutional Neural Network
Xintao Wu University of Arkansas Introduction to Deep Learning 1.
Neural networks and support vector machines
an introduction to: Deep Learning
Lecture 07 13/12/2011 Shai Avidan הבהרה: החומר המחייב הוא החומר הנלמד בכיתה ולא זה המופיע / לא מופיע במצגת.
Sentence Modeling Representation of sentences is the heart of Natural Language Processing A sentence model is a representation and analysis of semantic.
Gradient-based Learning Applied to Document Recognition
Distinctive Image Features from Scale-Invariant Keypoints
ECE 5424: Introduction to Machine Learning
MIRA, SVM, k-NN Lirong Xia. MIRA, SVM, k-NN Lirong Xia.
Computer Science and Engineering, Seoul National University
Announcements Project proposal due tomorrow
CSCI 5922 Neural Networks and Deep Learning: Convolutional Nets For Image And Speech Processing Mike Mozer Department of Computer Science and Institute.
Object detection, deep learning, and R-CNNs
Recognition using Nearest Neighbor (or kNN)
Lecture 5 Smaller Network: CNN
Convolutional Networks
Shunyuan Zhang Nikhil Malik
CS6890 Deep Learning Weizhen Cai
R-CNN region By Ilia Iofedov 11/11/2018 BGU, DNN course 2016.
Object detection.
Recognition - III.
Introduction to Convolutional Neural Network (CNN/ConvNET)-insights from amateur George (Tian Zhou)
Computer Vision James Hays
Introduction to Neural Networks
Image Classification.
Outline Y. LeCun, L. Bottou, Y. Bengio, and P. Haffner, “Gradient-based learning applied to document recognition,” Proceedings of the IEEE, vol. 86, no.
Convolutional Neural Networks
Decision making in episodic environments
Very Deep Convolutional Networks for Large-Scale Image Recognition
Smart Robots, Drones, IoT
Convolutional neural networks Abin - Roozgard.
Object Classes Most recent work is at the object level We perceive the world in terms of objects, belonging to different classes. What are the differences.
CSC 578 Neural Networks and Deep Learning
Semantic segmentation
Neural network training
On Convolutional Neural Network
Visualizing and Understanding Convolutional Networks
Analysis of Trained CNN (Receptive Field & Weights of Network)
CSSE463: Image Recognition Day 18
Convolutional Neural Network
CSCI 5922 Neural Networks and Deep Learning: Convolutional Nets For Image And Speech Processing Mike Mozer Department of Computer Science and Institute.
SIFT SIFT is an carefully designed procedure with empirically determined parameters for the invariant and distinctive features.
An introduction to: Deep Learning aka or related to Deep Neural Networks Deep Structural Learning Deep Belief Networks etc,
Word representations David Kauchak CS158 – Fall 2016.
CS295: Modern Systems: Application Case Study Neural Network Accelerator Sang-Woo Jun Spring 2019 Many slides adapted from Hyoukjun Kwon‘s Gatech “Designing.
MIRA, SVM, k-NN Lirong Xia. MIRA, SVM, k-NN Lirong Xia.
VERY DEEP CONVOLUTIONAL NETWORKS FOR LARGE-SCALE IMAGE RECOGNITION
Semantic Segmentation
Image recognition.
Support Vector Machines 2
CSC 578 Neural Networks and Deep Learning
Presentation transcript:

Non-linear classifiers Neural networks

Linear classifiers on pixels are bad Solution 1: Better feature vectors Solution 2: Non-linear classifiers

A pipeline for recognition Compute image gradients Compute SIFT descriptors Assign to k-means centers Linear classifier Compute histogram Horse

Linear classifiers on pixels are bad Solution 1: Better feature vectors Solution 2: Non-linear classifiers

Non-linear classifiers Suppose we have a feature vector for every image

Non-linear classifiers Suppose we have a feature vector for every image Linear classifier

Non-linear classifiers Suppose we have a feature vector for every image Linear classifier Nearest neighbor: assign each point the label of the nearest neighbor

Non-linear classifiers Suppose we have a feature vector for every image Linear classifier Nearest neighbor: assign each point the label of the nearest neighbor Decision tree: series of if-then-else statements on different features

Non-linear classifiers Suppose we have a feature vector for every image Linear classifier Nearest neighbor: assign each point the label of the nearest neighbor Decision tree: series of if-then-else statements on different features Neural networks / multi-layer perceptrons

A pipeline for recognition Compute image gradients Compute SIFT descriptors Assign to k-means centers Linear classifier Compute histogram Horse

Multilayer perceptrons Key idea: build complex functions by composing simple functions Caveat: simple functions must include non- linearities W(U(Vx)) = (WUV)x Let us start with only two ingredients: Linear: y = Wx + b Rectified linear unit (ReLU, also called half-wave rectification): y = max(x,0)

The linear function y = Wx + b Parameters: W,b Input: x (column vector, or 1 data point per column) Output: y (column vector or 1 data point per column) Hyperparameters: Input dimension = # of rows in x Output dimension = # of rows in y W : outdim x indim b : outdim x 1

The linear function = y = Wx + b Every row of y corresponds to a hyperplane in x space din = dout The case when din = 2. A single row in y plotted for every possible value of x

Multilayer perceptrons Key idea: build complex functions by composing simple functions f(x) = Wx g(x) = max(x,0) f(x) = Wx g(x) = max(x,0) f(x) = Wx x y z 1 row of z plotted for every value of x 1 row of y plotted for every value of x

Multilayer perceptron on images An example network for cat vs dog Linear + ReLU Linear + ReLU Linear + sigmoid Reshape 256 65K p(dog | image) 256 32 1024

The linear function = y = Wx + b How many parameters does a linear function have? din = dout The case when din = 2. A single row in y plotted for every possible value of x

The linear function for images W 1024 65K 65K

Reducing parameter count W

Reducing parameter count

Idea 1: local connectivity Pixels only related to nearby pixels

Idea 2: Translation invariance Pixels only related to nearby pixels Weights should not depend on the location of the neighborhood

Linear function + translation invariance = convolution Local connectivity determines kernel size 5.4 0.1 3.6 1.8 2.3 4.5 1.1 3.4 7.2

Linear function + translation invariance = convolution Local connectivity determines kernel size Feature map 5.4 0.1 3.6 1.8 2.3 4.5 1.1 3.4 7.2

Convolution with multiple filters Feature map 5.4 0.1 3.6 1.8 2.3 4.5 1.1 3.4 7.2

Convolution over multiple channels * + * * = + *

Convolution as a primitive w h c c’ Convolution h w

Convolution as a feature detector score at (x,y) = dot product (filter, image patch at (x,y)) Response represents similarity between filter and image patch

Kernel sizes and padding

Kernel sizes and padding Valid convolution decreases size by (k-1)/2 on each side Pad by (k-1)/2! k Valid convolution (k-1)/2

The convolution unit Each convolutional unit takes a collection of feature maps as input, and produces a collection of feature maps as output Parameters: Filters (+bias) If cin input feature maps and cout output feature maps Each filter is k x k x cin There are cout such filters Other hyperparameters: padding

Invariance to distortions

Invariance to distortions

Invariance to distortions

Invariance to distortions: Pooling …

Invariance to distortions: Subsampling

Convolution subsampling convolution

Convolution subsampling convolution Convolution in earlier steps detects more local patterns less resilient to distortion Convolution in later steps detects more global patterns more resilient to distortion Subsampling allows capture of larger, more invariant patterns

Strided convolution Convolution with stride s = standard convolution + subsampling by picking 1 value every s values Example: convolution with stride 2 = standard convolution + subsampling by a factor of 2

Convolutional networks Horse

Convolutional networks Horse In contrast, if you look at the earlier layers, this particular unit here really likes a dark blob at a very precise location and scale in its field of view. If this unit fired, you will know exactly where the dark blob was. Unfortunately, this unit doesn’t care about the actual semantics of the dark blob: you will have no idea what the dark blob actually is. Visualizations from : M. Zeiler and R. Fergus. Visualizing and Understanding Convolutional Networks. In ECCV 2014.

Convolutional networks Horse If you look at what one of these higher layers is detecting, here I am showing the input image patches that are highly scored by one of the units. This particular layer really likes bicycle wheels, so if this unit fires, you know that there is a bicycle wheel in the image. Unfortunately, you don’t know where the bicycle wheel is, because this unit doesn’t care where the bicycle wheel appears, or at what orientation or what scale. Visualizations from : M. Zeiler and R. Fergus. Visualizing and Understanding Convolutional Networks. In ECCV 2014.

Convolutional Networks and the Brain Slide credit: Jitendra Malik

Receptive fields of simple cells (discovered by Hubel & Wiesel) Slide credit: Jitendra Malik

Convolutional networks Yann LeCun, Léon Bottou, Yoshua Bengio, and Patrick Haffner. Gradient-based learning applied to document recognition. Proceedings of the IEEE 86.11 (1998): 2278-2324.

Convolutional networks

Convolutional networks subsample conv subsample linear filters filters weights