智慧农业 (Mar 2021)
Detection and Grading Method of Pomelo Shape Based on Contour Coordinate Transformation and Fitting
Abstract
Automatic grading method of pomelo fruit according to the shape and size is urgently needed in the industry since the work mainly depends on artificial judgment currently. In this research, a method, which detected the vertical and horizontal size of pomelo by using contour coordinate transformation fitting, fruit shape feature extraction and direction angle compensation algorithm, while it determined the shape defects based on fruit shape index, was proposed. The image acquisition system was self-designed and built up with a CMOS camera, a dot matrix LED light source, a plane mirror, the computer, a box and brackets. The image data containing whole surface information of Shatian pomelo samples with different sizes and shapes were collected by this system. The G-B component grayscale image was chosen for denoising and segmentation. The Laplacian edge detection algorithm was implemented to extract the edge pixels of the fruit. The polynomial fitting method was applied to converse the rectangular coordinates to polar coordinates so that the fruit shape description was simplified. The characteristic point polar angle value was used to compensate the random direction of the vertical and horizontal diameters of the sample. Then the vertical and horizontal diameters of fruit were calculated after classifying the sample shapes into the spherical and the pear-like categories. For the involved 168 pomelo samples, the average error, maximum absolute error and average relative error of the vertical diameters were 2.23 mm, 7.39 mm and 1.6% respectively, while these parameters of the horizontal diameters were 2.21 mm, 7.66 mm and 1.4% respectively. The fruit shape discriminant model was established by using BP neural network algorithm based on the seven features extracted from the fitting function and verified by independent validation set including 3 peak heights, 3 peak widths and 1 trough value difference. The total recognition rate of shape identification was 83.7%. The results illustrated that the method had the potential to measuring the pomelo size and shape for grading fast and non-destructively.
Keywords