CN116109994A - Lightweight disease identification method - Google Patents

Lightweight disease identification method Download PDF

Info

Publication number
CN116109994A
CN116109994A CN202310108111.3A CN202310108111A CN116109994A CN 116109994 A CN116109994 A CN 116109994A CN 202310108111 A CN202310108111 A CN 202310108111A CN 116109994 A CN116109994 A CN 116109994A
Authority
CN
China
Prior art keywords
disease
module
feature map
identification
classification
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202310108111.3A
Other languages
Chinese (zh)
Inventor
陈鹏
李高强
焦林
章军
夏懿
张明年
张波
庞春晖
王俊峰
杜健铭
王儒敬
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Hefei Intelligent Agriculture Collaborative Innovation Research Institute Of China Science And Technology
Original Assignee
Hefei Intelligent Agriculture Collaborative Innovation Research Institute Of China Science And Technology
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Hefei Intelligent Agriculture Collaborative Innovation Research Institute Of China Science And Technology filed Critical Hefei Intelligent Agriculture Collaborative Innovation Research Institute Of China Science And Technology
Priority to CN202310108111.3A priority Critical patent/CN116109994A/en
Publication of CN116109994A publication Critical patent/CN116109994A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V20/00Scenes; Scene-specific elements
    • G06V20/50Context or environment of the image
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods
    • G06N3/082Learning methods modifying the architecture, e.g. adding, deleting or silencing nodes or connections
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q50/00Information and communication technology [ICT] specially adapted for implementation of business processes of specific business sectors, e.g. utilities or tourism
    • G06Q50/02Agriculture; Fishing; Forestry; Mining
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/70Arrangements for image or video recognition or understanding using pattern recognition or machine learning
    • G06V10/764Arrangements for image or video recognition or understanding using pattern recognition or machine learning using classification, e.g. of video objects
    • G06V10/765Arrangements for image or video recognition or understanding using pattern recognition or machine learning using classification, e.g. of video objects using rules for classification or partitioning the feature space
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/70Arrangements for image or video recognition or understanding using pattern recognition or machine learning
    • G06V10/77Processing image or video features in feature spaces; using data integration or data reduction, e.g. principal component analysis [PCA] or independent component analysis [ICA] or self-organising maps [SOM]; Blind source separation
    • G06V10/774Generating sets of training patterns; Bootstrap methods, e.g. bagging or boosting
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/70Arrangements for image or video recognition or understanding using pattern recognition or machine learning
    • G06V10/77Processing image or video features in feature spaces; using data integration or data reduction, e.g. principal component analysis [PCA] or independent component analysis [ICA] or self-organising maps [SOM]; Blind source separation
    • G06V10/776Validation; Performance evaluation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/70Arrangements for image or video recognition or understanding using pattern recognition or machine learning
    • G06V10/82Arrangements for image or video recognition or understanding using pattern recognition or machine learning using neural networks
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02ATECHNOLOGIES FOR ADAPTATION TO CLIMATE CHANGE
    • Y02A90/00Technologies having an indirect contribution to adaptation to climate change
    • Y02A90/10Information and communication technologies [ICT] supporting adaptation to climate change, e.g. for weather forecasting or climate simulation

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • General Health & Medical Sciences (AREA)
  • Health & Medical Sciences (AREA)
  • Evolutionary Computation (AREA)
  • Computing Systems (AREA)
  • Artificial Intelligence (AREA)
  • Multimedia (AREA)
  • Software Systems (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Databases & Information Systems (AREA)
  • Medical Informatics (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Business, Economics & Management (AREA)
  • Biophysics (AREA)
  • Mining & Mineral Resources (AREA)
  • Data Mining & Analysis (AREA)
  • Molecular Biology (AREA)
  • General Engineering & Computer Science (AREA)
  • Mathematical Physics (AREA)
  • Agronomy & Crop Science (AREA)
  • Animal Husbandry (AREA)
  • Marine Sciences & Fisheries (AREA)
  • Computational Linguistics (AREA)
  • Biomedical Technology (AREA)
  • Economics (AREA)
  • Human Resources & Organizations (AREA)
  • Marketing (AREA)
  • Primary Health Care (AREA)
  • Strategic Management (AREA)
  • Tourism & Hospitality (AREA)
  • General Business, Economics & Management (AREA)
  • Image Analysis (AREA)

Abstract

The invention relates to a light disease identification method, which comprises the following steps: acquiring a disease image dataset: preprocessing the acquired original disease image; constructing a disease identification light module; constructing a disease classification and identification model; the training set is input into a disease classification and identification model, the disease classification and identification model is trained, the test set is input into the trained disease classification and identification model, and a disease image identification result is output. According to the invention, a disease recognition lightweight module is constructed for extracting disease classification characteristic information, then a disease characteristic diagram with rich information is obtained through sampling and characteristic processing of 3 stages, and finally final disease classification recognition information is obtained through a classification module; compared with the current disease identification method, the method has the advantages that the identification accuracy is obviously improved, and the model size can be reduced to one fourth of the identification model with the same level, so that the method can be fully used for identifying the agricultural disease under the multi-category and complex background.

Description

Lightweight disease identification method
Technical Field
The invention relates to the technical field of disease classification and identification, in particular to a lightweight disease identification method.
Background
The disease of crops has great influence on the agricultural yield, and if the type of the agricultural disease cannot be timely identified, the agricultural yield is greatly impacted. Especially, if the crop with higher environmental requirements is not found in time, the yield reduction can reach more than 50%, and timely and accurately identifying the crop is a key of disease prevention and control.
The traditional machine vision method for identifying the disease image has a plurality of problems, such as large workload and poor identification effect. In addition, the traditional disease identification mainly depends on manpower, and the disease category is judged according to subjective observation and historical experience of a grower, and the method has small problems for small-scale planting, but the current crop planting scale is large, and the traditional manual mode is used for identifying, preventing and controlling the disease, so that the time and the labor are wasted, and the method is limited by the defects of professional knowledge and experience of farmers, and is easy to misjudge and miss judge.
And rapid and accurate identification and prediction are key steps in the prevention and control of crop disease. In general, the monitoring of diseases is almost dependent on the experience of farmers or agricultural personnel, which experience is subjective, laborious, time-consuming and unreliable. Therefore, there is an urgent need to explore an automatic, accurate and convenient disease identification method, which has important practical significance.
Disclosure of Invention
In order to solve the problem of disease identification precision at the present stage, the invention aims to provide a lightweight disease identification method which uses data to process disease images and combines a converter as a backbone network to improve the identification efficiency and accuracy of diseases.
In order to achieve the above purpose, the present invention adopts the following technical scheme: a lightweight disease identification method comprising the sequential steps of:
(1) Acquiring a disease image dataset: preprocessing the acquired disease original image, forming a disease image data set by the preprocessed disease image, and performing a process of 7:3, dividing the ratio into a training set and a testing set;
(2) Constructing a disease identification light module;
(3) Constructing a disease classification and identification model based on a disease identification light module;
(4) Obtaining disease image classification and identification results: the training set is input into a disease classification and identification model, the disease classification and identification model is trained, the test set is input into the trained disease classification and identification model, and a disease image identification result is output.
In step (1), the pretreatment specifically includes the following steps:
(1a) Denoising processing is carried out to remove irrelevant quantity in the image;
(1b) Adopting a turnover and scaling method to enhance the number of the data sets;
(1c) Adopting the reinforcement of the cutoff data, filling a square area in the disease image by 0 pixel value, and realizing random shielding; performing center normalization operation on the disease image shielded randomly to eliminate the influence of 0 value filling on training;
(1d) And enhancing by using Mosai data, namely arbitrarily selecting 4 pictures to zoom and then splicing.
The step (2) specifically refers to: the disease identification light module consists of three standard convolution products and a global strategy, wherein the three standard convolution products comprise an n multiplied by n standard convolution product and two 1 multiplied by 1 standard convolution products; firstly, inputting a feature map with the size of h multiplied by w multiplied by c, firstly modeling local information through n multiplied by n standard convolution, and then mapping the local information through 1 multiplied by 1 standard convolution to obtain a local modeling feature map; assuming that the dimension of the mapping is d, the size of the local modeling feature map is h×w×d; the disease identification light module carries out global information modeling through a global strategy, and the size of a local modeling feature map is kept unchanged after the local modeling feature map passes through the global strategy, namely h multiplied by w multiplied by d; finally, performing dimension reduction processing through 1×1 standard convolution, outputting a lightweight feature map, and restoring the size of the lightweight feature map to h×w×c;
the global strategy comprises an unfolding module, a self-attention calculating module and a restoring module, when the global strategy is passed, the local modeling feature diagram is firstly divided into blocks with the size of n multiplied by n, each block consists of n multiplied by n elements, and each element in each block is the same as the elements in the same positions of other blocks, namely the elements with the same color in the diagram, and the self-attention calculating module carries out self-attention calculating operation; the unfolding module tiles each element in the local modeling feature map into a sequence, and the restoring module restores the sequence.
The step (3) specifically refers to: the disease classification recognition model consists of four disease recognition light-weight modules, three sampling modules and a classification module, wherein the four disease recognition light-weight modules are a first disease recognition light-weight module, a second disease recognition light-weight module, a third disease recognition light-weight module and a fourth disease recognition light-weight module respectively, and the three sampling modules are a first sampling module, a second sampling module and a third sampling module respectively;
firstly dividing a disease image with an input size of H multiplied by W multiplied by 3 into non-overlapping blocks through standard convolution, wherein 3 is the dimension of the input; each block is set to 4×4 in size, and each block has 4×4×3=48 elements, resulting in a size of
Figure BDA0004075754550000031
Is a block feature map of (1);
firstly, the block feature map passes through a disease identification light-weight module, and the disease identification light-weight module does not change the size of the input block feature map, namely
Figure BDA0004075754550000032
Then, a standard convolution is carried out to enable the input dimension of the block feature map to be changed into C, and finally a first feature map is output;
the first characteristic diagram is firstly subjected to downsampling by a first sampling module, and then the second characteristic diagram is subjected to output resolution ratio of a second disease identification light-weight module
Figure BDA0004075754550000033
Is a second feature map of (2);
the second characteristic diagram is firstly subjected to downsampling by a second sampling module, and then the third disease identification light-weight module outputs the resolution of which the size is
Figure BDA0004075754550000034
Is a third feature map of (2);
the third feature map is firstly subjected to downsampling through a third sampling module, and then the fourth disease identification light weight module outputs the resolution of the third feature map as follows
Figure BDA0004075754550000035
Is a fourth feature map of (2);
the first feature map, the second feature map, the third feature map and the fourth feature map are isomorphic and layered disease feature maps;
inputting the obtained layered disease feature map into a classification module, and outputting classification identification information of the disease by the classification module;
the sampling module is used for realizing downsampling of the feature images by a channel fusion and a linear layer, the channel fusion divides each 2 multiplied by 2 adjacent pixel in the first feature image into a block, then pixels at the same position in each block are spliced together, the linear layer is used for splicing in the dimension direction, the sampling feature images are finally obtained, and the second, third and fourth feature images are obtained by a second, third and fourth disease identification light-weight module;
the classification module consists of an LN standardization layer and a global average pooling layer, and the LN standardization layer is adopted to carry out integral standardization on the extracted characteristic data of the layered disease characteristic map after translation and scaling; the global average pooling layer averages the two-dimensional images of each channel in the feature map, outputs a C multiplied by 1 feature matrix, multiplies the feature matrix by a t multiplied by C weight matrix G to obtain the probability of each disease class, wherein the weight matrix G is obtained through training, t is the disease class number, and finally outputs classification identification information through a classification module.
According to the technical scheme, the beneficial effects of the invention are as follows: firstly, the invention is used for extracting disease classification characteristic information by constructing a disease recognition lightweight module, obtaining a disease characteristic diagram with rich information through sampling and characteristic processing of 3 stages, and finally obtaining final disease classification recognition information through a classification module; secondly, through experimental verification, the method has obviously improved recognition accuracy compared with the current disease recognition method, and the size of the model can be reduced to one fourth of the recognition model of the same level, which fully proves that the method can be applied to the agricultural disease recognition work under multi-category and complex background.
Drawings
FIG. 1 is a flow chart of the method of the present invention;
FIG. 2 is a flow chart of a process of the disease recognition lightweight module of the present invention;
fig. 3 is a schematic diagram of a global strategy method of a disease identification lightweight module in the present invention.
Detailed Description
As shown in fig. 1, a lightweight disease recognition method includes the following sequential steps:
(1) Acquiring a disease image dataset: preprocessing the acquired disease original image, forming a disease image data set by the preprocessed disease image, and performing a process of 7:3, dividing the ratio into a training set and a testing set;
(2) Constructing a disease identification light module;
(3) Constructing a disease classification and identification model based on a disease identification light module;
(4) Obtaining disease image classification and identification results: the training set is input into a disease classification and identification model, the disease classification and identification model is trained, the test set is input into the trained disease classification and identification model, and a disease image identification result is output.
In step (1), the pretreatment specifically includes the following steps:
(1a) Denoising processing is carried out to remove irrelevant quantity in the image;
(1b) Adopting a turnover and scaling method to enhance the number of the data sets; the contrast and intensity of the disease image are enhanced, noise is processed to remove irrelevant amount in the image, and the data amount of each disease of the original disease image is unbalanced, so that the number of the data sets is enhanced by adopting methods such as overturning, scaling and the like, and the problem of overfitting possibly caused by overlarge difference of the number of disease types in the training process is solved;
(1c) In order to improve generalization capability of various data of a disease data set, adopting cutoff data enhancement, filling a square area of a certain block in a disease image by 0 pixel value, and realizing random shielding; performing center normalization operation on the disease image shielded randomly to eliminate the influence of 0 value filling on training;
(1d) In order to improve the richness of various data of the disease data set, mosai data enhancement is adopted, namely 4 pictures are selected at will for zooming and then spliced, so that the detection data set is greatly enriched, a plurality of small targets are added through random zooming, the robustness of a network is better, the data of the 4 pictures can be directly calculated, the batch size is reduced, and the purpose of reducing the GPU is achieved.
As shown in fig. 2, the step (2) specifically refers to: the disease identification light module consists of three standard convolution products and a global strategy, wherein the three standard convolution products comprise an n multiplied by n standard convolution product and two 1 multiplied by 1 standard convolution products; firstly, inputting a characteristic diagram with the size of h multiplied by w multiplied by c, wherein the characteristic diagram can be a block characteristic diagram, a first characteristic diagram, a second characteristic diagram or a third characteristic diagram; firstly modeling local information through n×n standard convolution, and then mapping the local information through 1×1 standard convolution to obtain a local modeling feature map; assuming that the dimension of the mapping is d, the size of the local modeling feature map is h×w×d; the disease identification light module carries out global information modeling through a global strategy, and the size of a local modeling feature map is kept unchanged after the local modeling feature map passes through the global strategy, namely h multiplied by w multiplied by d; finally, performing dimension reduction processing through 1×1 standard convolution, outputting a lightweight feature map, and restoring the size of the lightweight feature map to h×w×c;
as shown in fig. 3, the global strategy includes an unfolding module, a self-attention calculating module and a restoring module, when the global strategy is passed, the local modeling feature diagram is firstly divided into blocks with n×n size, each block is composed of n×n elements, and the self-attention calculating operation is performed by the self-attention calculating module on the elements in the same position as the other blocks, namely on the elements with the same color in the diagram; the unfolding module tiles each element in the local modeling feature map into a sequence, and the restoring module restores the sequence.
The purpose of the disease recognition lightweight module is to accomplish local and global feature modeling with less input. From the form, an original feature map with the size of h×w×c is input, local information modeling is firstly carried out through n×n standard convolution, then local information is mapped through 1×1 standard convolution, and a local modeling feature map is obtained. Assuming the dimension of the map is d, the size of the local modeling feature map is h×w×d.
The step (3) specifically refers to: the disease classification recognition model consists of four disease recognition light-weight modules, three sampling modules and a classification module, wherein the four disease recognition light-weight modules are a first disease recognition light-weight module, a second disease recognition light-weight module, a third disease recognition light-weight module and a fourth disease recognition light-weight module respectively, and the three sampling modules are a first sampling module, a second sampling module and a third sampling module respectively;
firstly dividing a disease image with an input size of H multiplied by W multiplied by 3 into non-overlapping blocks through standard convolution, wherein 3 is the dimension of the input; each block is set to 4×4 in size, and each block has 4×4×3=48 elements, resulting in a size of
Figure BDA0004075754550000061
Is a block feature map of (1);
firstly, the block feature map passes through a disease identification light-weight module, and the disease identification light-weight module does not change the size of the input block feature map, namely
Figure BDA0004075754550000062
Then, a standard convolution is carried out to enable the input dimension of the block feature map to be changed into C, and finally a first feature map is output;
the first characteristic diagram is firstly subjected to downsampling by a first sampling module, and then the second characteristic diagram is subjected to output resolution ratio of a second disease identification light-weight module
Figure BDA0004075754550000063
Is a second feature map of (2);
the second characteristic diagram is firstly subjected to downsampling by a second sampling module, and then the third disease identification light-weight module outputs the resolution of which the size is
Figure BDA0004075754550000064
Is a third feature map of (2);
the third feature map is firstly subjected to downsampling through a third sampling module, and then the fourth disease identification light weight module outputs the resolution of the third feature map as follows
Figure BDA0004075754550000065
Is a fourth feature map of (2);
the first feature map, the second feature map, the third feature map and the fourth feature map are isomorphic and layered disease feature maps;
inputting the obtained layered disease feature map into a classification module, and outputting classification identification information of the disease by the classification module;
the sampling module is used for realizing downsampling of the feature images by a channel fusion and a linear layer, the channel fusion divides each 2 multiplied by 2 adjacent pixel in the first feature image into a block, then pixels at the same position in each block are spliced together, the linear layer is used for splicing in the dimension direction, the sampling feature images are finally obtained, and the second, third and fourth feature images are obtained by a second, third and fourth disease identification light-weight module;
the classification module consists of a LN (Layer Normalization) standardization layer and a global average pooling layer, and adopts an LN standardization layer to carry out integral standardization on the characteristic data of the extracted layered disease characteristic map after translational scaling; the global average pooling layer averages the two-dimensional images of each channel in the feature map, outputs a C multiplied by 1 feature matrix, multiplies the feature matrix by a t multiplied by C weight matrix G to obtain the probability of each disease class, wherein the weight matrix G is obtained through training, t is the disease class number, and finally outputs classification identification information through a classification module.
Table 1 shows the results of experimental comparison of the method of the present invention with several conventional classification methods
Figure BDA0004075754550000071
Table 1 shows the experimental results of the present invention compared with other classification methods. Obviously, compared with other methods, the method has the highest recognition precision, which reaches 99.10 percent, and the recall rate, the precision and the F-Measure (comprehensive evaluation index) reach 97.36 percent, 97.32 percent and 97.3 percent respectively. The method reduces the parameters of the model, and improves the recognition accuracy by 1% compared with Swin transducer. This is due to the lightweight design of the present invention, which combines the advantages of a transducer and convolution. The method has the advantages of good effect in disease monitoring of multiple varieties and high complexity, more stable and lighter model and capability of well solving the related problems of disease identification.
The foregoing has outlined the principles, main features and advantages of the present invention in comparison with the state-of-the-art classification and identification method. It will be understood by those skilled in the art that the present invention is not limited to the embodiments described above, and that the above embodiments and descriptions are merely illustrative of the principles of the present invention, and various changes and modifications may be made therein without departing from the spirit and scope of the invention, which is defined by the appended claims. The scope of the invention is defined by the appended claims and equivalents thereof.

Claims (4)

1. A lightweight disease identification method is characterized in that: the method comprises the following steps in sequence:
(1) Acquiring a disease image dataset: preprocessing the acquired disease original image, forming a disease image data set by the preprocessed disease image, and performing a process of 7:3, dividing the ratio into a training set and a testing set;
(2) Constructing a disease identification light module;
(3) Constructing a disease classification and identification model based on a disease identification light module;
(4) Obtaining disease image classification and identification results: the training set is input into a disease classification and identification model, the disease classification and identification model is trained, the test set is input into the trained disease classification and identification model, and a disease image identification result is output.
2. The lightweight disease recognition method according to claim 1, characterized in that: in step (1), the pretreatment specifically includes the following steps:
(1a) Denoising processing is carried out to remove irrelevant quantity in the image;
(1b) Adopting a turnover and scaling method to enhance the number of the data sets;
(1c) Adopting the reinforcement of the cutoff data, filling a square area in the disease image by 0 pixel value, and realizing random shielding; performing center normalization operation on the disease image shielded randomly to eliminate the influence of 0 value filling on training;
(1d) And enhancing by using Mosai data, namely arbitrarily selecting 4 pictures to zoom and then splicing.
3. The lightweight disease recognition method according to claim 1, characterized in that: the step (2) specifically refers to: the disease identification light module consists of three standard convolution products and a global strategy, wherein the three standard convolution products comprise an n multiplied by n standard convolution product and two 1 multiplied by 1 standard convolution products; firstly, inputting a feature map with the size of h multiplied by w multiplied by c, firstly modeling local information through n multiplied by n standard convolution, and then mapping the local information through 1 multiplied by 1 standard convolution to obtain a local modeling feature map; assuming that the dimension of the mapping is d, the size of the local modeling feature map is h×w×d; the disease identification light module carries out global information modeling through a global strategy, and the size of a local modeling feature map is kept unchanged after the local modeling feature map passes through the global strategy, namely h multiplied by w multiplied by d; finally, performing dimension reduction processing through 1×1 standard convolution, outputting a lightweight feature map, and restoring the size of the lightweight feature map to h×w×c;
the global strategy comprises an unfolding module, a self-attention calculating module and a restoring module, when the global strategy is passed, the local modeling feature diagram is firstly divided into blocks with the size of n multiplied by n, each block consists of n multiplied by n elements, and each element in each block is the same as the elements in the same positions of other blocks, namely the elements with the same color in the diagram, and the self-attention calculating module carries out self-attention calculating operation; the unfolding module tiles each element in the local modeling feature map into a sequence, and the restoring module restores the sequence.
4. The lightweight disease recognition method according to claim 1, characterized in that: the step (3) specifically refers to: the disease classification recognition model consists of four disease recognition light-weight modules, three sampling modules and a classification module, wherein the four disease recognition light-weight modules are a first disease recognition light-weight module, a second disease recognition light-weight module, a third disease recognition light-weight module and a fourth disease recognition light-weight module respectively, and the three sampling modules are a first sampling module, a second sampling module and a third sampling module respectively;
firstly dividing a disease image with an input size of H multiplied by W multiplied by 3 into non-overlapping blocks through standard convolution, wherein 3 is the dimension of the input; each block is set to 4×4 in size, and each block has 4×4×3=48 elements, resulting in a size of
Figure FDA0004075754540000021
Is a block feature map of (1);
firstly, the block feature map passes through a disease identification light-weight module, and the disease identification light-weight module does not change the size of the input block feature map, namely
Figure FDA0004075754540000022
Then, a standard convolution is carried out to enable the input dimension of the block feature map to be changed into C, and finally a first feature map is output;
the first characteristic diagram is firstly subjected to downsampling by a first sampling module, and then the second characteristic diagram is subjected to output resolution ratio of a second disease identification light-weight module
Figure FDA0004075754540000023
Is a second feature map of (2);
the second characteristic diagram is firstly subjected to downsampling by a second sampling module, and then the third disease identification light-weight module outputs the resolution of which the size is
Figure FDA0004075754540000024
Is a third feature map of (2);
the third feature map is firstly subjected to downsampling through a third sampling module, and then the fourth disease identification light weight module outputs the resolution of the third feature map as follows
Figure FDA0004075754540000025
Is a fourth feature map of (2);
the first feature map, the second feature map, the third feature map and the fourth feature map are isomorphic and layered disease feature maps;
inputting the obtained layered disease feature map into a classification module, and outputting classification identification information of the disease by the classification module;
the sampling module is used for realizing downsampling of the feature images by a channel fusion and a linear layer, the channel fusion divides each 2 multiplied by 2 adjacent pixel in the first feature image into a block, then pixels at the same position in each block are spliced together, the linear layer is used for splicing in the dimension direction, the sampling feature images are finally obtained, and the second, third and fourth feature images are obtained by a second, third and fourth disease identification light-weight module;
the classification module consists of an LN standardization layer and a global average pooling layer, and the LN standardization layer is adopted to carry out integral standardization on the extracted characteristic data of the layered disease characteristic map after translation and scaling; the global average pooling layer averages the two-dimensional images of each channel in the feature map, outputs a C multiplied by 1 feature matrix, multiplies the feature matrix by a t multiplied by C weight matrix G to obtain the probability of each disease class, wherein the weight matrix G is obtained through training, t is the disease class number, and finally outputs classification identification information through a classification module.
CN202310108111.3A 2023-02-14 2023-02-14 Lightweight disease identification method Pending CN116109994A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310108111.3A CN116109994A (en) 2023-02-14 2023-02-14 Lightweight disease identification method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310108111.3A CN116109994A (en) 2023-02-14 2023-02-14 Lightweight disease identification method

Publications (1)

Publication Number Publication Date
CN116109994A true CN116109994A (en) 2023-05-12

Family

ID=86259546

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310108111.3A Pending CN116109994A (en) 2023-02-14 2023-02-14 Lightweight disease identification method

Country Status (1)

Country Link
CN (1) CN116109994A (en)

Similar Documents

Publication Publication Date Title
CN110533084B (en) Multi-scale target detection method based on self-attention mechanism
CN109033998B (en) Remote sensing image ground object labeling method based on attention mechanism convolutional neural network
CN107239751B (en) High-resolution SAR image classification method based on non-subsampled contourlet full convolution network
WO2021139258A1 (en) Image recognition based cell recognition and counting method and apparatus, and computer device
CN109523470B (en) Depth image super-resolution reconstruction method and system
CN111860351B (en) Remote sensing image fishpond extraction method based on line-row self-attention full convolution neural network
CN111368825B (en) Pointer positioning method based on semantic segmentation
CN111178177A (en) Cucumber disease identification method based on convolutional neural network
EP3971767A1 (en) Method for constructing farmland image-based convolutional neural network model, and system thereof
CN115331104A (en) Crop planting information extraction method based on convolutional neural network
CN111598869A (en) Method, equipment and storage medium for detecting Mura of display screen
CN114898359B (en) Litchi plant diseases and insect pests detection method based on improvement EFFICIENTDET
CN116912674A (en) Target detection method and system based on improved YOLOv5s network model under complex water environment
CN112164030A (en) Method and device for quickly detecting rice panicle grains, computer equipment and storage medium
CN116012700A (en) Real-time fish disease detection system based on YOLO-v5
CN116884036A (en) Live pig posture detection method, device, equipment and medium based on YOLOv5DA
CN116721385A (en) Machine learning-based RGB camera data cyanobacteria bloom monitoring method
CN113435389B (en) Chlorella and golden algae classification and identification method based on image feature deep learning
CN110992267A (en) Abrasive particle identification method based on DPSR and Lightweight CNN
CN116109994A (en) Lightweight disease identification method
CN115661544A (en) N-MobileNetXt-based spinach seedling water stress level classification system and method
CN112465821A (en) Multi-scale pest image detection method based on boundary key point perception
CN117765410B (en) Remote sensing image double-branch feature fusion solid waste identification method and system and electronic equipment
CN106326846B (en) The forest plant parallel extraction method of unmanned plane image
CN116188774B (en) Hyperspectral image instance segmentation method and building instance segmentation method

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination