Machine Vision Grading of Pistachio Nuts Using Fourier Descriptors

Abstract A machine vision system was used to classify pistachio nuts into four grades designated as “Grade 1”, “Grade 2”, “Grade 3” and “unsplit”, respectively. Fourier descriptors and the projected area (pixel count) of the individual nuts were extracted from their two-dimensional images and used as recognition features. The Fisher criterion for feature selection was used in conjunction with the Gaussian classification method to select a subset of the Fourier descriptors from an initial set of 15 harmonics. The results of this feature selection indicated that seven harmonics were sufficient for this classification problem. The selected Fourier descriptors and the area of each nut were subsequently used as inputs to two classification schemes: a hybrid decision-tree classifier and a feedforward neural network trained by back-propagation. The average classification accuracy obtained for the decision-tree classifier was 87·1%. The neural-network classifier resulted in an average classification accuracy of 94·8%, indicating the superiority of the neural-network approach for machine vision grading of these nuts.