From: Aadarsh on 25 Mar 2010 15:55 in libSVM, do you have to give a test label for each of the instances you want to test with? What if you have no idea on the class - this will reduce the accuracey. Can libSVM not predict the class, or at least tell you which instances you got right? Out of the instances you guessed the class right, is there any chance to get an id of somesort of them, so you can do stuff with that? Thanks.
From: Pekka Kumpulainen on 26 Mar 2010 05:59 "Aadarsh " <imfromwales(a)hotmail.com> wrote in message <hogf3a$n6e$1(a)fred.mathworks.com>... > in libSVM, do you have to give a test label for each of the instances you want to test with? What if you have no idea on the class - this will reduce the accuracey. Can libSVM not predict the class, or at least tell you which instances you got right? > > Out of the instances you guessed the class right, is there any chance to get an id of somesort of them, so you can do stuff with that? > > Thanks. Not sure if I understand what you are after... svmpredict wants the labels of the test data to calculate the classification accuracy. If you use it to predict a completely new data set where you don't know the labels, you can give whatever labels, the calculated accuracy is meaningless anyway if the correct classes are not known. If you know the correct classes you can find the correct and false predictions by comparing the correct and predicted labels: correct_inds = predicted_label == testing_label_vector;
From: Aadarsh on 26 Mar 2010 13:02 "Aadarsh " <imfromwales(a)hotmail.com> wrote in message <hogf3a$n6e$1(a)fred.mathworks.com>... > in libSVM, do you have to give a test label for each of the instances you want to test with? What if you have no idea on the class - this will reduce the accuracey. Can libSVM not predict the class, or at least tell you which instances you got right? > > Out of the instances you guessed the class right, is there any chance to get an id of somesort of them, so you can do stuff with that? > > Thanks. Thanks for the reply! So how do you classify test data? I have used libsvm to train an svm on one image by storing data about the pixels within a 30x30 pixel box, around several points known to be either class 1 or class 0. I then have entered them into the svm, stating what class they are. I now am trying to use the trained model on a different image. I am sliding the same sized window over the image and recording the same set of features. Only this time I dont know what the classes of each window are (obviously, thats the whole point of the SVM!), so i make an arbitary vector of say 1's. Then i run the prediction and the svm says that it is 95% correct. I dont know how it can say that! I want to get the id of each window or something, so i can plot them over the original image and see whats going on. Thanks.
|
Pages: 1 Prev: Is it possible to label axis? Next: graph of cumulative functions |