Corn pest monitoring method based on YOLO-FSRNet

By adopting the YOLO-FSRNet-based method in corn pest monitoring, using FasterNet, SEAttention module and RepVGG module, combined with the MPDIoU loss function, the problems of high miss detection rate and slow inference speed in the existing technology are solved, and efficient and accurate corn pest monitoring is achieved.

CN119942329APending Publication Date: 2025-05-06HENAN UNIVERSITY
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510015521.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-01-06
Publication Date
2025-05-06

AI Technical Summary

Technical Problem

The existing corn pest monitoring methods have high missed detection rates and slow reasoning speed in complex environments, which cannot meet the needs of modern agriculture for efficient and accurate pest monitoring.

Method used

The corn pest monitoring method based on YOLO-FSRNet is adopted, and the backbone network of YOLOv8 is replaced with FasterNet, and the SEAttention module and RepVGG module are added to the backbone network and neck network, combining the MPDIoU loss function optimization model.

Benefits of technology

It improves the detection accuracy and inference speed of the model, significantly reduces the missed detection rate and false detection rate, and is suitable for real-time monitoring of complex field environments.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119942329A_ABST
    Figure CN119942329A_ABST
Patent Text Reader

Abstract

The invention belongs to the technical field of computer vision, and discloses a corn pest monitoring method based on YOLO-FSRNet. The method comprises the following steps: step 1, acquiring a corn pest image, and marking and constructing a high-quality corn pest data set; step 2, constructing a YOLO-FSRNet network model based on the YOLOv8 network, namely replacing a backbone network of the YOLOv8 network with a Faster Net network, adding a SEAttention module in the backbone network and a neck network, and adding a RepVGG module in the neck network; step 3, training the YOLO-FSRNet network model by using the high-quality corn pest data set to obtain a corn pest monitoring model; and 4, deploying the corn pest monitoring model on terminal equipment to realize monitoring and identification of corn pests. According to the method, the reasoning speed is remarkably increased while high recognition precision is kept, and more efficient and accurate monitoring of corn pests can be achieved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention belongs to the field of computer vision technology, and in particular relates to a corn pest monitoring method based on YOLO-FSRNet. Background Art

[0002] Corn is one of the most important food crops in the world, and its yield and quality directly affect food security. However, corn is easily attacked by various pests during its growth process. These pests not only damage corn plants, resulting in reduced yields, but may also cause diseases, thus affecting the overall growth and yield of corn. Therefore, timely monitoring and prevention of corn pests are crucial, which directly affects the benefits of agricultural production and food security.

[0003] Traditional corn pest monitoring methods mainly rely on manual observation and field investigation. Although this method can obtain relatively accurate information, it is inefficient, time-consuming and labor-intensive, and easily affected by human factors, resulting in unstable and incomplete monitoring results. With the continuous expansion of agricultural production, manual monitoring alone can no longer meet the needs of modern agriculture for efficient and accurate pest monitoring. Therefore, it is particularly important to adopt an automated corn pest monitoring method based on modern computer vision technology and deep learning algorithms.

[0004] In order to better achieve efficient monitoring of corn pests, the target detection algorithm based on convolutional neural network has become one of the effective solutions. Although the existing convolutional neural network has made significant progress in algorithm stability, the missed detection rate of corn pests is still high and the reasoning speed is slow in complex environments. Therefore, in complex field environments, how to further improve the reasoning speed while maintaining high detection accuracy is a technical direction that needs further exploration and optimization. Summary of the invention

[0005] In order to solve the problems of high missed detection rate and slow reasoning speed of existing corn pest monitoring methods in complex environments, the present invention provides a corn pest monitoring method based on YOLO-FSRNet, which uses an improved YOLOv8 network to improve the detection accuracy of the corn pest monitoring model while also improving the reasoning speed of the model.

[0006] The present invention provides a corn pest monitoring method based on YOLO-FSRNet, comprising:

[0007] Step 1: Collect corn pest images, annotate and build a high-quality corn pest dataset;

[0008] Step 2: Build the YOLO-FSRNet network model based on the YOLOv8 network, including: replacing the backbone network of the YOLOv8 network with the FasterNet network, adding the SEAttention module to the backbone network and the neck network, and adding the RepVGG module to the neck network;

[0009] Step 3: Using the high-quality corn pest dataset to train the YOLO-FSRNet network model to obtain a corn pest monitoring model;

[0010] Step 4: Deploy the corn pest monitoring model on the terminal device to monitor and identify corn pests.

[0011] Furthermore, in step 1, the pests in the image are accurately labeled using the LabelImg image labeling tool, and the labeled content includes the category and location information of the corn pests.

[0012] Furthermore, in step 2, the FasterNet network includes an Embedding layer, a first FasterNet Block module, a first Merging layer, a second FasterNet Block module, a second Merging layer, a third FasterNet Block module, a third Merging layer and a fourth FasterNet Block module; the FasterNet Block module includes a partial convolution layer, a point-by-point convolution layer and a residual structure.

[0013] Furthermore, in step 2, the SEAttention module is added to the end of the backbone network and the neck network, and the weight of the features of each channel is adjusted by compression, excitation and re-weighting.

[0014] Furthermore, in step 2, the RepVGG module establishes a residual connection through three paths, including: 3×3 convolution, 1×1 convolution and Identity.

[0015] Furthermore, the RepVGG module in the corn pest monitoring model merges the three paths of the RepVGG module in the training phase into a 3×3 convolutional layer.

[0016] Furthermore, the MPDIoU loss function is used when training the YOLO-FSRNet network model. The MPDIoU loss function formula is as follows:

[0017]

[0018] Among them, h represents the input image height, w represents the input image width, Represents the Euclidean distance between the upper left corner of the prediction box and the upper left corner of the target box, It represents the Euclidean distance between the lower right corner of the prediction box and the lower right corner of the target box, and IoU represents the intersection over union of the prediction box and the target box.

[0019] Furthermore, the terminal device includes a memory, a GPU processor, a high-precision camera and a display screen;

[0020] The memory is used to store the corn pest monitoring model and monitoring data, the GPU processor is used to provide efficient computing power to support real-time image processing and detection, the high-precision camera is used to collect high-resolution images in real time, and the display screen is used to display monitoring results in real time.

[0021] Furthermore, the monitoring and identification of corn pests includes:

[0022] Acquire the image of corn to be monitored through a high-precision camera;

[0023] Extracting features of the corn image to be monitored using the backbone network of the corn pest monitoring model;

[0024] The neck network of the corn pest monitoring model is used to adjust the weight of each feature information, and to perform feature fusion on multiple feature information;

[0025] The head network of the corn pest monitoring model is used to determine whether there are pests in the corn image to be monitored, and when pests are present in the corn image to be monitored, the location of the pests is marked and the type of pests is identified in the corn image to be monitored through the display screen.

[0026] Beneficial effects of the present invention:

[0027] (1) The present invention improves the inference speed of the model by replacing the backbone network in YOLOv8 with the FasterNet network, thus meeting the requirements for real-time and high efficiency in the corn pest monitoring process.

[0028] (2) The present invention introduces the SEAttention module into the improved network structure, which effectively enhances the robustness of the model in complex field environments, enabling it to more accurately identify and detect pests.

[0029] (3) The present invention adds the RepVGG module to the neck network, which further enhances the feature extraction capability and reduces the computational complexity of the model while still maintaining a high detection accuracy.

[0030] (4) By replacing the original loss function with the MPDIoU loss function, the present invention optimizes the precise positioning of the bounding box and significantly improves the detection accuracy of the model for corn pests in complex backgrounds. It performs well in environments with dense distribution of multiple targets and occlusion, effectively reducing the missed detection rate and false detection rate of corn pests. BRIEF DESCRIPTION OF THE DRAWINGS

[0031] Figure 1 A schematic diagram of a process of corn pest monitoring method based on YOLO-FSRNet provided in an embodiment of the present invention;

[0032] Figure 2 A schematic diagram of a corn pest image provided by an embodiment of the present invention;

[0033] Figure 3 A schematic diagram of the YOLO-FSRNet network model structure provided by an embodiment of the present invention;

[0034] Figure 4 A schematic diagram of the FasterNet network and FasterNet Block module structure provided by an embodiment of the present invention;

[0035] Figure 5 A schematic diagram of the structure of the SEAttention module provided in an embodiment of the present invention;

[0036] Figure 6 A schematic diagram of the structure of a RepVGG module provided in an embodiment of the present invention;

[0037] Figure 7 A schematic diagram of corn pest monitoring results provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0038] In order to make the purpose, technical solution and advantages of the present invention clearer, the technical solution in the embodiment of the present invention will be clearly described below in conjunction with the drawings in the embodiment of the present invention. Obviously, the described embodiment is a part of the embodiment of the present invention, not all the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0039] An embodiment of the present invention provides a corn pest monitoring method based on YOLO-FSRNet, comprising:

[0040] Step 1: Collect corn pest images, annotate them, and build a high-quality corn pest dataset.

[0041] Specifically, a large number of corn pest images are collected, including corn borers, locusts and other types of corn pests, such as Figure 2As shown in the figure, the pests in the image are accurately labeled using the LabelImg image annotation tool, and the annotation content includes the category and location information of the corn pests;

[0042] Step 2: Build the YOLO-FSRNet network model based on the YOLOv8 network, such as Figure 2 As shown, it includes: replacing the backbone network of the YOLOv8 network with the FasterNet network, adding the SEAttention module to the backbone network and the neck network, and adding the RepVGG module to the neck network.

[0043] Step 2.1: Use the lightweight FasterNet network as the backbone feature extraction network to improve the inference speed of the model.

[0044] like Figure 3 As shown, the FasterNet network includes an Embedding layer, a first FasterNet Block module, a first Merging layer, a second FasterNet Block module, a second Merging layer, a third FasterNet Block module, a third Merging layer and a fourth FasterNet Block module.

[0045] It can be understood that the FasterNet network has a faster inference speed than the YOLOv8 backbone network and is suitable for real-time monitoring scenarios of corn pests.

[0046] Specifically, Figure 3 As shown in the figure, the core of the FasterNet network is the use of the FasterNet block module composed of a partial convolution layer (PConv) and a point-by-point convolution layer (PWConv). The FasterNet Block module includes a partial convolution layer, a point-by-point convolution layer and a residual structure. The partial convolution layer is a 3×3 convolution, and the point-by-point convolution layer is a 1×1 convolution. This structure greatly reduces the number of model parameters and computational complexity, and shortens the model inference time.

[0047] Step 2.2: Add the SEAttention module at the end of the backbone network and the neck network. The SEAttention module effectively enhances the network's ability to capture key features through an adaptive channel weight allocation mechanism.

[0048] Specifically, Figure 4 As shown in Figure 1, the SEAttention module adjusts the weights of the features of each channel by compression, excitation, and reweighting.

[0049] It can be understood that the SEAttention module adjusts the weights of the features of each channel to identify and highlight important feature information, making the network more accurate when processing complex scenes. This module not only improves the network's ability to understand and represent input data, but also enhances the model's ability to identify key features in complex backgrounds.

[0050] Step 2.3: Add the RepVGG module at the end of the neck network to further optimize the feature extraction and fusion capabilities while maintaining low complexity, effectively improving the detection accuracy of the model.

[0051] Specifically, Figure 6 As shown in the figure, the RepVGG module establishes residual connections through three paths, including: 3×3 convolution, 1×1 convolution and Identity; it enables the features to better retain key information during the transmission process, reduces the gradient vanishing problem, and enhances the expressiveness of the model.

[0052] Step 3: Use the high-quality corn pest dataset to train the YOLO-FSRNet network model to obtain the corn pest monitoring model.

[0053] Specifically, the dataset annotated in step 1 is divided into training set, validation set and test set in a ratio of 8:1:1, and then the YOLO-FSRNet network model is trained.

[0054] Before training the YOLO-FSRNet network model, first set the specific parameters of the model, such as setting the image size to 640×640, the number of training rounds to 300, the batch size to 16, and the initial learning rate to 0.01. After the parameters are set, the model is trained using the generated training set, and the training process is monitored in real time through the validation set. When the training iteration reaches about 230 rounds, the model stops training. At this time, the average accuracy on the validation set is about 90%, and the inference time for each image is about 1.4 milliseconds. Afterwards, the trained YOLO-FSRNet model and YOLOv8 model are used to verify the test set. The results show that the average accuracy of the YOLO-FSRNet model is about 3% lower than that of the YOLOv8 model, but the inference speed is increased by about 30%.

[0055] like Figure 6 As shown in Figure 1, the RepVGG module in the corn pest monitoring model merges the three paths of the RepVGG module in the training phase into one 3×3 convolutional layer to improve the inference speed.

[0056] Furthermore, the MPDIoU loss function is used when training the YOLO-FSRNet network model. The MPDIoU loss function formula is as follows:

[0057]

[0058] Among them, h represents the input image height, w represents the input image width, Represents the Euclidean distance between the upper left corner of the prediction box and the upper left corner of the target box, It represents the Euclidean distance between the lower right corner of the prediction box and the lower right corner of the target box. IoU represents the intersection over union ratio between the prediction box and the target box. The prediction box is the output of the corn pest monitoring model, and the target box is the box manually annotated in the image in advance.

[0059] Step 4: Deploy the corn pest monitoring model on the terminal device to monitor and identify corn pests.

[0060] Specifically, the trained YOLO-FSRNet network model is deployed on terminal devices equipped with memory, GPU processor, high-precision camera and display screen to monitor and identify corn pests;

[0061] The memory is used to store the trained YOLO-FSRNet model and detection data, the GPU processor provides efficient computing power to support real-time image processing and detection, the high-precision camera is used to collect high-resolution images in real time, and the display screen is used to display the monitoring results in real time, so that users can view the detection information of corn pests in a timely manner.

[0062] Specifically, monitoring and identification of corn pests include:

[0063] Acquire the image of corn to be monitored through a high-precision camera;

[0064] The backbone network of the corn pest monitoring model is used to extract the features of the corn image to be monitored;

[0065] The neck network of the corn pest monitoring model is used to adjust the weight of each feature information and perform feature fusion on multiple feature information;

[0066] The head network of the corn pest monitoring model is used to determine whether there are pests in the corn image to be monitored. When pests are present in the corn image to be monitored, the location of the pests and the type of pests are marked in the corn image to be monitored through the display screen. The model detection results are as follows: Figure 7 shown.

[0067] The method obtained through the above steps is a corn pest monitoring method based on YOLO-FSRNet. This method replaces the YOLOv8 backbone network with FasterNet and introduces the SEAttention module and the RepVGG module. While ensuring high recognition accuracy, it significantly improves the inference speed. This method is suitable for real-time monitoring of corn pests in practical application scenarios.

[0068] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims

1. A corn pest monitoring method based on YOLO-FSRNet, characterized in that: include: Step 1: Collect corn pest images, annotate and build a high-quality corn pest dataset; Step 2: Build the YOLO-FSRNet network model based on the YOLOv8 network, including: replacing the backbone network of the YOLOv8 network with the FasterNet network, adding the SEAttention module to the backbone network and the neck network, and adding the RepVGG module to the neck network; Step 3: Using the high-quality corn pest dataset to train the YOLO-FSRNet network model to obtain a corn pest monitoring model; Step 4: Deploy the corn pest monitoring model on the terminal device to monitor and identify corn pests.

2. A corn pest monitoring method based on YOLO-FSRNet according to claim 1, characterized in that: In step 1, the LabelImg image annotation tool is used to accurately annotate the pests in the image, and the annotation content includes the category and location information of the corn pests.

3. A corn pest monitoring method based on YOLO-FSRNet according to claim 1, characterized in that: In step 2, the FasterNet network includes an Embedding layer, a first FasterNet Block module, a first Merging layer, a second FasterNet Block module, a second Merging layer, a third FasterNet Block module, a third Merging layer and a fourth FasterNet Block module; the FasterNet Block module includes a partial convolution layer, a point-by-point convolution layer and a residual structure.

4. A corn pest monitoring method based on YOLO-FSRNet according to claim 1, characterized in that: In step 2, the SEAttention module is added to the end of the backbone network and the neck network, and the weight of the features of each channel is adjusted by compression, excitation and re-weighting.

5. A corn pest monitoring method based on YOLO-FSRNet according to claim 1, characterized in that: In step 2, the RepVGG module establishes residual connections through three paths, including: 3×3 convolution, 1×1 convolution, and Identity.

6. A corn pest monitoring method based on YOLO-FSRNet according to claim 1, characterized in that: The RepVGG module in the corn pest monitoring model merges the three paths in the training phase into a 3×3 convolutional layer.

7. A corn pest monitoring method based on YOLO-FSRNet according to claim 1, characterized in that: The MPDIoU loss function is used when training the YOLO-FSRNet network model. The MPDIoU loss function formula is as follows: Among them, h represents the input image height, w represents the input image width, Represents the Euclidean distance between the upper left corner of the prediction box and the upper left corner of the target box, It represents the Euclidean distance between the lower right corner of the prediction box and the lower right corner of the target box, and IoU represents the intersection over union of the prediction box and the target box.

8. The corn pest monitoring method based on YOLO-FSRNet according to claim 1, characterized in that: The terminal device includes a memory, a GPU processor, a high-precision camera and a display screen; The memory is used to store the corn pest monitoring model and monitoring data, the GPU processor is used to provide efficient computing power to support real-time image processing and detection, the high-precision camera is used to collect high-resolution images in real time, and the display screen is used to display monitoring results in real time.

9. A corn pest monitoring method based on YOLO-FSRNet according to claim 8, characterized in that: The monitoring and identification of corn pests includes: Acquire the image of corn to be monitored through a high-precision camera; Extracting features of the corn image to be monitored using the backbone network of the corn pest monitoring model; The neck network of the corn pest monitoring model is used to adjust the weight of each feature information, and to perform feature fusion on multiple feature information; The head network of the corn pest monitoring model is used to determine whether there are pests in the corn image to be monitored, and when pests are present in the corn image to be monitored, the location of the pests is marked and the type of pests is identified in the corn image to be monitored through the display screen.