how to classify an image

1 次查看(过去 30 天)
Pat
Pat 2013-12-30
I am working on classification of images,i have 500 categories of images with 8 images for each category,i need to use a classification algorithm,i like to use knn classifier or svm ,I have extracted features of those 96 images,say mean value so i have 500x8,from this can u tell how to classify the images,does normal classification can be done,its Polyu database of palmprint,kindly help

回答(1 个)

Walter Roberson
Walter Roberson 2013-12-30
I would not advise svm for this. multi-class svm is time consuming and memory consuming. More efficient than multi-class svm is to do ceiling(log2(N)) svm's where N is the number of classes. e.g., (category 1 to 250, vs 251 to 500), select the "winner", subdivide it into two pieces, and so on dividing into two until you get to the point where the "winning" side only had a population of 1 category.
knn or the like is more likely to give you a one-step answer -- but it won't necessarily be the most accurate answer if some of the possibilities are similar.
  2 个评论
Pat
Pat 2013-12-30
ceiling(log2(N)) gives error as Undefined function 'ceiling' for input arguments of type 'double'.
I have divided the data into training and testing
can you tell how to find accuracy of the test data say i have used 80 % for training and 20 % for testing using knn classifier
Walter Roberson
Walter Roberson 2013-12-30
ceiling(log2(N)) is mathematical description, not code. The MATLAB code is
ceil(log2(N))
The calculation is an upper bound on the number of svm() calls you will need to make in order to determine which class any given point belongs to.
Accuracy of your test data is 100 * (number of test entries your classifier correctly classifies) / (total number of test entries)

请先登录,再进行评论。

类别

Help CenterFile Exchange 中查找有关 Classification 的更多信息

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by