欢迎您访问《智慧农业(中英文)》官方网站! English

Smart Agriculture ›› 2023, Vol. 5 ›› Issue (2): 104-114.doi: 10.12133/j.smartag.SA202304003

• 专题--机器视觉与农业智能感知 • 上一篇    下一篇

基于改进ShuffleNet V2的轻量级防风药材道地性智能识别

赵毓1(), 任艺平2, 朴欣茹1, 郑丹阳1, 李东明1,3()   

  1. 1.吉林农业大学 信息技术学院,吉林 长春 130118
    2.吉林农业大学 生命科学学院,吉林 长春 130118
    3.无锡学院 物联网工程学院,江苏 无锡 214063
  • 收稿日期:2023-04-07 出版日期:2023-06-30
  • 基金资助:
    吉林省科技厅重点研发项目(20210204050YY);吉林省教育厅科研项目(JJKH20210747KJ);吉林省环保厅项目(202107);吉林省生态环境厅科研项目(吉环科字第2021-07号);通辽市科技局重点研发项目(TLCXYD202103)
  • 作者简介:赵 毓,研究方向为计算机视觉、图像处理。E-mail:954445517@qq.com
  • 通信作者: 李东明,博士,教授,研究方向为计算机视觉,图像处理及光学检测等。E-mail:ldm0214@163.com

Lightweight Intelligent Recognition of Saposhnikovia Divaricata (Turcz.) Schischk Originality Based on Improved ShuffleNet V2

ZHAO Yu1(), REN Yiping2, PIAO Xinru1, ZHENG Danyang1, LI Dongming1,3()   

  1. 1.School of Information Technology, Jilin Agricultural University, Changchun 130118, China
    2.School of Life Science, Jilin Agricultural University, Changchun 130118, China
    3.School of Internet of Things Engineering, Wuxi College, Wuxi 214063, China
  • Received:2023-04-07 Online:2023-06-30

摘要:

[目的/意义] 目前,对于防风药材产地和品质的鉴别方法主要是根据其物理或化学特征,其方法需对中药材进行分离提取,存在耗时长,费用高,专业性强,技术难度大等问题,不利于推广应用。随着深度学习的不断发展,其无需人工提取特征、分类精度高等优点被广泛应用在中药材的识别之中。 [方法] 针对大多数卷积神经网络模型在识别防风药材时计算量大、精度低的问题,本研究提出了一种改进的ShuffleNet V2的轻量级防风道地性识别模型。在不降低网络性能的情况下调整模型架构,减少模型参数量和计算量,用沙漏残差网络(Hourglass Residual Network)代替传统残差网络,同时引入SE(Squeeze-and-Excitation)注意力机制,把具有附加信道注意力的沙漏残差网络嵌入到ShuffleNet V2中,使用SiLU激活函数替换 ReLU 激活函数,丰富局部特征学习,从而提出轻量化的中药防风道地性识别模型 Shuffle-Hourglass SE。为了验证本文所提出模型的有效性,选用VGG16、MobileNet V2、ShuffleNet V2和SqueezeNet V2四种经典网络模型进行对比实验。[结果和讨论]结果表明,本研究提出的模型Shuffle-Hourglass SE获得了最佳性能。在测试集上取得95.32%的准确率、95.28%的召回率,F1分数达到95.27%,测试时间、模型大小为246.34 ms和3.23 M,不仅在传统CNN网络中是最优的,在轻量级网络中也具有较大优势。 [结论] 本研究所提出的模型在保持较高识别精度的同时占用较少的储存空间,有助于在未来的低性能终端上实现防风道地性的实时诊断。

关键词: 防风, 道地性识别, ShuffleNet V2, SE注意力机制, 沙漏残差网络, 中药材, 轻量级模型

Abstract:

[Objective] Saposhnikovia divaricata (Turcz.) Schischk is a kind of traditional Chinese medicine. Currently, the methods of identifying the origin and quality of Saposhnikovia divaricata (Turcz.) Schischk are mainly based on their physical or chemical characteristics, which is impossible to make an accurate measurement of Groundness identification. With the continuous development of deep learning, its advantages of no manual extraction and high classification accuracy are widely used in different fields, and an attention-embedded ShuffleNet V2-based model was proposed in this study to address the problems of large computation and low accuracy of most convolutional neural network models in the identification of Chinese herbal medicine Saposhnikovia divaricata (Turcz.) Schischk. [Methods] The model architecture was adjusted to reduce the number of model parameters and computation without degrading the network performance, and the traditional residual network was replaced by the Hourglass residual network, while the SE attention mechanism was introduced to embed the hourglass residual network with additional channel attention into ShuffleNet V2. The important features were enhanced and the unimportant features were weakened by controlling the size of the channel ratio to make the extracted features more directional by SE attention. The SiLU activation function was used to replace the ReLU activation function to enhance the generalization ability of the model Enriching local feature learning. Therefore, a lightweight Shuffle-Hourglass SE model was proposed. The samples of Saposhnikovia divaricata (Turcz.) Schischk used in this research were samples from the main production areas, including more than 1000 samples from five production areas in Heilongjiang, Jilin, Hebei, Gansu and Inner Mongolia. A total of 5234 images of Saposhnikovia divaricata (Turcz.) Schischk were obtained by using cell phone photography indoors under white daylight, fully taking into account the geographical distribution differences of different Saposhnikovia divaricata (Turcz.) Schischk. The data set of Saposhnikovia divaricata (Turcz.) Schischk images was expanded to 10,120 by using random flip, random crop, brightness and contrast enhancement processes. In order to verify the effectiveness of the model proposed, four classical network models, VGG16, MobileNet V2, ShuffleNet V2 and SqueezeNet V2, were selected for comparison experiments, ECA ( Efficient Channel Attention ) attention mechanism, CBAM ( Convolutional Block Attention Module ) attention mechanism and CA attention mechanism were chosen to compare with SE. All attention mechanisms were introduced into the same position in the ShuffleNet V2 model, and ReLU, H-swish and ELU activation functions were selected for contrast experiments under the condition in which other parameters unchanged. In order to explore the performance improvement of ShuffleNet V2 model by using the attention mechanism of SE module, Hourglass residual block and activation function, Shuffle-Hourglass SE model ablation experiment was carried out. Finally, loss, accuracy, precision, recall and F1 score in test set and training set were used as evaluation indexes of model performances. [Results and Discussions] The results showed that the Shuffle-Hourglass SE model proposed achieved the best performances. An accuracy of 95.32%, recall of 95.28%, and F1 score of 95.27% were obtained in the test set, which was 2.09%, 2.1 %, and 2.19 % higher than the ShuffleNet V2 model, respectively. The test duration and model size were 246.34 ms and 3.23 M, respectively, which were not only optimal among Traditional CNN such as VGG and Desnet,but had great advantages among lightweight networks such as MobileNet V2、SqueezeNet V2 and ShufffleNet V2. Compared with the classical convolutional network VGG, 7.41% of the accuracy was improved, 71.89% of the test duration was reduced, and 96.76% of the model size was reduced by the Shuffle-Hourglass SE model proposed in this study. Although the test duration of ShuffleNet V2 and MobileNet V2 were similar, the accuracy and speed of the Shuffle-Hourglass SE model improved, which proved its better performance. Compared with MobileNet V2, the test duration was reduced by 69.31 ms, the model size was reduced by 1.98 M, and the accuracy was increased by 10.5 %. In terms of classification accuracy, the improved network maintains higher recognition accuracy and better classification performance. [Conclusions] The model proposed in this research is able to identify the Saposhnikovia divaricata (Turcz.) Schischk originality well while maintaining high identification accuracy and consuming less storage space, which is helpful for realizing real-time identification of Saposhnikovia divaricata (Turcz.) Schischk originality in the future low performance terminals.

Key words: Saposhnikovia divaricata (Turcz.) Schischk, originality recognition, ShuffleNet V2, SE attention mechanism, hourglass residual network, traditional Chinese medicine, lightweight model

中图分类号: