Font Size: a A A

Research On Impurity Segmentation Method Of Chinese Cabbage Based On U-net And Clustering

Posted on:2024-07-15Degree:MasterType:Thesis
Country:ChinaCandidate:K X LiuFull Text:PDF
GTID:2531307178978679Subject:Engineering
Abstract/Summary:PDF Full Text Request
With the improvement of people’s living standards,the quality and safety of agricultural products are widely concerned.During the harvesting and processing of Chinese cabbage,various impurities will inevitably be mixed,which will affect the sensory quality of Chinese cabbage and bring safety risks to human health.Therefore,it is necessary to remove impurities in time.Impurity detection is an important prerequisite for the removal of impurities in Chinese cabbage.Traditional impurity detection mainly relies on manual visual inspection,which has high labor intensity and low detection efficiency.A new method for the detection of impurities in Chinese cabbage is urgently needed to meet the needs of automatic detection of impurities in the packaging production line of Chinese cabbage.In view of the above problems,this paper takes the segmentation and extraction of common impurities in Chinese cabbage as the research object,and uses the traditional image segmentation method represented by clustering and the semantic segmentation method based on deep learning represented by U-net to study the automatic detection method of Chinese cabbage impurities.The main research contents and results are as follows:(1)A segmentation method of Chinese cabbage impurity image based on SSA-Kmeans clustering algorithm is proposed.Aiming at the problem that the traditional K-means clustering algorithm is affected by the initial clustering center,and the randomly selected clustering center is easy to fall into the local optimal solution,which leads to the unsatisfactory segmentation effect,the sparrow search algorithm is used to optimize the Kmeans clustering algorithm by using the powerful global optimization ability of the sparrow search algorithm,and a better segmentation effect of Chinese cabbage impurities is obtained.Fast and accurate impurity segmentation can be achieved for Chinese cabbage images containing single-type impurities.Compared with K-means clustering algorithm and other image segmentation algorithms,it has higher segmentation accuracy and good robust performance.(2)An image synthesis method based on binary mask is proposed and a semantic segmentation model of Chinese cabbage impurity image based on full convolutional neural network is optimized.Aiming at the problem that the traditional image segmentation method based on clustering can not meet the needs of diversified impurity detection,firstly,the image synthesis method based on binary mask is used to automatically synthesize the Chinese cabbage impurity image and its corresponding label image,which provides data support for semantic segmentation experiments.Then,the performance of classical semantic segmentation models such as U-Net,PSPNet and Deep Lab V3+ on the task of Chinese cabbage impurity segmentation is compared.Experiments show that the MIo U and MPA of Unet semantic segmentation model are 81.67% and 86.72% respectively,which is better than the other two models.Finally,Mobile Net V2 with the highest adaptability is selected as the backbone network for the U-net model to obtain better segmentation effect of Chinese cabbage impurities.(3)Construction of lightweight U-net Chinese cabbage impurity semantic segmentation network fusing coordinate attention.Aiming at the embedded application requirements of Chinese cabbage impurity detection,three improvement directions are proposed based on the original U-net model: introducing coordinate attention module,applying lightweight feature extraction network to optimize encoder,and applying deep separable convolution to optimize decoder.Experiments show that the three improved structures can effectively improve the semantic segmentation performance of U-net model on Chinese cabbage impurity images.The LU-net integrated with the three functional modules has a model parameter of 3.48 M,which is only 7.3% of the original U-net,meeting the lightweight design requirements.Compared with the real-time semantic segmentation model ENet,the segmentation accuracy has a great advantage.The MIo U and MPA are 87.49% and 94.02% respectively,which realizes the balance of segmentation accuracy and speed,and can run stably in embedded devices.The dataset comparison experiment based on LU-Net shows that the synthetic data helps to improve the segmentation performance of the model on real data.This research will provide technical reference for the on-line detection of impurities on the Chinese cabbage packaging production line,which is conducive to promoting the development of Chinese cabbage production in the direction of mechanization,automation and intelligence.
Keywords/Search Tags:Chinese cabbage, impurity detection, Kmeans clustering, U-net network, coordinate attention
PDF Full Text Request
Related items