Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Please answer in MATLAB 3 Training an SVM Classifier (40 points) Let g(x;, ) indicate the probability density function (pdf) of a Gaussian random vector

image text in transcribed

Please answer in MATLAB

3 Training an SVM Classifier (40 points) Let g(x;, ) indicate the probability density function (pdf) of a Gaussian random vector with mean and covariance matrix . Write code that implements the following 0.5 . Generate N;ran 100 samples from p(x:0)-Adx; (8), (00)) +Ag(x; (3), (11)) + 3g(x; (1) (H) ) with (0 25). Label 0.25 the samples that originate from Component 1 (with mean at the origin) as coming from class +1, and the remaining samples as coming from class -1 For a support vector machine classifier that uses spherically symmetric Gaussian kernels with width parameter , use K-fold cross validation to determine the best kernel parameter and the overlap penalty term weight parameter (referred to as C in class), in order to achieve minimum empirical probability of error estimate as the cross-validation objective Using the best hyper parameters and C, train a final SVM on the entire data set . Generate Niest10000 samples from the same GMM that generated the training set, and assign labels in the same way. This large test data set is independent from and is identically distributed to our training set that was used to train the SVM classifier. We can use it to assess test (generalization) performance Apply the trained SVM to classify the test samples and report the following results (1) empirical probability of error estimate on the test set; (2) a single plot that shows the following (a) all test data, each sample colored green if correctly classified xor red if incorrectly classified by the SVM; (b) the decision boundary of the SVM overlaid on the data. 3 Training an SVM Classifier (40 points) Let g(x;, ) indicate the probability density function (pdf) of a Gaussian random vector with mean and covariance matrix . Write code that implements the following 0.5 . Generate N;ran 100 samples from p(x:0)-Adx; (8), (00)) +Ag(x; (3), (11)) + 3g(x; (1) (H) ) with (0 25). Label 0.25 the samples that originate from Component 1 (with mean at the origin) as coming from class +1, and the remaining samples as coming from class -1 For a support vector machine classifier that uses spherically symmetric Gaussian kernels with width parameter , use K-fold cross validation to determine the best kernel parameter and the overlap penalty term weight parameter (referred to as C in class), in order to achieve minimum empirical probability of error estimate as the cross-validation objective Using the best hyper parameters and C, train a final SVM on the entire data set . Generate Niest10000 samples from the same GMM that generated the training set, and assign labels in the same way. This large test data set is independent from and is identically distributed to our training set that was used to train the SVM classifier. We can use it to assess test (generalization) performance Apply the trained SVM to classify the test samples and report the following results (1) empirical probability of error estimate on the test set; (2) a single plot that shows the following (a) all test data, each sample colored green if correctly classified xor red if incorrectly classified by the SVM; (b) the decision boundary of the SVM overlaid on the data

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Introduction To Data Mining

Authors: Pang Ning Tan, Michael Steinbach, Vipin Kumar

1st Edition

321321367, 978-0321321367

More Books

Students also viewed these Databases questions

Question

1. How do most insects respire ?

Answered: 1 week ago

Question

Who is known as the father of the indian constitution?

Answered: 1 week ago

Question

1.explain evaporation ?

Answered: 1 week ago

Question

Who was the first woman prime minister of india?

Answered: 1 week ago