Classification method for multi-scale feature enhancement of rice leaf diseases
Through the ASTNet model of frequency-space dual-domain data enhancement, all-round attention coordination module and multi-scale pyramid fusion module, the robustness and multi-scale feature capture problems of rice disease recognition in complex field environments are solved, and efficient rice leaf disease recognition is achieved.
Patent Information
- Application Number
- CN202510529392.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-24
- Publication Date
- 2025-08-08
AI Technical Summary
The existing rice disease identification methods are not robust enough in complex field environments, and are difficult to adapt to multi-light changes, occlusion and noise interference. In addition, traditional models are difficult to capture multi-scale lesions, resulting in low recognition efficiency and high misjudgment rate.
The data set is generated using the frequency-space dual-domain collaboration enhancement strategy, and combined with the all-round attention coordination module and the multi-scale pyramid fusion module, an ASTNet model is formed to enhance the multi-scale feature extraction and environmental adaptability of rice leaf diseases.
The accuracy and robustness of rice leaf disease recognition have been significantly improved. The Top-1 accuracy rate is 81.20%, the average F1 score is 80.34%, the accuracy rate of healthy leaf recognition is 100%, and the recall rate of rice blast is 89.09%, overcoming the problem of insufficient feature extraction ability of traditional models in complex environments.
Smart Images

Figure CN120451785A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of agriculture, and in particular to a classification method for rice leaf diseases with multi-scale feature enhancement. Background Art
[0002] Accurately identifying rice diseases is crucial to ensuring food security. However, traditional manual detection methods are inefficient, rely on operator experience, and are susceptible to subjective factors, leading to missed detections, misjudgments, and delayed prevention and control efforts. Although deep learning technology offers new insights into disease identification, existing methods face significant challenges in complex field environments. Convolutional neural network (CNN)-based methods (such as ResNet and VGG) possess local feature extraction capabilities, but they are inadequate for capturing multi-scale lesion characteristics and are susceptible to generalization performance issues such as illumination variations, occlusions, and noise. Transformer-based methods (such as VisionTransformer) improve semantic modeling capabilities through global attention mechanisms, but their high computational complexity and large number of parameters make them difficult to adapt to the requirements of lightweight mobile deployment.
[0003] In addition, most existing studies construct datasets based on laboratory environments and lack the modeling of real-world interference factors (such as dust, uneven plant density, and equipment imaging differences), resulting in insufficient robustness of the model in actual scenarios. Another bottleneck of existing technologies is the single data enhancement strategy. Most studies only use geometric transformations (rotation, scaling) or simple noise injection, which fails to effectively simulate complex field environmental variables (such as multispectral interference and equipment defects), limiting the model's adaptability to different scenarios. At the same time, insufficient coverage of disease types (for example, most studies only identify 3-5 types of diseases) and weak cross-variety generalization capabilities further restrict the practical application of the technology.
[0004] Therefore, technicians in this field are committed to developing a rice disease identification method that takes into account multi-scale feature enhancement, environmental robustness and lightweight deployment to meet the complex challenges in real agricultural scenarios. Summary of the Invention
[0005] In view of the above-mentioned defects of the prior art, the technical problem to be solved by the present invention is how to develop a rice disease identification method that takes into account multi-scale feature enhancement, environmental robustness and lightweight deployment.
[0006] To achieve the above objectives, the present invention provides a classification method for rice leaf diseases by multi-scale feature enhancement, comprising the following steps:
[0007] Step 1: Collect initial data of rice leaves to obtain an initial dataset of large-scale field images;
[0008] Step 2: The initial data set obtained in step 1 is enhanced by using the frequency-space dual-domain collaborative enhancement strategy;
[0009] Step 3: Merge the initial dataset obtained in step 1 with the enhanced dataset obtained in step 2 to obtain a self-made dataset, and integrate the Omnidirectional Attention Collaboration Module (OSAS) and the Multi-Scale Pyramid Fusion Module (MSPF) into a model with SwinTransformer as the core to form a deep learning classification model ASTNet;
[0010] Step 4: Import the self-made dataset obtained in step 3 into the ASTNet model obtained in step 4, conduct a classification experiment on eight rice leaf feature states, and obtain eight feature classification results.
[0011] Furthermore, step 1 also includes: retrieving an initial image set containing seven types of pathological features and healthy leaves through the large-scale data platform Kaggle, and performing a three-level data cleaning process on the collected images to obtain an initial data set.
[0012] Furthermore, the seven types of pathological characteristics are bacterial leaf blight, brown spot, rice blast, leaf burn, narrow brown leaf spot, rice wilt and sheath blight; the three-level data cleaning process is as follows: remove artificial background or segmented leaf samples to retain the real image of the interaction between the complete plant and the environment; filter low-quality images with a resolution lower than 1200x1600 to ensure that the texture characteristics of the lesions are clearly discernible; standardize the image size to 1200x1600 pixels to eliminate scale variations caused by equipment differences.
[0013] Furthermore, the frequency-space dual-domain collaborative enhancement strategy in step 2 is: injecting simulated field environment interference into the initial data set through Fourier transform, spatial domain noise and spatial domain conventional transform, including frequency domain enhancement and spatial domain enhancement steps.
[0014] Furthermore, the frequency domain enhancement step is as follows: Fourier transform is applied to decompose the image into amplitude spectrum and phase spectrum, and five illumination variation samples are generated by randomly adjusting the spectral components to effectively simulate the solar spectrum characteristics and device white balance deviation at different time periods; the plane wave formula is shown in Formula 1:
[0015]
[0016] Where x and y are the coordinates of the pixels in the image, with the center of the image as the origin; f is the frequency of the plane wave; θ is the direction angle of the plane wave; the random sampling formula for frequency and phase is shown in Formula 2:
[0017]
[0018] Where f is uniformly randomly selected from the predefined frequency list [1, 2, 3] and normalized to the image width dimension; φ is uniformly sampled from the interval [-2π, 0] with a compensation of 64; the amplitude intensity adjustment formula is shown in Formula 3:
[0019] A~Exponential(Λ=mean_str)+min_str Formula 3,
[0020] Where mean_str is the average intensity parameter; min_str is the minimum intensity parameter; the formula for synthesizing the enhanced image is shown in Formula 4:
[0021]
[0022] Among them I original is the original image, normalized to [0,1]; N f The number of frequencies sampled for each channel; N p The number of phases sampled for each frequency; ∈ scale is the scaling factor, which is determined by the image width; Clip(·) limits the enhanced pixel value to the range of [0,1].
[0023] Furthermore, the spatial domain enhancement steps include: injecting Gaussian noise, Laplace noise, Poisson noise, impulse noise, Gaussian blur, grayscale mask occlusion, horizontal flip, vertical flip, scaling, and rotation to simulate device defects and environmental interference; the formula for Gaussian noise is shown in Formula 5:
[0024]
[0025] The mean μ1 is fixed to 0, and the noise is symmetrically distributed on both sides of 0; the standard deviation σ1 is defined as σ∈[0,51]; the formula for Laplace noise is shown in Formula 6:
[0026]
[0027] The mean μ2 is fixed to 0, and the noise is symmetrically distributed on both sides of 0. The scale parameter b determines the diffusion of the noise. The larger the b value, the wider the noise range. The formula for Poisson noise is shown in Formula 7:
[0028]
[0029] The mean Λ controls the noise intensity; the actual noise value: obeys Poisson(Λ)-Λ, with a mean of 0 and a variance of Λ; the formulas for impulse noise are Equation 8 and Equation 9:
[0030] AddNoise(x,y)~Bernoulli(p) formula 8,
[0031]
[0032] The formula for Gaussian blur is shown in Formula 10:
[0033]
[0034] Where (x, y) is the coordinate of the pixel relative to the center of the Gaussian kernel, and σ2 is the standard deviation, which controls the "diffusion degree" of the Gaussian kernel. The larger the value of σ2, the wider the Gaussian kernel and the stronger the blur.
[0035] Furthermore, the omnidirectional attention collaborative module in step 3: parallel spatial attention, channel attention and multi-scale convolutional attention mechanism, enhances the ability to locate the lesion area, and finally outputs the fused three-way features; the multi-scale pyramid fusion module alleviates the problem of deep network feature degradation through cross-stage feature fusion and spatial pyramid pooling.
[0036] Furthermore, spatial attention is specifically: generating a spatial weight matrix through pooling operation to focus on the lesion area; channel attention is specifically: screening discriminative feature channels through global average pooling; multi-scale convolution attention is specifically: using different convolution kernels to capture multi-granularity lesion details.
[0037] Furthermore, the multi-scale pyramid fusion module further includes the following steps:
[0038] (1) Cross-stage feature fusion: aligning shallow high-resolution features with deep semantic features;
[0039] (2) Spatial pyramid pooling: integrating multi-scale contextual information to enhance the recognition of small lesions;
[0040] (3) Residual enhancement output.
[0041] Furthermore, step 4 also includes: experimental result analysis, confusion matrix analysis, method evaluation, comparative experiment and ablation experiment; the method evaluation is to use ROC curve and PR curve to evaluate the performance of ASTNet architecture respectively; the ablation experiment is to verify the effectiveness and combined advantages of the omnidirectional attention collaboration module and multi-scale pyramid fusion module in the ASTNet architecture through systematic ablation experiments.
[0042] Furthermore, the multi-scale feature enhancement model ASTNet is based on the Swin Transformer framework, integrating the Omnidirectional Attention Collaboration (OSAS) module and the Multi-Scale Pyramid Fusion (MSPF) module to enhance the multi-scale feature expression capability.
[0043] Furthermore, the Omnidirectional Attention Synergy (OSAS) mechanism combines spatial attention, channel attention, and multi-scale convolutional attention in parallel to collaboratively optimize feature responses from the spatial, channel, and scale dimensions.
[0044] Furthermore, the Multi-Scale Pyramid Fusion (MSPF) mechanism combines cross-stage feature alignment with Spatial Pyramid Pooling (SPP) to fuse feature maps of different resolutions and retain multi-scale contextual information.
[0045] Furthermore, frequency-space dual-domain data enhancement is performed to simulate sensor noise (such as color temperature offset) in the frequency domain and physical interference (such as rain and fog obstruction) in the space domain, covering the parametric modeling of equipment defects and environmental variables.
[0046] In the preferred embodiment 1 of the present invention, the use process of a classification method for rice leaf diseases with multi-scale feature enhancement for complex agricultural scenarios is described in detail;
[0047] In preferred embodiment 2 of the present invention, the process of class-specific analysis is described in detail;
[0048] In the preferred embodiment 3 of the present invention, the process of verifying the classification performance using the confusion matrix is described in detail;
[0049] In preferred embodiment 4 of the present invention, the process of constructing a closed-loop optimization framework through interpretable analysis is described in detail.
[0050] The beneficial technical effects of the present invention are as follows:
[0051] This invention addresses the limited performance of existing models in complex agricultural scenarios. Existing models have poor adaptability to complex conditions such as changing lighting, leaf adhesion, and muddy water contamination, resulting in low accuracy. The model achieves a Top-1 accuracy of 81.20% and an average F1 score of 80.34%, significantly improving over the baseline model. The model achieves 100% accuracy in identifying healthy leaves and an 89.09% recall rate for rice blast.
[0052] This overcomes the problem of traditional models struggling to balance local lesion details with global semantic associations, and of small lesions being easily distracted by background noise, leading to insufficient feature extraction. It significantly improves the model's ability to discern subtle lesions (e.g., an F1 score of 82% for rice blast) and enhances robustness against complex backgrounds.
[0053] This improves the traditional model's multi-scale feature degradation problem, where the deep network loses shallow details and the small-scale lesion features are severely degraded. This alleviates the problem of small lesion feature degradation and improves the model's sensitivity to targets of varying sizes (e.g., a 93.56% recall rate for sheath blight).
[0054] Traditional enhancement methods struggle to simulate real-world device defects and environmental interference, resulting in weak model generalization and insufficient data diversity. This paper constructs a large-scale enhancement dataset of 9,922 images, significantly improving the model's generalization in complex scenarios (for example, the AP value for leaf burn was optimized from 58% to a higher level).
[0055] The concept, specific structure and technical effects of the present invention will be further described below in conjunction with the accompanying drawings to fully understand the purpose, characteristics and effects of the present invention. BRIEF DESCRIPTION OF THE DRAWINGS
[0056] Figure 1 This is a structural diagram of a method of a preferred embodiment 1 of the present invention;
[0057] Figure 2 This is a structural diagram of the ASTNet model used in the experiment of a preferred embodiment 1 of the present invention;
[0058] Figure 3 Schematic diagram of the collection, preprocessing and enhancement of a self-made data set according to a preferred embodiment 1 of the present invention;
[0059] Figure 4 This is a structural diagram of an Omnidirectional Attention Collaboration (OSAS) module according to a preferred embodiment 1 of the present invention;
[0060] Figure 5 1 is a structural diagram of a multi-scale pyramid fusion (MSPF) module according to a preferred embodiment 1 of the present invention;
[0061] Figure 6 1 is a confusion matrix experimental result diagram of a preferred embodiment 1 of the present invention;
[0062] Figure 7 4 is a ROC curve result diagram of ASTNet of a preferred embodiment of the present invention;
[0063] Figure 8 This is a PR curve result diagram of ASTNet of a preferred embodiment 4 of the present invention. DETAILED DESCRIPTION
[0064] The following describes several preferred embodiments of the present invention with reference to the accompanying drawings to make its technical content clearer and easier to understand. The present invention can be embodied in many different forms of embodiments, and the scope of protection of the present invention is not limited to the embodiments mentioned herein.
[0065] Example 1: Classification method for rice leaf diseases with multi-scale feature enhancement for complex agricultural scenarios
[0066] To ensure the accuracy and reliability of the experiments and minimize potential interference from experimental equipment and conditions, all experiments in this example were conducted in a consistent environment. In terms of hardware, this example was configured with a local desktop computer; in terms of software, a standardized development environment was used, including necessary installation packages, to ensure consistency across the experiments.
[0067] The specific hardware configuration is shown in Table 1.
[0068] Table 1 Hardware configuration
[0069]
[0070] The specific software environment configuration is shown in Table 2.
[0071] Table 2 Software environment configuration
[0072]
[0073] First, a large-scale field image dataset containing seven rice diseases and healthy leaves was constructed using the Kaggle platform. Data quality was ensured through a three-stage data cleaning process (removing artificial background samples, filtering low-resolution images, and unifying the image size to 1200x1600 pixels). A frequency-space dual-domain collaborative enhancement strategy was then employed to improve model robustness. Specifically, frequency-domain enhancement involved Fourier transform decomposition of the image spectrum, randomly adjusting the amplitude and phase spectra to simulate different lighting conditions and device white balance deviations, generating five frequency-domain perturbation samples. Spatial-domain enhancement involved injecting five-dimensional perturbations: Gaussian noise (standard deviation σ∈[0,51]), Laplace noise (scale parameter b∈[0,51]), Poisson noise (Λ=40), and impulse noise (salt and pepper noise ratio p=10%). These perturbations were combined with rotation (±45°) and scaling (50%-150%) to cover common field equipment defects and environmental disturbances. During the training phase, the Swin Transformer Tiny is used as the core architecture, and the independently designed OSAS module and MSPF module are embedded: the OSAS module dynamically enhances the feature response of the lesion area through parallel spatial attention (based on dual-pooling feature fusion), channel attention (global average pooling + fully connected layer) and multi-scale convolution attention (3×3, 5×5 and void convolution branches); the MSPF module spans different stages of the network, aligns shallow high-resolution features with deep semantic information through bilinear interpolation, and uses spatial pyramid pooling (SPP) to fuse multi-scale context, and finally injects it into the backbone network through residual connection. The experiment was configured using an NVIDIA RTX 4070 GPU and the PyTorch framework. The trained ASTNet achieved a Top-1 accuracy of 81.20% and an average F1 score of 80.34% in an eight-category classification task involving 9,922 images. Its recognition accuracy for healthy leaves and highly pathogenic pests (rice blast and sheath blight) exceeded 98%, significantly improving its performance compared to baseline models such as ResNet and Vision Transformer (see the comparative experiment table for details), validating the effectiveness of the module design and its adaptability to complex scenarios.
[0074] This paper proposes a classification method for rice leaf diseases with multi-scale feature enhancement for complex agricultural scenarios. Through frequency-space dual-domain data enhancement, omnidirectional attention coordination mechanism, and multi-scale pyramid fusion mechanism, the classification accuracy and robustness of the model for seven rice diseases are significantly improved. The method structure diagram is shown in the figure below. Figure 1 As shown, the overall implementation path includes the following steps:
[0075] S1: An initial image set containing seven types of pathological features and healthy leaves was retrieved through the large-scale data platform Kaggle, and a three-level data cleaning process was performed on the collected images to obtain the initial dataset;
[0076] S2: Frequency-space dual-domain collaborative enhancement strategy: The enhanced dataset is generated by injecting Fourier transform, spatial domain noise and spatial domain conventional transform into the dataset to simulate field environmental interference;
[0077] S3: The initial dataset in step S1 and the enhanced dataset in step S2 are combined as the self-made dataset used in the present invention, with a total of 9922 data images;
[0078] S4: The Omnidirectional Attention Collaboration (OSAS) module and the Multiscale Pyramid Fusion (MSPF) module are integrated into a model with the Swin Transformer as its core to form the new deep learning classification model ASTNet used in the present invention (A classification method for rice leaf diseases with multiscale feature enhancement for complex agricultural scenarios);
[0079] S5: Import the self-made dataset in step S3 into the ASTNet model in step S4 and conduct a classification experiment on eight rice leaf feature states. The final result has a Top-1 accuracy of 81.20%.
[0080] S1 contains the following:
[0081] S11: The initial image set containing seven types of pathological features including bacterial leaf blight, brown spot, rice blast, leaf burn, narrow brown leaf spot, rice wilt and sheath blight, as well as healthy leaves, was retrieved through the platform.
[0082] S12: Perform a three-level data cleaning process on the collected images: remove artificial background or segmented leaf samples to retain the true image of the complete plant interacting with the environment; filter low-quality images with a resolution lower than 1200x1600 to ensure that the texture features of the lesions are clearly discernible; standardize the image size to 1200x1600 pixels to eliminate scale variations caused by equipment differences.
[0083] The ASTNet model structure view used in this experiment is as follows Figure 2 As shown, S2 contains the following contents:
[0084] S21: Frequency Domain Enhancement: Apply Fourier transform to decompose the image into amplitude and phase spectra. By randomly adjusting the spectral components, five illumination variation samples are generated to effectively simulate the solar spectrum characteristics and device white balance deviation at different times.
[0085] The formula for generating a plane wave is
[0086]
[0087] Where x, y are the coordinates of the pixels in the image (with the center of the image as the origin); f is the frequency of the plane wave; θ is the direction angle of the plane wave. The random sampling formula for frequency and phase is
[0088]
[0089] Where f is uniformly randomly selected from the predefined frequency list [1, 2, 3] and normalized to the image width dimension; φ is uniformly sampled from the interval [-2π, 0] with a compensation of 64. The amplitude intensity adjustment formula is
[0090] A~Exponential(Λ=mean_str)+min_str
[0091] Where mean_str is the average intensity parameter; min_str is the minimum intensity parameter. The formula for synthesizing enhanced images is:
[0092]
[0093] Among them I orignal is the original image, normalized to [0,1]; N f The number of frequencies sampled for each channel; N p The number of phases sampled for each frequency; ∈ scale is the scaling factor, which is determined by the image width; Clip(·) limits the enhanced pixel value to the range of [0,1].
[0094] S22: Spatial Domain Enhancement: Inject Gaussian noise, Laplace noise, Poisson noise, impulse noise, Gaussian blur, grayscale mask occlusion, horizontal flip, vertical flip, scaling, and rotation to simulate device defects and environmental interference.
[0095] The formula for Gaussian noise is
[0096]
[0097] The mean (μ1) is fixed to 0, and the noise is symmetrically distributed on both sides of 0; the standard deviation (σ1) is defined as σ∈[0,51].
[0098] The formula for Laplace noise is
[0099]
[0100] The mean (μ2) is fixed to 0, and the noise is symmetrically distributed on both sides of 0; the scale parameter (b) determines the degree of noise diffusion (the larger the b, the wider the noise range). The formula for Poisson noise is
[0101]
[0102] The mean value Λ controls the noise intensity; the actual noise value obeys:
[0103] Poisson(Λ)-Λ
[0104] The mean is 0 and the variance is Λ.
[0105] The formula for impulse noise is
[0106] AddNoise(x,y)~Bernoulli(p)
[0107]
[0108] The formula for Gaussian blur is
[0109]
[0110] Where (x, y) is the coordinate of the pixel relative to the center of the Gaussian kernel, and σ2 is the standard deviation, which controls the "diffusion" of the Gaussian kernel (the larger σ2, the wider the kernel and the stronger the blur).
[0111] S4 contains the following:
[0112] S41: OSAS module: Parallel spatial attention, channel attention and multi-scale convolutional attention mechanism to enhance the ability to locate the lesion area; the structure of the Omnidirectional Attention Synergy (OSAS) module is shown in the figure. Figure 4 As shown in the figure, ① is the spatial attention branch, ② is the channel attention branch, ③ is the multi-scale convolution attention branch, ④ is the weighted summation, and ⑤ is the weighted addition of the results.
[0113] S42: MSPF module: Alleviate the problem of deep network feature degradation through cross-stage feature fusion and spatial pyramid pooling; the structure of the multi-scale pyramid fusion (MSPF) module is as follows Figure 5 As shown in the figure, ① is cross-stage feature alignment, ② is feature fusion, ③ is spatial pyramid pooling, ④ is bilinear interpolation, ⑤ is channel alignment, ⑥ is dimension splicing, ⑦ is multi-scale pooling, ⑧ is feature aggregation, and ⑨ is the element-by-element addition process.
[0114] S43: The OSAS module in step S41 and the MSPF module in step S42 are integrated into SwinTransformer to form a new ASTNet model used in the present invention (a classification method for multi-scale feature enhancement of rice leaf diseases in complex agricultural scenarios).
[0115] S41 includes the following:
[0116] (1) Spatial attention: Generate a spatial weight matrix through pooling operation to focus on the lesion area;
[0117] (2) Channel attention: Filter discriminative feature channels through global average pooling;
[0118] (3) Multi-scale convolutional attention: using different convolution kernels to capture multi-granularity lesion details;
[0119] (4) Finally, the fused three-way features are output.
[0120] S41(1) contains the following:
[0121] The spatial attention mechanism dynamically adjusts the weights of different spatial locations in the feature map, allowing the model to focus on key areas and suppress irrelevant background information. Its core idea is to perform global spatial modeling on the input feature map and leverage the spatial correlation of features to generate a two-dimensional attention weight matrix. Each element in this matrix represents the importance score of the corresponding location. Ultimately, these weights are applied to the original features through element-by-element multiplication to enhance the feature response of important areas.
[0122] The formula for the spatial attention branch is
[0123]
[0124] and
[0125] where Φ Avg and Φ Max Represents the average pooling and maximum pooling along the channel dimension, generating spatial statistical features
[0126]
[0127] is the feature concatenation operation, ψ conv is the spatial convolution layer, ζ is the sigmoid function that generates the spatial weight matrix ⊙ represents element-by-element multiplication.
[0128] S41(2) contains the following:
[0129] The channel attention mechanism dynamically learns the importance weights of different channels by modeling the dependencies between channels in the feature map, thereby strengthening the contribution of task-related feature channels and weakening the interference of redundant channels. Its core lies in compressing the feature map along the spatial dimension, generating channel description vectors to capture global channel information, and establishing nonlinear interactions between channels through structures such as fully connected layers. Finally, it outputs a weight vector with the same number of channels to act on the original features. The formula of the channel attention branch is
[0130]
[0131] where Ψ GAP It is global average pooling, compressing the spatial dimension to obtain the channel description vector
[0132]
[0133] is the weight matrix of the fully connected layer for dimensionality reduction and dimensionality increase, is the ReLU activation function, Represents broadcast multiplication along the channel dimension.
[0134] S41(3) contains the following:
[0135] The multi-scale convolutional attention mechanism captures multi-scale contextual information by using convolution operations with different receptive fields in parallel, and adaptively fuses features of each scale to enhance the model's perception of complex patterns. Its core lies in constructing a multi-branch convolution structure (such as dilated convolutions with different expansion rates or convolution layers with different kernel sizes), extracting multi-granularity spatial features, and dynamically aggregating the important components of features at each scale through attention weights. The formula for the multi-scale convolutional attention branch is
[0136]
[0137] where κ i is a multi-scale convolution kernel (such as 3×3, 5×5 and dilated convolution), Λ i is the learnable scale balance coefficient, * represents the convolution operation; ψ 1×1 Generate multi-scale attention weights for channel compression convolution
[0138] S41(4) includes the following: Fusion outputs the final three-way features:
[0139]
[0140] S42 contains the following:
[0141] (1) Cross-stage feature fusion: aligning shallow high-resolution features with deep semantic features;
[0142] (2) Spatial pyramid pooling: integrating multi-scale contextual information to enhance the recognition of small lesions;
[0143] (3) Residual enhancement output.
[0144] S42(1) contains the following:
[0145] Cross-stage feature fusion is a technology that enhances the representation ability of the model by integrating feature maps at different levels of the neural network. Its core lies in the synergistic use of shallow high-resolution detail information and deep low-resolution semantic information. In deep convolutional networks, shallow features (such as edges and textures) have fine spatial details but lack high-level semantic understanding; while deep features (such as object contours and category distributions) are semantically rich, but they lose local details due to layer-by-layer downsampling. Cross-stage feature fusion aligns the spatial resolution of shallow features with deep features through dynamic upsampling (such as bilinear interpolation or transposed convolution), and uses channel adjustment to unify the channel dimensions of the two, and then realizes feature interaction through splicing or element-by-element addition. Finally, the fusion result is added to the original deep feature through residual connection, which not only retains the semantic integrity of the backbone network, but also injects cross-stage detail enhancement gradients, thereby significantly improving the detection accuracy and robustness of the model for multi-scale targets in complex scenarios such as agricultural disease classification. The formula for cross-feature fusion is
[0146]
[0147] Among them (1) ,Υ (2) is the input feature map of the two adjacent stages, with resolutions of
[0148] (H1,W1),(H2,W2)
[0149] Γ 1×1 is a 1×1 convolution, with the number of unified channels being the target dimension; ∪ is the concatenation operation along the channel dimension; Γ 3×3 Implement cross-stage feature interaction for 3×3 convolution.
[0150] S42(2) contains the following:
[0151] Spatial pyramid pooling is a technique used in deep learning to enhance the multi-scale feature extraction capability of the model. Its core idea is to fuse local details with global contextual information by pooling feature maps at different spatial scales. The method first divides the input feature map into multiple grid regions of different sizes, and then performs a pooling operation within each grid to extract representative features of the region. By sequentially splicing the features obtained by pooling at different scales, the model can simultaneously capture the subtle structure of the target object and its spatial distribution pattern in the overall scene. This multi-level pooling strategy not only breaks through the limitations of traditional networks on fixed input size, enabling the model to flexibly process images of arbitrary resolution, but also significantly improves the adaptability of feature expression to targets of different scales. In particular, in complex scenes such as agricultural disease identification, it can effectively identify regions of interest of different sizes and shapes.
[0152] The formula for spatial pyramid pooling is
[0153]
[0154] where Λ s is S×S adaptive average pooling; || is channel splicing after bilinear interpolation to restore the original size; Aggregation of multi-scale pooling results.
[0155] S42(3) contains the following: The formula for the residual enhancement output is in It is element-wise addition, preserving the original feature distribution.
[0156] S43 contains the following:
[0157] In each basic block (Swin Block) of the Swin Transformer, the OSAS module is connected in parallel to the multi-head self-attention layer, and then dynamically focuses on the lesion area through spatial attention, filters highly discriminative features through channel attention, and captures pathological details of different granularities through multi-scale convolution branches. After weighted fusion of the three, the output is enhanced features to strengthen the interaction between local and global semantics. The MSPF module spans between adjacent network stages, performs bilinear interpolation and channel alignment on the shallow high-resolution feature map, splices it with the deep low-resolution features, and fuses the multi-receptive field context information through spatial pyramid pooling (SPP), and finally injects it into the main network through residual connection. This design achieves refined modeling of multi-scale lesion features without significantly increasing the amount of computation, effectively alleviates the problem of feature degradation in deep networks, and improves the model's adaptability to complex field scenarios.
[0158] The collection, preprocessing and enhancement diagram of the self-made dataset is as follows Figure 3As shown in the figure, ① is spatial domain enhancement, ② is frequency domain enhancement, ③ is Gaussian noise superimposed on a random grayscale mask, ④ is Laplace noise combined with image horizontal flipping, ⑤ is Poisson noise coupled with image vertical flipping, ⑥ is impulse noise combined with image scale scaling, and ⑦ is Gaussian blur combined with image rotation perturbation process.
[0159] S5 includes the following:
[0160] Import the self-made dataset in step S3 into the ASTNet model in step S4, conduct a classification experiment on eight rice leaf characteristic states, generate corresponding experimental results, and analyze and explain them.
[0161] S51: Experimental results analysis: This method showed high classification ability in most disease categories, but there were still recognition differences between some categories;
[0162] S52: Confusion Matrix Analysis: The performance of the rice leaf disease classification method was analyzed based on the confusion matrix. The detailed confusion matrix data is as follows: Figure 6 As shown;
[0163] S53: Method evaluation: ROC curve and PR curve are used to evaluate the performance of the ASTNet architecture used in the present invention.
[0164] S54: Comparative experiment: The superior performance of the present invention in the rice leaf disease classification task in complex agricultural scenarios is verified through comparative experiments.
[0165] S55: Ablation experiment: The effectiveness of the OSAS module and MSPF module in the ASTNet architecture of the present invention and their combined advantages are verified through systematic ablation experiments.
[0166] Example 2 Class-specific analysis
[0167] The present invention proposes a classification method for rice leaf diseases with multi-scale feature enhancement for complex agricultural scenarios, and its classification performance shows significant advantages and practical value in multi-category scenarios.
[0168] S51 includes the following content: In the category-specific analysis, the method's ability to detect healthy rice leaves is particularly outstanding, achieving near-perfect classification results with 100% precision and average precision (AP). At the same time, the recall rate (Recall) reached 98.64% and the F1 score (F1 Score) reached 99.31%, fully verifying its ability to accurately distinguish healthy features with almost no false positive or false negative misjudgments. The recognition performance for diseases with high incidence is also excellent. The recall rates for Rice Blast and Sheath Blight reached 89.09% and 93.56%, respectively, and the F1 scores exceeded 82%, showing high sensitivity to early diseases and low risk of missed detection. The rice wilt (Rice Hispa) disease achieved an F1 score of 94.66% (precision of 91.89% and recall of 97.61%) and an AP value of 99.49%, demonstrating the excellent performance of the present invention in complex lesion location and classification tasks.
[0169] In terms of overall performance evaluation, ASTNet's Top-1 accuracy reached 81.20%, and the average precision (81.03%), recall (80.28%) and F1 score (80.34%) were highly consistent, proving its classification stability and reliability. Especially in the real-time field diagnosis scenario, ASTNet's strong recognition ability for healthy leaves and highly diseased diseases has significant application value. For medium-performance categories (such as brown spot disease and bacterial leaf blight), it effectively addresses the inter-class similarity challenge through balanced precision and recall (F1 scores of 77.41% and 73.52%); for low-performance categories such as Narrow Brown Leaf Spot and Leaf Scald, the present invention has clarified optimization paths, including improving sample diversity through data enhancement, using synthetic lesion images to enhance feature learning, or improving local texture feature extraction strategies to distinguish background noise. These targeted improvement schemes will further enhance the generalization ability of the model and provide more comprehensive technical support for the precise prevention and control of rice diseases.
[0170] Example 3 Confusion Matrix Verification of Classification Performance
[0171] The present invention discloses a classification method for rice leaf diseases with multi-scale feature enhancement for complex agricultural scenarios, and its classification performance is verified by confusion matrix. S52 includes the following contents: Figure 6As shown, this method demonstrates significant technical advantages and practical value. The method achieved overall high-precision classification in eight categories of rice leaf conditions (including healthy leaves and seven diseases). The recognition accuracy of healthy leaves (Healthy Rice Leaf) was as high as 98.6% (217 / 220), and only 3 cases were misclassified as diseased. This fully verified the method's ability to efficiently distinguish between healthy and pathological characteristics, providing a reliable guarantee for field health monitoring. The identification of highly prevalent diseases was also excellent: Rice blast (Leaf Blast) was accurately located with an accuracy rate of 89.1% (294 / 330), and Sheath Blight (Sheath Blight) showed excellent performance of 93.6% (247 / 264), highlighting its classification robustness. Only a small number of misjudgments occurred in Bacterial Leaf Blight, where features were highly overlapping, confirming the method's strong ability to capture complex lesion features.
[0172] For disease categories with strong cross-interference, ASTNet has achieved breakthrough progress through innovative feature extraction strategies. For example, Bacterial Leaf Blight achieved an accuracy rate of 76.3% (193 / 253) in 253 tests, and Brown Spot achieved an accuracy rate of 78.8% (197 / 250) in 250 tests, significantly outperforming traditional image processing methods. Even between morphologically highly similar categories such as Leaf Scald and Leaf Blast, ASTNet effectively reduced the misclassification rate through deep feature decoupling, resulting in limited errors due only to the similarity of local lesions, indicating a technical path for subsequent targeted optimization. Of particular note is that the rice wilt (Rice Hispa) achieved an extremely high accuracy rate of 97.6% in 209 tests, and the narrow brown leaf spot (Narrow Brown Leaf Spot) also achieved 64.3% effective recognition in 107 samples, verifying the generalization potential of the method of the present invention in small sample scenarios.
[0173] To further improve the performance of the classification system, the present invention proposes a systematic optimization scheme: for easily confused categories (such as bacterial leaf blight and leaf burn, rice blast and sheath blight), the detail distinction can be enhanced by fusion of multi-scale morphological features; combined with synthetic data augmentation technology, the feature coverage of low-sample-size categories such as narrow brown leaf spot can be expanded.
[0174] Example 4: Building a closed-loop optimization framework
[0175] This invention not only provides a high-precision solution for early diagnosis of rice diseases, but also constructs a closed-loop optimization framework through interpretable analysis, which has important practical significance for promoting the development of smart agricultural technology.
[0176] S53 includes the following:
[0177] (1) ROC curve: The ROC curve is a visualization tool used to evaluate the performance of a binary classification model. It presents the model performance by plotting the relationship between the true positive rate (TPR, i.e., the proportion of actual positive examples that are correctly identified) and the false positive rate (FPR, i.e., the proportion of actual negative examples that are mistakenly classified as positive) at different classification thresholds. The horizontal axis is FPR and the vertical axis is TPR. Each point on the curve corresponds to the classification result under a threshold. Ideally, the curve will be close to the upper left corner, indicating a high TPR and a low FPR; the diagonal line indicates that the model is no different from random guessing. The area under the curve (AUC) quantifies the overall discrimination ability of the model. The closer the AUC is to 1, the stronger the model's ability to distinguish between positive and negative categories, and 0.5 means no discrimination. The ROC curve is not affected by the distribution of categories and can fully reflect the trade-off characteristics of the model at different thresholds.
[0178] (2) PR curve: The PR curve (Precision-Recall curve) is a visualization tool for evaluating the performance of a binary classification model, especially suitable for scenarios with unbalanced class distribution. Its horizontal axis is the recall rate (Recall, i.e., the proportion of actual positive examples that are correctly identified), and the vertical axis is the precision rate (Precision, i.e., the proportion of true positive examples in samples predicted to be positive). The model performance is reflected by plotting the corresponding relationship between the two under different classification thresholds. The closer the curve is to the upper right, the higher the recall rate and the higher the precision rate in positive class recognition. If the curve is close to the baseline (horizontal axis), the model performance is poor. The area under the curve (AUC-PR) or average precision (AP) is often used to quantify the overall performance of the model. The closer the value is to 1, the stronger the model's ability to distinguish the positive class. Compared with the ROC curve, the PR curve focuses more on the recognition quality of positive samples, is more sensitive to the evaluation of class imbalance data (such as when there are very few positive samples), and can intuitively reveal the trade-off characteristics of the model between precision and recall.
[0179] S53(1) contains the following:
[0180] The patent disclosed in this invention is a classification method for rice leaf diseases with multi-scale feature enhancement for complex agricultural scenarios. Through multimodal feature fusion and optimization strategies, it shows breakthrough classification performance in seven classification tasks. Figure 7As shown in the figure, the ROC curve analysis of the model shows that both healthy rice leaves and rice wilt (Rice Hispa) achieved perfect classification with an area under the curve (AUC) of 1.00, achieving a detection accuracy of zero false positives, verifying the absolute advantage of the model in extracting key category features; Rice blast (Leaf Blast) (AUC = 0.96) and sheath blight (Sheath Blight) (AUC = 0.98) were close to the theoretical optimal values, highlighting its excellent performance in complex lesion identification, providing a reliable technical guarantee for early warning of high-incidence and severe diseases.
[0181] In scenarios involving feature cross-interference, this invention significantly improves discrimination capabilities through an innovative spatial attention mechanism: Bacterial Leaf Blight achieves strong detection performance with an AUC of 0.90, while Leaf Scald and Narrow Brown Leaf Spot achieve robust performance with AUCs of 0.89 and 0.84, respectively, representing significant improvements over traditional methods. Of particular note, the model achieves AUCs ≥ 0.89 in most tasks, achieving industry-leading overall classification robustness.
[0182] This invention not only overcomes the technical challenge of decoupling the mixed characteristics of rice leaf diseases but also establishes a closed-loop performance optimization system through a quantifiable AUC indicator system. Its core value lies in: accurate discrimination of health status and core diseases (such as rice blast and sheath blight) provides a decision-making basis for real-time field diagnosis, while efficient identification of complex cases (such as bacterial leaf blight) lays the algorithmic foundation for precise pesticide application, marking a new stage in intelligent agricultural disease detection technology.
[0183] S53(2) contains the following:
[0184] The invention discloses a classification method for rice leaf diseases with multi-scale feature enhancement for complex agricultural scenarios, which is fully verified by the PR curve evaluation system. Figure 8 As shown in the figure, it has demonstrated industry-leading technical advantages in eight classification tasks. Figure 7As shown, the model achieved an average precision (AP) of 1.00 in the classification of healthy rice leaves, achieving a zero-error balance between precision and recall, providing a gold standard for field health monitoring. For high-value diseases, the model approached the theoretical limit with an AP of 0.99 for Rice Hispa, and achieved an exceptional AP of 0.96 for Sheath Blight, demonstrating its ability to accurately identify complex lesion features, significantly outperforming traditional detection methods. The above-average performance for Leaf Blast (AP = 0.82) and Brown Spot (AP = 0.71) further validated the stability and generalization capabilities of this method in identifying common diseases.
[0185] Facing the challenges of class imbalance and feature overlap, the present invention achieves a technological breakthrough through a dynamic weight optimization mechanism: Bacterial Leaf Blight demonstrates reliable comprehensive performance on an AP 0.68 benchmark, Narrow Brown Leaf Spot achieves effective discrimination in small sample scenarios with an AP 0.68, and a technical optimization path has been identified for the identification bottleneck of Leaf Scald (AP = 0.58). The patent specifically proposes innovative solutions, including the introduction of a lesion area enhancement algorithm to strengthen the local feature expression of low-AP categories, the construction of a multi-source data fusion framework to alleviate sample distribution bias, and the reduction of inter-class interference through attention-guided feature decoupling technology.
[0186] The core value of this invention lies in its closed-loop optimization system, based on PR curves and AP quantitative indicators, which not only achieves ultra-precise identification of healthy leaves and core diseases (such as sheath blight and rice blast), but also provides interpretable guidance for model iteration in complex scenarios. This technological achievement can be widely applied to intelligent plant protection equipment, improving the efficiency of early disease screening and promoting the rice industry's transition to a data-driven, precision prevention and control model. It has significant socioeconomic benefits and industrial application prospects.
[0187] S54 includes the following:
[0188] The present invention verifies the superior performance of ASTNet in the task of rice leaf disease classification in complex agricultural scenarios through comparative experiments. As shown in Table 3, ASTNet significantly surpasses mainstream methods in four core indicators: Top-1 accuracy, average precision (MP), average recall (MR) and average F1 score, reaching 81.20%, 81.03%, 80.28% and 80.34% respectively. The Top-1 accuracy of the suboptimal methods Swin-Transformer and ResNet-50 is improved by 2.87 percentage points, and the F1 score is improved by 2.63 percentage points, showing the effectiveness of the multi-scale feature enhancement strategy. Among traditional convolutional neural networks, ResNet-50 performs best with a Top-1 accuracy of 78.33%, but its MR (77.45%) and F1 (77.71%) are still significantly lower than ASTNet, indicating that existing methods have limitations in modeling the global association of disease features in complex backgrounds. Lightweight models such as MobileNetV3 and EfficientNet are limited by network capacity and have relatively weak classification performance. Although the visual Transformer series models (ViT, Swin-T) have advantages in attention mechanism, their ability to capture multi-scale local features is still insufficient.
[0189] The comparative experimental results are shown in Table 3:
[0190] Table 3 Comparative experimental results
[0191]
[0192] In Table 3, Top-1 is the Top-1 accuracy, MP is the mean precision, MR is the mean recall, and F1 is the mean F1 score; ViT is the Vision Transformer, and Swin-T is the Swin Transformer.
[0193] Experimental results further reveal that ASTNet, by integrating a multi-scale feature enhancement module, significantly improves recall to 80.28% while maintaining a high precision of 81.03%, an average improvement of 3-4 percentage points over the baseline model. This demonstrates that this method can more effectively balance false positives and false negatives, which is particularly important for disease detection in actual agricultural scenarios, which are susceptible to illumination changes and leaf occlusion. Compared to the accuracy bottleneck of around 77% for traditional architectures such as VGG and DenseNet, and the performance saturation phenomenon of deep networks such as ResNet-101, the feature enhancement mechanism proposed by ASTNet breaks through the boundaries of existing models' ability to represent complex agricultural images, validating the key role of multi-scale feature fusion in fine-grained agricultural disease recognition.
[0194] S55 includes the following:
[0195] Finally, the present invention verifies the effectiveness of the OSAS module and MSPF module in ASTNet and their combined advantages through systematic ablation experiments. The ablation results are shown in Table 4.
[0196] Table 4 Ablation results
[0197]
[0198] In Table 4, Top-1 is the Top-1 accuracy, MP is the mean precision, MR is the mean recall, and F1 is the mean F1 score; SA is spatial attention, CA is channel attention, MSCA is multi-scale convolution of attention, CSFF is cross-stage feature fusion, and SPP is spatial pyramid pooling.
[0199] Experimental results demonstrate that the spatial attention (SA), channel attention (CA), and multi-scale convolutional attention (MSCA) in the OSAS module significantly improve model performance through complementary synergy. When SA, CA, or MSCA are used alone, the Top-1 accuracy increases to 78.94%, 78.89%, and 78.89%, respectively. When all three are used together, the Top-1 accuracy jumps to 80.79%, and the F1 score reaches 79.96%. This demonstrates that the multi-scale feature enhancement mechanism can effectively capture the fine-grained characteristics of rice diseases in complex agricultural scenarios. The combination of cross-stage feature fusion (CSFF) and spatial pyramid pooling (SPP) in the MSPF module also exhibits a synergistic effect. When SPP is used alone, the Top-1 accuracy reaches 79.20%, while when combined with CSFF, it increases to 80.33%. This demonstrates that the multi-scale feature fusion strategy enhances the model's adaptability to the spatial distribution and scale variations of diseases.
[0200] It is worth noting that when the OSAS and MSPF modules are fully integrated, the various indicators of the network architecture reach the optimal level: the Top-1 accuracy rate is improved to 81.20%, and the F1 value exceeds 80.34%, which are 2.87% and 2.99% higher than the baseline method respectively. This result verifies the effectiveness of the dual-module design - OSAS strengthens the extraction ability of key features through multi-scale enhancement of the attention mechanism, while MSPF optimizes the integration and expression of multi-level features through a combination of cross-stage feature fusion and spatial pyramid pooling. In particular, cross-stage feature fusion (CSFF) performs poorly when used alone (Top-1 78.12%), but plays an important role in collaboration with other modules, revealing the deep coupling characteristics between model components. Comprehensive experimental data shows that the present invention effectively solves the challenge of rice leaf disease classification in complex agricultural scenarios through a hierarchical feature enhancement mechanism.
[0201] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and are not limiting. Although the present invention has been described in detail with reference to the best embodiments, researchers in this field should understand that the technical solutions of the present invention can be modified or replaced by equivalents without departing from the purpose and scope of the technical solutions, which should all be covered by the scope of the claims of the present invention.
[0202] The preferred embodiments of the present invention have been described in detail above. It should be understood that numerous modifications and variations based on the concepts of the present invention are possible without inventive effort by those skilled in the art. Therefore, any technical solution that can be derived by one skilled in the art through logical analysis, reasoning, or limited experimentation based on the concepts of the present invention and the prior art should be within the scope of protection defined by the claims.
Claims
1. A classification method for rice leaf diseases with multi-scale feature enhancement, characterized in that: The method comprises the following steps: Step 1: Collect initial data of rice leaves to obtain an initial dataset of large-scale field images; Step 2: The initial data set obtained in step 1 is enhanced by using the frequency-space dual-domain collaborative enhancement strategy; Step 3: Merge the initial dataset obtained in step 1 with the enhanced dataset obtained in step 2 to obtain a self-made dataset; and integrate the omnidirectional attention collaboration module and the multi-scale pyramid fusion module into a model with Swin Transformer as the core to form a deep learning classification model ASTNet; Step 4: Import the self-made dataset obtained in step 3 into the ASTNet model, conduct a classification experiment on eight rice leaf characteristic states, and obtain eight characteristic classification results.
2. The method according to claim 1, wherein The step 1 also includes: retrieving an initial image set containing seven types of pathological features and healthy leaves through the large-scale data platform Kaggle, and performing a three-level data cleaning process on the collected images to obtain the initial data set.
3. The method according to claim 2, wherein The seven types of pathological characteristics are bacterial leaf blight, brown spot, rice blast, leaf burn, narrow brown leaf spot, rice wilt and sheath blight; the three-level data cleaning process is as follows: remove artificial background or segmented leaf samples to retain the real image of the interaction between the complete plant and the environment; filter low-quality images with a resolution lower than 1200x1600 to ensure that the texture characteristics of the lesions are clearly discernible; standardize the image size to 1200x1600 pixels to eliminate scale variations caused by equipment differences.
4. The method according to claim 1, wherein The frequency-space dual-domain collaborative enhancement strategy in step 2 is: injecting simulated field environment interference into the initial data set through Fourier transform, spatial domain noise and spatial domain conventional transform, including frequency domain enhancement and spatial domain enhancement steps.
5. The method according to claim 4, wherein The frequency domain enhancement step is to apply Fourier transform to decompose the image into amplitude spectrum and phase spectrum, and generate five illumination variation samples by randomly adjusting the spectral components to effectively simulate the solar spectrum characteristics and device white balance deviation at different time periods; the plane wave formula is shown in Formula 1: Where x and y are the coordinates of the pixels in the image, with the center of the image as the origin; f is the frequency of the plane wave; θ is the direction angle of the plane wave; the random sampling formula for frequency and phase is shown in Formula 2: Where f is uniformly randomly selected from the predefined frequency list [1, 2, 3] and normalized to the image width dimension; φ is uniformly sampled from the interval [-2π, 0] with a compensation of 64; The amplitude intensity adjustment formula is shown in Formula 3: A~Exponential(Λ=mean_str)+min_str Formula 3, Where mean_str is the average intensity parameter; min_str is the minimum intensity parameter; the formula for synthesizing the enhanced image is shown in Formula 4: Among them I original is the original image, normalized to [0,1]; N f The number of frequencies sampled for each channel; N p The number of phases sampled for each frequency; ∈ scale is the scaling factor, which is determined by the image width; Clip(·) limits the enhanced pixel value to the range of [0,1].
6. The method according to claim 4, wherein The spatial domain enhancement step includes injecting Gaussian noise, Laplace noise, Poisson noise, impulse noise, Gaussian blur, grayscale mask occlusion, horizontal flipping, vertical flipping, scaling and rotation to simulate device defects and environmental interference. The formula of the Gaussian noise is shown in Formula 5: The mean μ1 is fixed to 0, and the noise is symmetrically distributed on both sides of 0; the standard deviation σ1 is defined as σ1∈[0,51]; the formula for Laplace noise is shown in Formula 6: The mean μ2 is fixed to 0, and the noise is symmetrically distributed on both sides of 0. The scale parameter b determines the diffusion degree of the noise. The larger the b value, the wider the noise range. The formula of Poisson noise is shown in Formula 7: The mean Λ controls the noise intensity; Actual noise value: obeys Poisson (Λ)-Λ, with a mean of 0 and a variance of Λ; the formulas for impulse noise are Equation 8 and Equation 9: AddNoise(x,y)~Bernoulli(p) formula 8, The formula for Gaussian blur is shown in Formula 10: Where (x, y) is the coordinate of the pixel relative to the center of the Gaussian kernel, and σ2 is the standard deviation, which controls the "diffusion degree" of the Gaussian kernel. The larger the value of σ2, the wider the Gaussian kernel and the stronger the blur.
7. The method according to claim 1, wherein The omnidirectional attention collaborative module in step 3: parallel spatial attention, channel attention and multi-scale convolutional attention mechanisms to enhance the ability to locate the lesion area and ultimately output a fused three-way feature; The multi-scale pyramid fusion module alleviates the problem of deep network feature degradation through cross-stage feature fusion and spatial pyramid pooling.
8. The method according to claim 1, wherein The spatial attention is specifically: generating a spatial weight matrix through pooling operation to focus on the lesion area; the channel attention is specifically: screening discriminative feature channels through global average pooling; the multi-scale convolution attention is specifically: using different convolution kernels to capture multi-granularity lesion details.
9. The method according to claim 7, wherein: The multi-scale pyramid fusion module further comprises the following steps: (1) Cross-stage feature fusion: aligning shallow high-resolution features with deep semantic features; (2) Spatial pyramid pooling: integrating multi-scale contextual information to enhance the recognition of small lesions; (3) Residual enhancement output.
10. The method according to claim 1, wherein The step 4 also includes: experimental result analysis, confusion matrix analysis, method evaluation, comparative experiment and ablation experiment; the method evaluation is to use ROC curve and PR curve to evaluate the performance of the ASTNet architecture respectively; the ablation experiment is to verify the effectiveness and combined advantages of the omnidirectional attention collaboration module and multi-scale pyramid fusion module in the ASTNet architecture through systematic ablation experiments.
Citation Information
Cited By
Industrial part image data enhancement and noise reduction method based on deep learning
CN120655528A
Multi-dimensional photovoltaic defect quantitative evaluation auxiliary decision-making method and system
CN121147933A
Improved network model crack identification and segmentation method for complex texture background
CN122156601A