A light-weight empoasca fabae pest detection method based on deep learning

CN121095701BActive Publication Date: 2026-08-21SHANDONG ACADEMY OF AGRICULTURAL SCIENCES
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202511491525.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-10-19
Publication Date
2026-08-21
Estimated Expiration
2045-10-19

AI Technical Summary

Technical Problem

[0003]本发明的目的在于提供一种基于深度学习的轻量化小绿叶蝉虫害检测方法,用于解决人工检测茶小绿叶蝉时无法快速、全面掌握病害情况的问题

Benefits of technology

[0019]本发明的有益效果是:提出尺度动态化注意力机制SDAM, 通过计算输入特征图的标准差来衡量其复杂度,进而为不同卷积核分支动态分配权重,捕捉茶小绿叶蝉的细微特征。引入分离与增强注意力机制SEAM,实现检测头重构与多尺度检测强化,优化模型对茶小绿叶蝉多尺度分布的检测能力。采用WaveletPool网络替代模型的部分传统卷积与上下采样, 基于小波变换的时频局部化特性,将茶园图像分解为高频细节与低频背景,有效分离茶小绿叶蝉与背景,提升特征信噪比,在提升特征提取能力的同时,大幅降低了计算量。本发明解决了人工虫害检测,费时耗力、效率低下的问题,解放劳动力,降低成本投入,实用性较强。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121095701B_ABST
    Figure CN121095701B_ABST
Patent Text Reader

Abstract

The application discloses a light-weighted aphid pest detection method based on deep learning, relates to the technical field of agricultural disease detection, and aims at solving the problem that artificial detection of tea green leafhoppers cannot quickly and comprehensively grasp the disease situation. The method comprises the following steps: S1, preparing a tea green leafhopper original data set containing different environmental variables in a real tea garden environment; S2, dividing the labeled image data into a training set, a verification set and a test set; S3, constructing a tea green leafhopper detection model based on an improved Yolov; S4, training the tea green leafhopper detection model based on the improved Yolov constructed in the step S3 by using the training set in the step S2 to obtain a final optimized model; S5, detecting tea green leafhoppers trapped in a tea garden by using the optimized model obtained in the step S4 to obtain a detection result; and S6, deploying and putting into use. The application solves the problems of time-consuming, labor-consuming, low efficiency, labor liberation, cost reduction and high practicability of artificial pest detection.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of agricultural disease detection technology, specifically a lightweight method for detecting leafhopper pests based on deep learning. Background Technology

[0002] The tea green leafhopper, a major pest in tea gardens, is widely distributed, causes damage over a long period, and results in significant losses. Tiny, typically only a few millimeters in length, and with a body color similar to tender tea leaves, it often hides on the tender shoots and undersides of leaves, making it extremely difficult to spot due to its small size and camouflage. Furthermore, the tea green leafhopper is a strong migratory bird, quickly flying away at the slightest disturbance, making manual capture extremely difficult. In addition, it tends to be scattered throughout the tea garden, with a wide and unconcentrated distribution, requiring considerable time and effort for individual inspection of each plant during manual detection. In large tea gardens, manual detection cannot quickly and comprehensively assess the occurrence of the tea green leafhopper, hindering timely and effective control decisions. Therefore, accurate identification of the tea green leafhopper is crucial for timely control efforts, ensuring healthy tea tree growth, and producing high-quality tea. Summary of the Invention

[0003] The purpose of this invention is to provide a lightweight method for detecting tea green leafhopper pests based on deep learning, which solves the problem that manual detection of tea green leafhoppers cannot quickly and comprehensively grasp the disease situation.

[0004] The technical solution adopted by this invention to solve its technical problem is: a lightweight method for detecting leafhopper pests based on deep learning, comprising the following steps:

[0005] S1. Create the original dataset of the tea green leafhopper containing different environmental variables in a real tea garden environment.

[0006] Insect-attracting boards were deployed in the tea garden to capture the tea green leafhopper, and images of the tea green leafhopper on the boards were collected. The collected raw images were further cropped into multiple smaller images, and an image annotation platform was used to label them into two categories based on the image data: tea green leafhopper and other insects.

[0007] S2. Divide the labeled image data into training set, validation set and test set.

[0008] S3. Construct an improved tea green leafhopper detection model based on Yolov.

[0009] A scale-dynamic attention module (SDAM) is added to the backbone network of the Yolov model. The P2 detector head is used to replace the P5 detector head. The Separation and Enhancement Attention (SEAM) mechanism is introduced into the detector head. WaveletPool is introduced to replace some convolutions and upsampling in the original Yolov model, resulting in an improved Yolov-based tea green leafhopper detection model.

[0010] S4. Use the training set from step S2 to train the improved tea green leafhopper detection model based on Yolov constructed in step S3 to obtain the final optimized model; and verify the model performance on the test set.

[0011] S5. The optimized model obtained in step S4 is used to detect the tea green leafhoppers trapped in the tea garden, and the detection results are obtained.

[0012] S6, deployed and put into use.

[0013] Furthermore, in step S1, image data is collected by taking pictures. An insect photography device is selected to photograph the insect-attracting board, and images of the tea green leafhopper are collected under different lighting conditions, different shading conditions, and different weather conditions.

[0014] Furthermore, considering the impact of sunlight color temperature and the number of insects on the insect-attracting boards on the feature information of the collected images at different times, data was collected every hour.

[0015] Furthermore, the original image was cropped into 1360 images, and images of poor quality were removed. The image was then labeled with rectangular boxes using the labelimg software, and the labels were divided into two categories: EPM and Others. EPM represents the tea green leafhopper, and Others represents other insects.

[0016] Furthermore, the ratio of the training set, validation set, and test set is 7:1.5:1.5.

[0017] Furthermore, the Scale Dynamic Attention Module (SDAM) measures the complexity of the input feature maps by calculating the standard deviation of the input feature maps and dynamically assigns weights to different convolutional kernel branches. The algorithm for SDAM includes: (1); (2); (3). In the formula, F is the input feature map; C is the number of channels; A is adaptive average pooling, M is adaptive max pooling; α is the standard deviation of the feature map; σ is the Sigmoid activation function; * represents element-wise multiplication; m is the average value calculated in the channel dimension, x is the maximum value calculated in the channel dimension; C iωi is the i-th branch convolution; ωi is the corresponding dynamic weight; concat is the concatenation operation; F' is the final attention feature generated after activation by the sigmoid function, which is then element-wise multiplied by the input feature mapping; F'' is the output feature.

[0018] Furthermore, the specific algorithm of WaveletPool includes: (4); (5); (6). In the formula, ψ is an approximate function; ψ is a detail function; W is the approximation coefficient. ψ For detail coefficients; Indicates the scale of time reversal; h ψ [-n] represents a time-reversed wavelet vector; n represents the sample in the vector, j represents the resolution, and K represents the position index.

[0019] The beneficial effects of this invention are as follows: It proposes a scale-dynamic attention mechanism (SDAM), which measures the complexity of the input feature map by calculating its standard deviation, and then dynamically assigns weights to different convolutional kernel branches to capture the subtle features of the tea green leafhopper. It introduces a separation and enhancement attention mechanism (SEAM) to achieve detector head reconstruction and multi-scale detection enhancement, optimizing the model's ability to detect the multi-scale distribution of the tea green leafhopper. It uses a WaveletPool network to replace some of the traditional convolutions and upsampling in the model. Based on the time-frequency localization characteristics of wavelet transform, it decomposes the tea garden image into high-frequency details and low-frequency background, effectively separating the tea green leafhopper from the background, improving the feature signal-to-noise ratio, and significantly reducing computational load while enhancing feature extraction capabilities. This invention solves the problems of time-consuming, labor-intensive, and inefficient manual pest detection, liberating labor, reducing costs, and demonstrating strong practicality. Attached Figure Description

[0020] Figure 1 This is a diagram showing the network results of the improved model of the present invention.

[0021] Figure 2 This is a flowchart illustrating the implementation steps of the method of the present invention.

[0022] Figure 3 This is a diagram showing the detection results of the small green leafhopper according to the present invention. Detailed Implementation

[0023] The present invention provides a lightweight deep learning-based method for detecting small green leafhopper pests, described in detail below with reference to the accompanying drawings. The method includes the following steps:

[0024] S1. Create the original dataset of the tea green leafhopper containing different environmental variables in a real tea garden environment.

[0025] Insect-attracting boards were deployed in the tea garden to capture the tea green leafhopper, and images of the leafhopper were collected. The original images were further cropped into multiple smaller images, and an image annotation platform was used to label them as either tea green leafhoppers or other insects based on the image data, in order to realistically reflect the insect situation in the tea garden.

[0026] Specifically, in step S1, image data is collected through photography. To ensure the diversity and authenticity of tea green leafhopper identification samples in the complex environment of tea gardens, insect photography equipment was selected to photograph the insect-attracting boards, collecting images of tea green leafhoppers under different lighting, shading, and weather conditions. Considering the influence of sunlight color temperature and the number of insects on the attracting boards at different times on the image feature information, data was collected every hour. After cropping the original images, a total of 1360 images were generated. Images of poor quality were removed, and the images were labeled with rectangular boxes using labelimg software, dividing the labels into two categories: EPM and Others. EPM represents tea green leafhoppers, and Others represents other insects.

[0027] S2. Divide the labeled image data into training set, validation set and test set according to the ratio of 7:1.5:1.5.

[0028] S3. Construct an improved tea green leafhopper detection model based on Yolov8.

[0029] A Scale Dynamic Attention (SDAM) module is added to the backbone network of the YOLOv8 model, and the P2 detector head replaces the P5 detector head to optimize the model's ability to detect small-scale targets. A Separate and Enhanced Attention (SEAM) mechanism is introduced into the detector head to further optimize the model's detection performance for targets at different scales. Combined with the rich features extracted by the SDAM module, the model can utilize more accurate feature information when detecting targets at different scales, thereby improving overall detection performance. WaveletPool is introduced to replace some convolutions and upsampling in the original YOLOv8 model, resulting in an improved YOLOv8-based tea green leafhopper detection model.

[0030] Step S3 aims to enhance the model's ability to identify small and overlapping targets, such as the tea green leafhopper, and improve detection accuracy. A scale-dynamic attention mechanism is proposed, and a detection head resolution optimization method is designed to enhance the model's ability to express detailed features. Based on this, the Separation and Enhancement Attention Mechanism (SEAM) is integrated. Finally, a WaveletPool module is introduced to replace some convolution and upsampling operations, reducing aliasing and computational complexity, thus achieving a lightweight model. The scale-dynamic attention module measures the complexity of the input feature map by calculating the standard deviation and dynamically assigns weights to different convolutional kernel branches, focusing on key features. (1); (2). (3). In the formula, F is the input feature map; C is the number of channels; A is adaptive average pooling, M is adaptive max pooling; α is the standard deviation of the feature map; σ is the Sigmoid activation function; * represents element-wise multiplication; m is the average value calculated in the channel dimension, x is the maximum value calculated in the channel dimension; C i ωi is the i-th branch convolution; ωi is the corresponding dynamic weight; concat is the concatenation operation; F' is the final attention feature generated after activation by the sigmoid function, which is then element-wise multiplied by the input feature mapping; F'' is the output feature.

[0031] In complex tea garden backgrounds, WaveletPool is introduced to effectively separate the key features of the tea green leafhopper through a unique transformation method, enhancing feature clarity and recognizability. This solves the problem of feature extraction difficulties in complex backgrounds using traditional methods, significantly reducing computational load while improving feature extraction capabilities. When processing tea garden insect-covered images, it can quickly complete feature extraction, significantly improving detection efficiency and achieving a balance between detection efficiency and accuracy. The specific algorithm is as follows:

[0032] (4).

[0033] (5).

[0034] (6). In the formula, ψ is an approximate function; ψ is a detail function; W is the approximation coefficient. ψ For detail coefficients; Indicates the scale of time reversal; h ψ [-n] represents a time-reversed wavelet vector; n represents the sample in the vector, j represents the resolution, and K represents the position index.

[0035] S4. Train the improved tea green leafhopper detection model based on Yolov8n constructed in step S3 using the training set from step S2; and verify the model performance on the test set.

[0036] S5. The optimized model obtained in step S4 is used to detect the tea green leafhoppers trapped in the tea garden, and the detection results are obtained.

[0037] S6, deployed and put into use.

[0038] The advantages of this invention are: (1) It proposes a plug-and-play scale dynamic attention mechanism SDAM, which measures the complexity by calculating the standard deviation of the input feature map, and then dynamically assigns weights to different convolutional kernel branches to capture the subtle features of the tea green leafhopper. (2) It introduces a separation and enhancement attention mechanism SEAM into the detection head of the improved model to realize the reconstruction of the detection head and the enhancement of multi-scale detection, and optimizes the model's ability to detect the multi-scale distribution of the tea green leafhopper. (3) It uses the WaveletPool network to replace part of the traditional convolution and upsampling of the model. Based on the time-frequency localization characteristics of wavelet transform, it decomposes the tea garden image into high-frequency details and low-frequency background, effectively separating the tea green leafhopper from the background, improving the feature signal-to-noise ratio, and significantly reducing the amount of computation while improving the feature extraction capability. (4) It solves the problems of time-consuming, labor-intensive, and inefficient manual pest detection, liberates labor, reduces cost input, and has strong practicality.

Claims

1. A lightweight method for detecting small green leafhopper pests based on deep learning, characterized in that, Includes the following steps: S1. Create the original dataset of the tea green leafhopper containing different environmental variables in a real tea garden environment; Insect-attracting boards were deployed in the tea garden to capture the tea green leafhopper. Data images of the tea green leafhopper on the insect-attracting boards were collected and cropped into multiple small images. Based on the image data, the leafhoppers were labeled as either tea green leafhoppers or other insects. S2. Divide the labeled image data into training set, validation set and test set; S3. Construct an improved tea green leafhopper detection model based on Yolov; A scale-dynamic attention module (SDAM) is added to the backbone network of the Yolov model. The P2 detection head is used to replace the P5 detection head. The Separation and Enhancement Attention (SEAM) mechanism is introduced into the detection head. WaveletPool is introduced to replace some convolutions and upsampling in the original Yolov model, resulting in a Yolov-based improved tea green leafhopper detection model. S4. Use the training set from step S2 to train the improved tea green leafhopper detection model based on Yolov constructed in step S3 to obtain the final optimized model; and verify the model performance on the test set. S5. The optimized model obtained in step S4 is used to detect the tea green leafhoppers trapped in the tea garden, and the detection results are obtained. S6. Deployed and put into use; The Scale Dynamic Attention Module (SDAM) measures the complexity of the input feature map by calculating the standard deviation of the input feature map and dynamically assigns weights to different convolutional kernel branches. The algorithm for Scale Dynamic Attention Module (SDAM) includes: (1); (2); (3); where F is the input feature map; C is the number of channels; A is adaptive average pooling, M is adaptive max pooling; α is the standard deviation of the feature map; σ is the Sigmoid activation function; * represents element-wise multiplication; m is the average value in the channel dimension, x is the maximum value in the channel dimension; C i ωi is the i-th branch convolution; concat is the concatenation operation; F' is the final attention feature generated after activation by the sigmoid function, which is then element-wise multiplied by the input feature mapping; F'' is the output feature. The specific algorithm of WaveletPool includes: (4); (5); (6); where, ψ is an approximate function; ψ is a detail function; W is the approximation coefficient. ψ For detail coefficients; Indicates the scale of time reversal; h ψ [-n] represents a time-reversed wavelet vector; n represents the sample in the vector, j represents the resolution, and k represents the position index.

2. The lightweight green leafhopper pest detection method based on deep learning according to claim 1, characterized in that, In step S1, image data is collected by taking pictures. Insect photography equipment is selected to photograph the insect-attracting board and collect images of the tea green leafhopper under different lighting, different shading, and different weather conditions.

3. The lightweight green leafhopper pest detection method based on deep learning according to claim 2, characterized in that, Considering the impact of sunlight color temperature and the number of insects on the insect-attracting boards on the feature information of the collected images at different times, data was collected every hour.

4. The lightweight green leafhopper pest detection method based on deep learning according to claim 3, characterized in that, The original image was cropped into 1360 images, and images of poor quality were removed. The image was labeled with rectangular boxes using the labelimg software, and the labels were divided into two categories: EPM and Others. EPM represents the tea green leafhopper, and Others represents other insects.

5. A lightweight method for detecting small green leafhopper pests based on deep learning according to claim 4, characterized in that, The ratio of training set, validation set and test set is 7:1.5:1.5.

Citation Information

Patent Citations

  • Cicada tea image detection method in natural scene based on improved YOLO model

    CN117690065A

  • Rice disease and pest detection method and system based on improved YOLOv8

    CN117710820A