Incremental depth transfer learning method and system for remote sensing real-time detection of crop diseases and insect pests
By using incremental deep transfer learning methods and IoT sensor data, the model structure and loss function are dynamically adjusted to solve the problems of data scarcity and insufficient adaptability in remote sensing detection of crop pests and diseases, and achieve efficient pest and disease identification and real-time monitoring.
Patent Information
- Application Number
- CN202510741887.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-05
- Publication Date
- 2025-09-19
- Estimated Expiration
- 2045-06-05
AI Technical Summary
Existing technologies in remote sensing detection of crop diseases and insect pests suffer from data scarcity and insufficient model generalization capabilities, making it difficult to adapt to dynamically changing types of diseases and insect pests and crop varieties, resulting in low detection accuracy and efficiency.
An incremental deep transfer learning method is adopted to transfer the knowledge of the source model to the target task through pest and disease feature domain alignment technology and incremental learning mechanism. Combined with IoT sensor data, the model structure and weights are dynamically adjusted, and the loss function is optimized to adapt to new pest and disease types and crop varieties.
It significantly improves the accuracy of pest and disease identification and monitoring efficiency under small sample conditions, realizes real-time detection and early warning, simplifies the operation steps, and adapts to the detection performance of different regions and crops.
Smart Images

Figure CN120673270A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to a method and system for crop disease and insect pest detection, and in particular to an incremental deep transfer learning method and system for real-time remote sensing detection of crop diseases and insect pests. Background Art
[0002] Early detection of crop pests and diseases is crucial for agricultural production. Traditional pest and disease detection methods rely primarily on manual observation and empirical judgment. This approach is not only inefficient but also has limited accuracy, making it difficult to meet the demands of modern agricultural production. With the development of remote sensing and deep learning technologies, automated pest and disease detection methods have gradually become a research hotspot. Remote sensing technology, using sensors carried by satellites or drones, can rapidly capture the growth status of crops and the occurrence of pests and diseases over large areas. Deep learning technology, particularly convolutional neural networks (CNNs), excels in image recognition and classification tasks, providing powerful technical support for automated detection.
[0003] However, existing technologies have some limitations in remote sensing detection of crop pests and diseases. First, crop pest and disease image data is complex and diverse, and pests and diseases manifest differently in different regions, different crops, and different growth cycles. Second, high-quality annotated data is relatively scarce, and this data is key to training deep learning models. In addition, existing deep learning models usually require a large amount of annotated data for training, but in the field of crop pest and disease detection, obtaining sufficient annotated data is very difficult, which limits the performance and generalization ability of the model. More importantly, the types and varieties of crop pests and diseases are dynamic, requiring the model to constantly adapt to new situations. Therefore, a new technical solution is needed to solve the above problems. Summary of the Invention
[0004] Purpose of the invention: The purpose of the present invention is to provide an incremental deep transfer learning method and system for real-time remote sensing detection of crop diseases and insect pests, which solves the problem of disease and insect pest identification under small sample conditions, and can dynamically adapt to new disease and insect pest types or crop varieties, significantly improving the early detection accuracy and monitoring efficiency of crop diseases and insect pests.
[0005] Technical Solution: The present invention provides an incremental deep transfer learning method for real-time remote sensing detection of crop pests and diseases, comprising:
[0006] (1) Use remote sensing equipment and IoT sensors to collect crop image data and environmental data and perform preprocessing;
[0007] (2) Build a source model;
[0008] (3) Through the pest and disease feature domain alignment technology and incremental learning mechanism, the knowledge of the source model is dynamically transferred to the target task to adapt to new pest and disease types or crop varieties;
[0009] (4) Train and optimize the model to adapt to pest and disease detection tasks;
[0010] (5) Use the test set to evaluate the detection results of the model;
[0011] (6) Iterative improvement based on feedback, adjusting and optimizing the model according to the evaluation results.
[0012] Preferably, the preprocessing includes image cropping to remove non-crop areas in the image; image denoising to eliminate high-frequency noise and salt and pepper noise in the image using Gaussian filtering and median filtering; using histogram equalization to enhance the contrast and clarity of the image; data enhancement by adjusting the image resolution through scaling and rotating the image; and fusing the remote sensing image data with the environmental data collected by the Internet of Things sensor to form a comprehensive feature vector.
[0013] Preferably, the step (2) comprises:
[0014] (21) Extracting feature representations of crop images through source models;
[0015] (22) Extract features from the source domain data and target domain data respectively, perform Wasserstein distance optimization, and minimize the Wasserstein distance value through gradient descent to achieve domain alignment;
[0016] (23) When encountering new types of pests and diseases or crop varieties, the model structure is dynamically adjusted, new classification layers or feature extraction layers are added, and only the newly added parts and associated layers are trained.
[0017] Preferably, during the model training process, the model weight is adjusted using the following formula:
[0018]
[0019] Among them, w t represents the weight at time step t, α is the learning rate, L(w t ) is the loss function under the current weight.
[0020] Preferably, the model optimization includes using a triple adaptive fusion comprehensive loss function of cross entropy loss, focal loss and contrast loss, and the formula is:
[0021]
[0022] Among them, α and β are balance coefficients, which are used to balance the weights of different loss functions; LCE , L Focal , L Contrastive They are cross entropy loss, focal loss and contrastive loss respectively.
[0023] Preferably, in step (5), the detection results of the model are evaluated using an independently labeled pest and disease image dataset, and the indicators include accuracy, recall rate, and F1-score.
[0024] Preferably, during the model training, the performance indicators of the model on the validation set are monitored, and the weights and learning rates are dynamically adjusted according to the performance on the validation set. An early stopping mechanism is adopted. When the performance indicators on the validation set do not improve within a certain number of iteration cycles, the training is stopped in advance to prevent the model from overfitting.
[0025] The present invention provides an incremental deep transfer learning system for real-time remote sensing detection of crop diseases and insect pests, comprising:
[0026] Data acquisition and processing unit: used to collect crop image data and environmental data using remote sensing equipment and IoT sensors, and perform pre-processing;
[0027] Model building unit: used to build source model;
[0028] Model training unit: This unit is used to dynamically transfer the knowledge of the source model to the target task through pest and disease feature domain alignment technology and incremental learning mechanism, and train and optimize the model to adapt to pest and disease detection tasks;
[0029] Evaluation and feedback unit: used to evaluate the detection results of the model using the test set; based on the iterative improvement of feedback, the model is adjusted and optimized according to the evaluation results.
[0030] A computer device comprises one or more processors, a memory, and one or more programs, wherein the one or more programs are stored in the memory and configured to be executed by the one or more processors, and when the programs are executed by the processors, the steps of the incremental deep transfer learning method for real-time remote sensing detection of crop diseases and insect pests are implemented.
[0031] A computer-readable storage medium stores a computer program, which, when executed by a processor, implements the steps of an incremental deep transfer learning method for real-time remote sensing detection of crop pests and diseases.
[0032] Beneficial effects: Compared with the existing technology, the present invention has the following significant advantages: (1) Through the pest and disease feature domain alignment technology, it can quickly adapt to new crop pest and disease detection tasks; (2) The transfer learning of the source model significantly improves the recognition accuracy under small sample conditions; (3) The adaptive weight adjustment mechanism and incremental learning mechanism ensure the detection performance of the model in different regions, different crops and different pest and disease types; (4) Combined with the Internet of Things technology, real-time monitoring and early warning of pest and disease detection are realized; (5) The end-to-end monitoring process simplifies the operation steps and is easy to apply in actual production. BRIEF DESCRIPTION OF THE DRAWINGS
[0033] Figure 1 The figure is a flow chart of the method of the present invention.
[0034] Figure 2 Schematic diagram of data preprocessing of the present invention.
[0035] Figure 3 Schematic diagram of the process of aligning pest and disease feature domains.
[0036] Figure 4 This is a schematic diagram of incremental learning of the present invention.
[0037] Figure 5 Schematic diagram of the TriFAL loss function optimization process of the present invention. DETAILED DESCRIPTION
[0038] The technical solution of the present invention will be further described below with reference to the accompanying drawings.
[0039] The present invention provides an incremental deep transfer learning method for real-time remote sensing detection of crop pests and diseases. Figure 1 Shown, including:
[0040] (1) Use remote sensing equipment and IoT sensors to collect crop image data and environmental data and perform preprocessing;
[0041] Specifically, multispectral or hyperspectral sensors carried by drones or satellites are used to collect crop image data. The drone's flight altitude is appropriately set based on the crop type and pest characteristics to ensure the image resolution meets detection requirements. Simultaneously, IoT sensors are deployed in the fields to collect real-time environmental data (such as temperature, humidity, and light).
[0042] Select representative crop planting areas, covering different growth stages and pest and disease occurrences.
[0043] Collect image data including visible light, near-infrared and other bands, as well as environmental data such as temperature, humidity, and light intensity to fully reflect the health status of crops.
[0044] After data collection, the following preprocessing steps are performed, such as Figure 2 As shown:
[0045] Image cropping: Remove non-crop areas (such as soil and roads) from the image to ensure that the image data is focused on the target crop. Cropping the image to a uniform size facilitates subsequent model input.
[0046] Image denoising: Gaussian filtering and median filtering techniques are used to remove high-frequency noise and salt and pepper noise, respectively. The filter kernel size is selected based on the image resolution and noise level.
[0047] Contrast enhancement: Use histogram equalization or adaptive histogram equalization (CLAHE) technology to improve the contrast and clarity of the image and highlight the characteristics of pests and diseases.
[0048] Data augmentation: Adjust image resolution by scaling to fit the model input requirements; use rotation to correct images to ensure consistent crop orientation; and expand the dataset by flipping, adjusting brightness, etc. This enhances the model's generalization capabilities.
[0049] Data fusion: Fuse remote sensing image data with environmental data collected by IoT sensors to form a comprehensive feature vector for model input.
[0050] (2) Build a source model;
[0051] Select a pre-trained deep learning model that performs well on pest and disease identification tasks, such as ResNet or VGG, as the source model. This model has been trained on a large amount of image data and has rich feature extraction capabilities. Remove the top classification layer of the model, retaining the feature extraction portion.
[0052] (3) Through the pest and disease feature domain alignment technology and incremental learning mechanism, the knowledge of the source model is dynamically transferred to the target task to adapt to new pest and disease types or crop varieties;
[0053] Specifically, the feature domain alignment technology of pests and diseases is used to dynamically transfer the feature extraction capability of the source model to the target detection task. Figure 3 Shown, including:
[0054] (31) Feature Mapping: Extract feature representations of crop images through the source model. The preprocessed crop image data is input into the source model. The source model undergoes operations such as convolutional layers and pooling layers to extract low-level features such as edges, textures, and shapes from the image, as well as high-level semantic features specific to pests and diseases. The extracted feature vectors are recorded and used as the basis for subsequent feature domain alignment.
[0055] (32) Feature domain alignment: Extract features from the source domain data (e.g., a public pest and disease dataset) and the target domain data (e.g., the data collected in the examples); perform Wasserstein distance optimization: Use the Wasserstein distance to measure the difference between the source and target domain feature distributions. Domain alignment is achieved by minimizing the Wasserstein distance using a gradient descent optimization algorithm.
[0056] (33) Incremental learning: When encountering new pest and disease types or crop varieties, the model structure is dynamically adjusted, new classification layers or feature extraction layers are added, and only the newly added parts and associated layers are trained, while most of the parameters of the original model are retained. The details are as follows:
[0057] After identifying a new pest or disease type or crop variety, determine the number and structure of additional classification or feature extraction layers. Based on the source model, add the new classification or feature extraction layers and train the new layers and their associated layers. During training, freeze most of the parameters of the original model, and only update the parameters of the new layers and associated layers. After training is complete, integrate the new layers with the original model to form a target model adapted to the new task.
[0058] (4) Train and optimize the model to adapt to pest and disease detection tasks;
[0059] The training optimization includes:
[0060] (41) Loss function design
[0061] Cross entropy loss: As a basic loss function, it is used to measure the difference between the model prediction and the true label. Its formula is:
[0062] L CE =-∑y i log(p i )
[0063] Among them, y i represents the true label, p i Represents the probability that the model predicts class i.
[0064] Focal Loss: Focal loss is introduced to solve the problem of class imbalance and enhance the model's ability to identify small sample classes. By adjusting the balance factor and focus parameter, the model's attention to difficult and easy samples is optimized. The formula for focal loss is:
[0065] L Focal =-(1-p t ) γ log(p t )
[0066] Among them, pt is the probability predicted by the model, indicating the probability that the model predicts that the sample belongs to the true category t. γ is a focusing parameter that controls the degree of attention paid to difficult and easy samples. It can take values such as 0, 0.5, 1, and 2. A larger value indicates more attention paid to difficult samples.
[0067] Contrastive Loss: Through the idea of contrastive learning, the model can better distinguish the characteristics of different categories of pests and diseases. Figure 5 As shown, the contrast loss formula is:
[0068] L Contrastive =∑‖f(x i )-f(x j )‖ 2 +max(0,m-‖f(x k )-f(x l )‖)
[0069] Among them, f(x i ) represents x i The feature representation of the model is the feature vector extracted by the model, x i 、x j Sample pairs belonging to the same category, x k 、x l For pairs of samples belonging to different categories, m represents the preset distance threshold (margin), which is used to distinguish the minimum distance between samples of different categories.
[0070] (42) Adaptive weight adjustment
[0071] Dynamically adjust weights and learning rates based on the model's performance during training. Use early stopping to prevent overfitting and ensure optimal model performance on the validation set. Specific steps are as follows:
[0072] During training, monitor the model's performance on the validation set, such as accuracy and loss. Dynamically adjust the weights and learning rate based on the validation set's performance. For example, if the validation set's loss stops decreasing after several iterations, reduce the learning rate to further optimize the model. Use an early stopping mechanism to stop training early if performance on the validation set doesn't improve significantly within a certain number of iterations to prevent overfitting.
[0073] (5) Use the test set to evaluate the detection results of the model;
[0074] (6) Iterative improvement based on feedback, adjusting and optimizing the model according to the evaluation results.
[0075] Based on transfer learning, the model is further optimized, including:
[0076] (61) Weight adjustment: According to the loss function L(w t ), use gradient descent to adjust the model weight W t The specific steps are as follows:
[0077] Calculate the gradient of the loss function with respect to the model weights:
[0078]
[0079] Among them, W t represents the weight at time step t, α is the learning rate, L(W t ) is the loss function under the current weight.
[0080] (62) Loss function optimization: Focal Loss is introduced to solve the problem of class imbalance and enhance the model's ability to recognize small sample classes. The specific operations are as follows:
[0081] During model training, focus loss is combined with cross entropy loss and contrast loss to form a comprehensive loss function to optimize model performance. The formula of the comprehensive loss function is:
[0082]
[0083] Among them, α and β are balance coefficients used to balance the weights of different loss functions. CE , L Focal , L Contrastive They are cross entropy loss, focal loss and contrastive loss respectively.
[0084] The present invention also provides an incremental deep transfer learning system for real-time remote sensing detection of crop diseases and insect pests, comprising:
[0085] Data acquisition and processing unit: used to collect crop image data and environmental data using remote sensing equipment and IoT sensors, and perform pre-processing;
[0086] Model building unit: used to build source model;
[0087] Model training unit: This unit is used to dynamically transfer the knowledge of the source model to the target task through pest and disease feature domain alignment technology and incremental learning mechanism, and train and optimize the model to adapt to pest and disease detection tasks;
[0088] Evaluation and feedback unit: used to evaluate the detection results of the model using the test set; based on the iterative improvement of feedback, the model is adjusted and optimized according to the evaluation results.
Claims
1. An incremental deep transfer learning method for real-time remote sensing detection of crop pests and diseases, characterized by: include: (1) Use remote sensing equipment and IoT sensors to collect crop image data and environmental data and perform preprocessing; (2) Build a source model; (3) Through the pest and disease feature domain alignment technology and incremental learning mechanism, the knowledge of the source model is dynamically transferred to the target task to adapt to new pest and disease types or crop varieties; (4) Train and optimize the model to adapt to pest and disease detection tasks; (5) Use the test set to evaluate the detection results of the model; (6) Iterative improvement based on feedback, adjusting and optimizing the model according to the evaluation results.
2. The incremental deep transfer learning method for real-time remote sensing detection of crop pests and diseases according to claim 1, characterized in that: The preprocessing includes image cropping to remove non-crop areas in the image; image denoising to remove high-frequency noise and salt and pepper noise in the image using Gaussian filtering and median filtering; Use histogram equalization to improve image contrast and clarity; Data enhancement is performed by adjusting image resolution by scaling and rotating the image; remote sensing image data is fused with environmental data collected by IoT sensors to form a comprehensive feature vector.
3. The incremental deep transfer learning method for real-time remote sensing detection of crop diseases and insect pests according to claim 1, characterized in that: The step (2) comprises: (21) Extracting feature representations of crop images through source models; (22) Extract features from the source domain data and target domain data respectively, perform Wasserstein distance optimization, and minimize the Wasserstein distance value through gradient descent to achieve domain alignment; (23) When encountering new types of pests and diseases or crop varieties, the model structure is dynamically adjusted, new classification layers or feature extraction layers are added, and only the newly added parts and associated layers are trained.
4. The incremental deep transfer learning method for real-time remote sensing detection of crop diseases and insect pests according to claim 1, characterized in that: During the model training process, the model weights are adjusted using the following formula: Among them, w t represents the weight at time step t, α is the learning rate, L(w t ) is the loss function under the current weight.
5. The incremental deep transfer learning method for real-time remote sensing detection of crop diseases and insect pests according to claim 1, characterized in that: The model optimization includes using a triple adaptive fusion comprehensive loss function of cross entropy loss, focal loss and contrast loss, and the formula is: ▽L total =▽L CE +α▽L Focal +β▽L Contrastive Among them, α and β are balance coefficients, which are used to balance the weights of different loss functions; L CE , L Focal , L Contrastive They are cross entropy loss, focal loss and contrastive loss respectively.
6. The incremental deep transfer learning method for real-time remote sensing detection of crop pests and diseases according to claim 1, characterized in that: The step (5) uses an independently labeled pest and disease image dataset to evaluate the detection results of the model, and the indicators include accuracy, recall rate, and F1-score.
7. The incremental deep transfer learning method for real-time remote sensing detection of crop diseases and insect pests according to claim 1, characterized in that: During model training, the performance indicators of the model on the validation set are monitored, and the weights and learning rates are dynamically adjusted based on the performance on the validation set. An early stopping mechanism is adopted. When the performance indicators on the validation set do not improve within a certain number of iteration cycles, the training is stopped in advance to prevent the model from overfitting.
8. An incremental deep transfer learning system for real-time remote sensing detection of crop pests and diseases, characterized by: include: Data acquisition and processing unit: used to collect crop image data and environmental data using remote sensing equipment and IoT sensors, and perform pre-processing; Model building unit: used to build source model; Model training unit: This unit is used to dynamically transfer the knowledge of the source model to the target task through pest and disease feature domain alignment technology and incremental learning mechanism, and train and optimize the model to adapt to pest and disease detection tasks; Evaluation feedback unit: used to evaluate the detection results of the model using the test set; Feedback-based iterative improvement, adjusting and optimizing the model according to the evaluation results.
9. A computer device, characterized in that: The invention comprises one or more processors, a memory and one or more programs, wherein the one or more programs are stored in the memory and are configured to be executed by the one or more processors, and when the programs are executed by the processors, the steps of an incremental deep transfer learning method for real-time remote sensing detection of crop diseases and insect pests as described in any one of claims 1 to 7 are implemented.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of an incremental deep transfer learning method for real-time remote sensing detection of crop diseases and insect pests as described in any one of claims 1 to 7 are implemented.
Citation Information
Patent Citations
Small sample learning classification method for fruit and vegetable disease identification
CN116843952A
Remote sensing image classification and farmland identification method based on deep learning
CN119580088A
Crop disease and pest identification method based on agricultural production service platform
CN119622635A
Disease and pest detection method based on deep learning and transfer learning
CN119992308A
High-resolution remote sensing image accurate classification system and method based on deep learning multi-modal fusion
CN120047721A