# Image Classification of Pests with Residual Neural Network Based on Transfer Learning
## 5 Conclusions  
Since the traditional pest classification method has many problems such as hard feature extraction and small size of data sample, the transfer learning method and a residual CNN were adopted in this study to classify the IP102 pest dataset, and the influence of factors on the model performance such as the learning method, data enhancement and learning rate was compared and analyzed. The conclusions are drawn as follows:  
1. Compared with other CNNs, the residual CNN can achieve better extraction of pest features. Compared with other research results, it has better classification performance with the average recognition accuracy as high as more than 70%;
2. Learning rate has a greater influence than the data augmentation on model training stability. The selection of appropriate learning rate can expedite the model convergence so that the model can approach the optimal solution at a faster speed. When the new learning method is adopted, a larger learning rate should be adopted to expedite the learning speed of the model; when the transfer learning method is adopted, a small learning rate should be adopted to prevent the optimal solution being skipped. If an improper learning rate is selected, the training effect is greatly influenced, and the model even diverges in severe cases;
3. It is important to select the right data augmentation. Appropriate data augmentation can help models to better learn sample features and reduce the overfitting problems caused by small datasets. Basic data augmentation should be adopted when new learning is adopted. When the model has no pre-training \"knowledge\", an excessively complicated input interference prevents the models from learning basic features; when a combination of transfer learning + fine-tuning is adopted, it is recommended to use more complicated data enhancement (such as CutMix). If the model has pre-trained \"knowledge\", strong input interference can help the models learn deep features;
4. Transfer learning can help models learn generically featured \"knowledge\" from other datasets. Learning the target dataset based on this \"knowledge\" can greatly improve the model performance. The training time needed for the model to achieve the same classification accuracy is greatly reduced, and the average classification accuracy is improved by 10-20% compared to the new learning model;
5. The ability of transfer learning can be better exerted with fine-adjusting pre-training parameters than freezing pre-training parameters. Although the parameters of feature extraction in the transfer model are very close to the optimal solution, the fine-tuning is needed on this basis due to the differences between the datasets. According to the experimental results, the effect of the transfer learning model with fine-tuning or freezing is better than that of new learning, while the effect of the combination  
Figure 9: Accuracy of models with different learning strategies.  
of transfer learning + fine-tuning is improved by 8% on average compared to the combination of transfer learning + freezing.  
Conceptualization, C.L. and Z.L.; methodology, C.L., T.Z. and Z.L.; investigation, C.L.; writing--original draft preparation, C.L.; writing--review and editing, C.L.; supervision, C.L. All authors have read and agreed to the published version of the manuscript.  
This research received no external funding.  
Not applicable.  
The IP102 dataset is available at [[https://github.com/xpwu95/IP102](https://github.com/xpwu95/IP102)]([https://github.com/xpwu95/IP102](https://github.com/xpwu95/IP102)), accessed on 10 January 2022.  
The authors declare no conflict of interest.