Issues and Techniques in Pattern Classification

Similar documents
EEL 851: Biometrics. An Overview of Statistical Pattern Recognition EEL 851 1

Introduction to Machine Learning

Instance-based Learning CE-717: Machine Learning Sharif University of Technology. M. Soleymani Fall 2016

6.867 Machine learning

Linear, threshold units. Linear Discriminant Functions and Support Vector Machines. Biometrics CSE 190 Lecture 11. X i : inputs W i : weights

Principal Component Analysis -- PCA (also called Karhunen-Loeve transformation)

CSE 417T: Introduction to Machine Learning. Final Review. Henry Chai 12/4/18

ECE521 week 3: 23/26 January 2017

Chap 1. Overview of Statistical Learning (HTF, , 2.9) Yongdai Kim Seoul National University

6.036 midterm review. Wednesday, March 18, 15

Machine learning for pervasive systems Classification in high-dimensional spaces

Machine Learning 2nd Edition

Metric-based classifiers. Nuno Vasconcelos UCSD

Ridge Regression 1. to which some random noise is added. So that the training labels can be represented as:

L11: Pattern recognition principles

Focus was on solving matrix inversion problems Now we look at other properties of matrices Useful when A represents a transformations.

Linear Algebra Methods for Data Mining

MRC: The Maximum Rejection Classifier for Pattern Detection. With Michael Elad, Renato Keshet

Introduction to Machine Learning

Face Recognition Using Laplacianfaces He et al. (IEEE Trans PAMI, 2005) presented by Hassan A. Kingravi

9/26/17. Ridge regression. What our model needs to do. Ridge Regression: L2 penalty. Ridge coefficients. Ridge coefficients

Linear Discriminant Functions

Statistical Pattern Recognition

PCA & ICA. CE-717: Machine Learning Sharif University of Technology Spring Soleymani

SUPERVISED LEARNING: INTRODUCTION TO CLASSIFICATION

CS 6375 Machine Learning

Bayes Decision Theory - I

Machine Learning Lecture 3

Lecture 3: Pattern Classification. Pattern classification

Chemometrics: Classification of spectra

The Perceptron. Volker Tresp Summer 2014

Lecture 3: Statistical Decision Theory (Part II)

Introduction to machine learning and pattern recognition Lecture 2 Coryn Bailer-Jones

Classification: The rest of the story

ROBERTO BATTITI, MAURO BRUNATO. The LION Way: Machine Learning plus Intelligent Optimization. LIONlab, University of Trento, Italy, Apr 2015

Linear Model Selection and Regularization

Machine Learning. Lecture 9: Learning Theory. Feng Li.

Notes on Discriminant Functions and Optimal Classification

Linear & nonlinear classifiers

Soft and hard models. Jiří Militky Computer assisted statistical modeling in the

Cheng Soon Ong & Christian Walder. Canberra February June 2018

Bagging and Other Ensemble Methods

Clustering VS Classification

Comparison of Modern Stochastic Optimization Algorithms

Advanced Methods for Fault Detection

ARTIFICIAL NEURAL NETWORKS گروه مطالعاتي 17 بهار 92

Bayesian decision theory Introduction to Pattern Recognition. Lectures 4 and 5: Bayesian decision theory

PRINCIPAL COMPONENTS ANALYSIS

Pattern Recognition 2

The Perceptron. Volker Tresp Summer 2016

Classifier Evaluation. Learning Curve cleval testc. The Apparent Classification Error. Error Estimation by Test Set. Classifier

Introduction to Machine Learning. PCA and Spectral Clustering. Introduction to Machine Learning, Slides: Eran Halperin

MACHINE LEARNING ADVANCED MACHINE LEARNING

Classification. The goal: map from input X to a label Y. Y has a discrete set of possible values. We focused on binary Y (values 0 or 1).

Lecture 3. STAT161/261 Introduction to Pattern Recognition and Machine Learning Spring 2018 Prof. Allie Fletcher

SVM TRADE-OFF BETWEEN MAXIMIZE THE MARGIN AND MINIMIZE THE VARIABLES USED FOR REGRESSION

INTRODUCTION TO PATTERN

CLUe Training An Introduction to Machine Learning in R with an example from handwritten digit recognition

Announcements. CS 188: Artificial Intelligence Spring Classification. Today. Classification overview. Case-Based Reasoning

Kernel-Based Principal Component Analysis (KPCA) and Its Applications. Nonlinear PCA

Assignment 3. Introduction to Machine Learning Prof. B. Ravindran

Machine Learning! in just a few minutes. Jan Peters Gerhard Neumann

Final Overview. Introduction to ML. Marek Petrik 4/25/2017

Machine Learning. Nonparametric Methods. Space of ML Problems. Todo. Histograms. Instance-Based Learning (aka non-parametric methods)

Wolf-Tilo Balke Silviu Homoceanu Institut für Informationssysteme Technische Universität Braunschweig

CMU-Q Lecture 24:

Probabilistic Methods in Bioinformatics. Pabitra Mitra

Decision Tree Learning

20 Unsupervised Learning and Principal Components Analysis (PCA)

Statistical Geometry Processing Winter Semester 2011/2012

CS534 Machine Learning - Spring Final Exam

Statistical Machine Learning

Unsupervised Learning: K- Means & PCA

Dimension Reduction Methods

ECE 521. Lecture 11 (not on midterm material) 13 February K-means clustering, Dimensionality reduction

Geometric Modeling Summer Semester 2010 Mathematical Tools (1)

When Dictionary Learning Meets Classification

Lecture 13. Principal Component Analysis. Brett Bernstein. April 25, CDS at NYU. Brett Bernstein (CDS at NYU) Lecture 13 April 25, / 26

Machine Learning for Software Engineering

Holdout and Cross-Validation Methods Overfitting Avoidance

Learning Theory Continued

COMP 551 Applied Machine Learning Lecture 13: Dimension reduction and feature selection

Machine Learning Concepts in Chemoinformatics

Pattern Recognition and Machine Learning. Learning and Evaluation of Pattern Recognition Processes

Iterative Laplacian Score for Feature Selection

CSE 417T: Introduction to Machine Learning. Lecture 11: Review. Henry Chai 10/02/18

Regularization. CSCE 970 Lecture 3: Regularization. Stephen Scott and Vinod Variyam. Introduction. Outline

DATA MINING LECTURE 10

ECE662: Pattern Recognition and Decision Making Processes: HW TWO

Machine Learning 2017

Beyond the Point Cloud: From Transductive to Semi-Supervised Learning

Learning Tetris. 1 Tetris. February 3, 2009

Linear & nonlinear classifiers

Lecture 24: Other (Non-linear) Classifiers: Decision Tree Learning, Boosting, and Support Vector Classification Instructor: Prof. Ganesh Ramakrishnan

Tutorial on Machine Learning for Advanced Electronics

Foundations of Machine Learning

Computer Vision Group Prof. Daniel Cremers. 3. Regression

M.S. Project Report. Efficient Failure Rate Prediction for SRAM Cells via Gibbs Sampling. Yamei Feng 12/15/2011

Uncorrelated Multilinear Principal Component Analysis through Successive Variance Maximization

Qualifying Exam in Machine Learning

Transcription:

Issues and Techniques in Pattern Classification Carlotta Domeniconi www.ise.gmu.edu/~carlotta Machine Learning Given a collection of data, a machine learner eplains the underlying process that generated the data in a general and simple fashion. Different learning paradigms: supervised learning unsupervised learning semi-supervised learning reinforcement learning

Supervised Learning Sample data comprises input vectors along with the corresponding target values (labeled data) Supervised learning uses the given labeled data to find a model (hypothesis) that predicts the target values for previously unseen data Supervised Learning: Classification Each element in the sample is labeled as belonging to some class (e.g., apple or orange). The learner builds a model to predict classes for all input data. There is no order among classes.

Classification Eample: Handwriting Recognition You've been given a set of N pictures of digits. For each picture, you're told the digit number Discover a set of rules which, when applied to pictures you've never seen, correctly identifies the digits in those pictures Supervised Learning: Regression Each element in the sample is associated with one or more continuous variables The learner builds a model to predict the value(s) for all input data Unlike classes, values have an order among them 3

Regression Eample: Automated Steering A CMU team trained a neural network to drive a car by feeding in many pictures of roads, plus the value according to which the graduate student was turning the steering wheel at the time. Eventually the neural network learned to predict the correct value for previously unseen pictures of roads. "No Hands Across America" Unsupervised Learning The given data consists of input vectors without any corresponding target values The goal is to discover groups of similar eamples within the data (clustering), or to determine the distribution of data within the input space (density estimation) 4

Clustering Goal: Grouping a collection of objects (data points) into subsets or clusters, such that those within each cluster are more closely related to one another than objects assigned to different clusters. Fundamental to all clustering techniques is the choice of distance or dissimilarity measure between two objects. 5

Semi-supervised learning In many data mining applications, unlabeled data are easily available, while labeled ones are epensive to obtain because they require human effort For eample: Web page classification; Contentbased image retrieval Semi-supervised learning is a recent learning paradigm: it eploits unlabeled eamples, in addition to labeled ones, to improve the generalization ability of the resulting classifier Reinforcement Learning The problem here is to find suitable actions to take in a given situation in order to maimize a reward Trial and error: no eamples of optimal outputs are given Trade-off between eploration (try new actions to see how effective they are) and eploitation (use actions that are known to give high reward) 6

A Classification Eample (from Pattern Classification by Duda & Hart & Stork Second Edition, 00) A fish-packing plant wants to automate the process of sorting incoming fish according to species As a pilot project, it is decided to try to separate sea bass from salmon using optical sensing 7

To solve this problem, we adopt a machine learning approach: We use a training set to tune the parameters of an adaptive model Length Lightness Width Position of the mouth Features to eplore for use in our classifier 8

Preprocessing: Images of different fishes are isolated from one another and from background; Feature etraction: The information of a single fish is then sent to a feature etractor, that measure certain features or properties ; Classification: The values of these features are passed to a classifier that evaluates the evidence presented, and build a model to discriminate between the two species Domain knowledge: a sea bass is generally longer than a salmon Feature: Length Model: Sea bass have some typical length, and this is greater than the length of a salmon 9

Classification rule: If Length >= l* then sea bass otherwise salmon How to choose l*? Use length values of sample data (training data) Histograms of the length feature for the two categories Leads to the smallest number of errors on average We cannot reliably separate sea bass from salmon by length alone! 0

New Feature: Average lightness of the fish scales Histograms of the lightness feature for the two categories Leads to the smallest number of errors on average The two classes are much better separated!

Histograms of the lightness feature for the two categories Classifying a sea bass as salmon costs more. Thus we reduce the number of sea bass classified as salmon. Our actions are equally costly In Summary: The overall task is to come up with a decision rule (i.e., a decision boundary) so as to minimize the cost (which is equal to the average number of mistakes for equally costly actions).

No single feature gives satisfactory results We must rely on using more than one feature We observe that: sea bass usually are wider than salmon Two features: Lightness and Width Resulting fish representation: = Decision rule: Classify the fish as a sea bass if its feature vector falls above the decision boundary shown, and as salmon otherwise Should we be satisfied with this result? 3

Options we have: Consider additional features: Which ones? Some features may be redundant (e.g., if eye color perfectly correlates with width, then we gain no information by adding eye color as feature.) It may be costly to attain more features Too many features may hurt the performance! Use a more comple model All training data are perfectly separated Should we be satisfied now?? We must consider: Which decisions will the classifier take on novel patterns, i.e. fish not yet seen? Will the classifier suggest the correct actions? This is the issue of GENERALIZATION 4

Generalization A good classifier should be able to generalize, i.e. perform well on unseen data The classifier should capture the underlying characteristics of the categories The classifier should NOT be tuned to the specific (accidental) characteristics of the training data Training data in practice contain some noise As a consequence: We are better off with a slightly poorer performance on the training eamples if this means that our classifier will have better performance on novel patterns. 5

The decision boundary shown may represent the optimal tradeoff between accuracy on the training set and on new patterns How can we determine automatically when the optimal tradeoff has been reached? Generalization The idea is to use a model with an intermediate compleity, which gets most of the points right, without putting too much trust in any individual point. The goal of statistical learning theory is to formalize these arguments by studying mathematical properties of learning machines, i.e. properties of the class of functions that the learning machine can implement (formalization of the compleity of the model). 6

Tradeoff between performance on training and novel eamples error Generalization error Error on training data Optimal compleity Compleity of the model Evaluation of the classifier on novel data is important to avoid over-fitting Eample: Regression Estimation ( ) t = sin π Data: input-output pairs Regularity: ( i, t i ) R R (, t ),, (, t ) drawn from L N N P (, t) Learning: choose a function error function is minimized f : R R such that a given 7

Polynomial Curve Fitting We fit the data using a polynomial function of the form: y M (, w) = w0 + w + w + L+ wm = It is linear in the unknown parameters: linear model M j= 0 w j j Fit the polynomial to the training data so that a given error function is minimized: E N ( w) = ( y( n, w) t n ) n= Polynomial Curve Fitting Geometrical interpretation of the sum-of-squares error function E N ( w) = ( y( n, w) t n ) n= 8

Polynomial Curve Fitting Model selection: We need to choose the order M of the polynomial: y M (, w) = w0 + w + w + L+ wm = M j= 0 w j j Over-fitting Polynomial Curve Fitting Model selection: we can investigate the dependence of the generalization performance on the order M * E( w ) N E RMS / = Root-mean-square error 9

Polynomial Curve Fitting We can also eamine the behavior of a given model as the size of the data set changes M = 9 For a given model, the over-fitting problem becomes less severe as the number of training data increases How to dodge the over-fitting problem? Assumption: we have a limited number of training data available, and we wish to use relatively comple and fleible models. One possible solution: add a penalty term to the error function to discourage the coefficients from reaching large values, e.g.: ~ E N = ( w) ( y(, w) ) n= n t n λ + w Sum of all squared coefficients This is an eample of a regularization technique. [shrinkage methods, ridge regression, weight decay] 0

The impact of Regularization N ~ λ E( w) = ( y( n, w) t n ) + w n= M = 9 The impact of Regularization N ~ λ E( w) = ( y( n, w) t n ) + w n= M = 9 λ controls the effective compleity of the model and hence determines the degree of over-fitting

Model selection Partition available data into a training set used to determine the coefficients w, and into a separate validation set (also called hold-out) used to optimize the M or λ model compleity ( ) If the model design is iterated several times using a limited number of data, some over-fitting to the validation data can occur. Solution: Set aside a third test set on which performance of the selected model is finally evaluated. Model selection Often we have limited data available, and we wish to use as much of the available data as possible for training to build good models. However, if we use a small set for validation, we obtain noisy estimates of predictive performance. One solution to this problem is cross-validation.

Cross-validation: Eample 4-fold cross-validation It allows to use ¾ of the available data for training, while making use of all of the data to assess performance k-fold Cross-validation In general: we perform k runs. Each run uses (k-)/k of the available data for training. If the number of data is very limited, we can set k=n (total number of data points). This gives the leave-oneout cross-validation technique. 3

k-fold Cross-validation: Drawbacks Computationally epensive: number of training runs is increased by a factor of k. A single models may have multiple compleity parameters: eploring combinations of settings could require a number of training runs that is eponential in the number of parameters. Curse of Dimensionality Real world applications deal with spaces with high dimensionality High dimensionality poses serious challenges for the design of pattern recognition techniques Oil flaw data in two dimensions Red = homogeneous Green = annular Blue = laminar 4

Curse of Dimensionality A simple classification approach Curse of Dimensionality Going higher in dimensionality 3 The number of regions of a regular grid grows eponentially with the dimensionality D of the space 3 3 3 5

Curse of Dimensionality DMAX DMAX/DMIN DMIN Sample of size N=500 uniformly distributed in q [0,] Curse of Dimensionality dim The distribution of the ratio DMAX/DMIN converges to as the dimensionality increases 6

Curse of Dimensionality dim Variance of distances from a given point Curse of Dimensionality dim The variance of distances from a given point converges to 0 as the dimensionality increases 7

Curse of Dimensionality Distance values from a given point Values flatten out as dimensionality increases Computing radii of nearest neighborhoods 8

median radius of a nearest neighborhood uniform distribution in the unit cube [-.5,.5] q Curse-of-Dimensionality As dimensionality increases, the distance from the closest point increases faster Random sample of size N ~ uniform distribution in the q-dimensional unit hypercube Diameter of a K = neighborhood using Euclidean / q distance: d( q, N) = O( N ) q 4 4 6 6 0 0 0 0 0 N 00 000 00 000 000 0000 0000 6 0 0 0 d(q,n) 0.4 0.3 0.7 0.48 0.9 0.7.5.0 0.76 Large d( q, N ) Highly biased estimations 9

Curse-of-Dimensionality In high dimensional spaces data become etremely sparse and are far apart from each other The curse of dimensionality affects any estimation problem with high dimensionality Curse-of-Dimensionality It is a serious problem in many real-world applications Microarray data: 3,000-4,000 genes; Documents: 0,000-0,000 words in dictionary; Images, face recognition,, etc. 30

How can we deal with the curse of dimensionality? Curse-of-Dimensionality Effective techniques applicable to high dimensional spaces eist. Real data are often confined to regions of lower dimensionality 3

3 9.5 9. 9. 7.68 ( )( ) [ ] ( ) ( ) ( )( ) ( )( ) ( ) ( ) ( )( ) ( )( ) ( ) = = µ µ µ µ µ µ = µ µ µ µ µ µ = µ µ µ µ = = µ µ = = N i i i i i i i T N i i N E E E N, : µ µ µ covariance matri

N N i i i ( µ ) ( µ )( µ ) i i i i= ( µ )( µ ) ( µ ) = variance covariance N N N N i i i ( µ ) [ ( µ )( µ )] N N i i i [ ( µ )( µ )] ( µ ) i= i= N i= N i= covariance variance 0.94 0.93 0.93.03 0.97 0.49 0.49.04 0.93 0.0 0.0.05 0.99 0.5 0.5.06.04.05.05.5 33

Dimensionality Reduction Many dimensions are often interdependent (correlated); We can: Reduce the dimensionality of problems; Transform interdependent coordinates into significant and independent ones; Principal Component Analysis -- PCA (also called Karhunen-Loeve transformation) PCA transforms the original input space into a lower dimensional space, by constructing dimensions that are linear combinations of the given features; The objective is to consider independent dimensions along which data have largest variance (i.e., greatest variability); 34

Principal Component Analysis -- PCA PCA involves a linear algebra procedure that transforms a number of possibly correlated variables into a smaller number of uncorrelated variables called principal components; The first principal component accounts for as much of the variability in the data as possible; Each succeeding component (orthogonal to the previous ones) accounts for as much of the remaining variability as possible. Principal Component Analysis -- PCA So: PCA finds n linearly transformed components s, s, L, s n so that they eplain the maimum amount of variance; We can define PCA in an intuitive way using a recursive formulation: 35

Principal Component Analysis -- PCA Suppose data are first centered at the origin (i.e., their mean is 0 ); We define the direction of the first principal component, say, as follows w w T w = arg ma E[( w ) w = where is of the same dimensionality q as the data vector Thus: the first principal component is the projection on the direction along which the variance of the projection is maimized. ] Principal Component Analysis -- PCA Having determined the first k- principal components, the k-th principal component is determined as the principal component of the data residual: T T wk = arg ma E{[ w ( wiwi )] w = i= The principal components are then given by: s i = w T i k } 36

Simple illustration of PCA First principal component of a two-dimensional data set. Simple illustration of PCA Second principal component of a two- dimensional data set. 37

PCA Geometric interpretation Basically: PCA rotates the data (centered at the origin) in such a way that the maimum variability is visible (i.e., aligned with the aes.) Eample: PCA does not always work 38

Eample Eample First principal component 39

Eample First principal component Eample First principal component Confused miture of samples from both classes 40

How to classify a new data point? First principal component How to classify a new data point? First principal component Points from both classes are intermingled. We cannot predict with accuracy the class of the new unlabeled point! 4

Can we find a better projection? How about the horizontal dimension? 4

How about the horizontal dimension? How about the horizontal dimension? Projected samples are well separated now 43

How to classify a new data point? Projected samples are well separated now How to classify a new data point? The new point is much closer to the red samples than to the green ones. Projected samples are well separated now 44

How to classify a new data point? The new point is much closer to the red samples than to the green ones. We can label the new point as red. Projected samples are well separated now What did we do? Find an orientation along which the projected samples are well separated; This is eactly the goal of linear discriminant analysis (LDA); In other words: we are after the linear projection that best separate the data, i.e. best discriminate data of different classes. 45

PCA vs. LDA Both PCA and LDA are linear techniques for dimensionality reduction: they project the data along directions that can be epressed as linear combination of the input features. The appropriate transformation depends on the data and on the task we want to perform on the data. Note that LDA uses class labels, PCA does not. Non-linear etensions of PCA and LDA eist (e.g., Kernel-PCA, generalized LDA). 46