As a common ingredient,wild mushrooms are rich in a variety of trace elements,and it can also boost people’s immunity,so they are deeply loved by people.However,in recent years,there have been frequent occurrences of wild mushrooms poisoning in China.The main reason is that the general public does not have the professional knowledge to identify wild mushrooms species,so it is easy to mistake the poisonous wild mushrooms for the edible wild mushrooms,which leads to poisoning by mistakenly eating poisonous wild mushrooms.At present,the existing wild mushroom identification methods have low universality,which is not conducive to popularization and use.Therefore,this thesis intends to develop a wild mushroom identification program,which uses deep learning technology to assist people in identifying wild mushroom species,thereby making a certain contribution to reducing the occurrence of domestic wild mushroom poisoning incidents,at the same time,it can also popularize knowledge about wild mushroom.The main works completed in this thesis are as follows:1.In view of the problem that there is no public wild mushroom image dataset in China,this thesis constructs an image dataset containing 28 wild mushroom species through two methods of field shooting and downloading pictures from the Internet.2.A wild mushroom classification model based on image saliency extraction and transfer learning is proposed.The model first introduced the EGNet algorithm to detect the saliency region of wild mushroom images,and then constructed a wild mushroom salient region extraction module,which used the binarized saliency map to remove part of the background of the original image.Second,a new Res Ne Xt50 output layer is written,and finally transfer learning is used to train the parameters of the model.Through the experimental results,it can be seen that the classification accuracy of the improved model reaches 92.79%,which is 2.34% higher than that of Res Ne Xt50 before the improvement.3.From the perspective of attention mechanism and feature pyramid,a wild mushrom classification model based on attention mechanism and feature fusion is proposed.For the existing wild mushroom classification model does not deal with the background of picture in the dataset,this thesis first uses channel attention to improve the residual block of Res Ne Xt50 to enhance the extraction of key channel features.Secondly,embedded the spatial attention mechanism,so that the Res Ne Xt50 model can pays more attention to the location of wild fungi in the image.At the same time,using the feature fusion and classification module,the features of different levels are fused to generate multi-scale features for classification.The experimental results show that the accuracy rate of the improved model reaches 94.28%,which is 3.83% higher than that of the previous model.4.In view of the fact that the existing wild mushroom identification methods do not fully utilize the features extracted by the model at all levels,an image classification model of wild mushroom based on multi-scale feature guidance and fusion is proposed in this thesis.Firstly,based on the latest Soft Pool method and pyramid pooling idea,a multiscale pooling module is constructed.Secondly,two feature fusion modules are designed to realize the fusion of features of different sizes.Finally,combined with the connection idea of the Dense Net network,the multi-scale pooled features are connected to other convolutional layers to guide the network for feature learning,and then integrate the fused features further to generate joint features for classification.Through the experimental results,it can be seen that the accuracy of the improved Res Ne Xt50 model has reached95.02%,which is 4.57% higher than the unmodified model,and it is also better than the existing wild mushroom identification and classification methods.5.Finally,based on the Flask framework and Gunicorn server,the wild mushroom recognition model with the highest recognition accuracy in this thesis is selected to write the back-end interface,and a We Chat applet with wild mushroom classification function is developed. |