Research of impurity detection of green vegetable based on improved Mask R-CNN
The intelligent packaging and processing of green leafy vegetables is an important part of realizing intelligent production of green leafy vegetables and reducing production costs.The detection of impurities in the packaging of green leafy vegetables is an important prerequisite.Taking vegetables as the research object,this paper proposes a vegetable impurity detection model based on Mask R-CNN.Firstly,more than 1 370 cabbage images were collected and labeled with 3 kinds of common impurities,including withered leaves,withered leaves and shredded paper.The data set containing 2 740 cabbage impurity images was expanded by the method of data enhancement.In order to reduce the influence of background on impurity detection,this paper add a coordinated attention mechanism,a fully connected layer and Dropout layer to the Mask R-CNN model,reduce over fitting and fine tune the model using transfer learning methods.The results show that the average accuracy of the improved Mask R-CNN algorithm for the identification of vegetable impurities is 99.19%,the detection speed is 8.45 FPS,and the detection effect is good,which can meet the detection requirements of vegetable impurities.
green vegetablesimpurity detectionMask R-CNNtransfer learningcoordinate attention