Classification of fruits using computer vision and a multiclass support vector machine

Sensors (Basel). 2012;12(9):12489-505. doi: 10.3390/s120912489. Epub 2012 Sep 13.

Abstract

Automatic classification of fruits via computer vision is still a complicated task due to the various properties of numerous types of fruits. We propose a novel classification method based on a multi-class kernel support vector machine (kSVM) with the desirable goal of accurate and fast classification of fruits. First, fruit images were acquired by a digital camera, and then the background of each image was removed by a split-and-merge algorithm; Second, the color histogram, texture and shape features of each fruit image were extracted to compose a feature space; Third, principal component analysis (PCA) was used to reduce the dimensions of feature space; Finally, three kinds of multi-class SVMs were constructed, i.e., Winner-Takes-All SVM, Max-Wins-Voting SVM, and Directed Acyclic Graph SVM. Meanwhile, three kinds of kernels were chosen, i.e., linear kernel, Homogeneous Polynomial kernel, and Gaussian Radial Basis kernel; finally, the SVMs were trained using 5-fold stratified cross validation with the reduced feature vectors as input. The experimental results demonstrated that the Max-Wins-Voting SVM with Gaussian Radial Basis kernel achieves the best classification accuracy of 88.2%. For computation time, the Directed Acyclic Graph SVMs performs swiftest.

Keywords: Unser's texture analysis; color histogram; fruit classification; kernel SVM; mathematical morphology; multi-class SVM; principal component analysis; shape feature; stratified cross validation.

MeSH terms

  • Fruit / classification*
  • Image Processing, Computer-Assisted / methods*
  • Principal Component Analysis / methods
  • Software
  • Support Vector Machine*