A coastal wetland classification method based on lightweight multi-directional compression attention network

By using a lightweight, multi-directional compressed attention network, the problem of inaccurate wetland classification across climate zones was solved, achieving lightweight and efficient coastal wetland classification and improving classification accuracy and adaptability.

CN119992214BActive Publication Date: 2025-12-05SUN YAT SEN UNIV
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510158143.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-02-13
Publication Date
2025-12-05
Estimated Expiration
2045-02-13

AI Technical Summary

Technical Problem

Traditional wetland classification models struggle to effectively handle differences in wetland types across climate zones, leading to inaccurate classifications and making it difficult to scale up the models.

Method used

A lightweight multi-directional compressed attention network is adopted to achieve accurate classification of coastal wetlands through preprocessing, wetland screening, and a combination of lightweight attention-enhanced convolutional units, multi-directional axial compressed attention units, and cross-attention units.

Benefits of technology

The model improved accuracy and adaptability in wetland classification across climate zones, reduced model complexity, enhanced the ability to mine information from remote sensing data, and achieved efficient coastal wetland classification.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119992214B_ABST
    Figure CN119992214B_ABST
Patent Text Reader

Abstract

The application discloses a coastal wetland classification method based on a lightweight multi-direction compression attention network. The method comprises the following steps: acquiring a remote sensing image and performing preprocessing to obtain a preprocessed remote sensing image; performing wetland screening on the preprocessed remote sensing image to obtain a wetland image; and inputting the wetland image into a lightweight multi-direction compression attention network to obtain a final classification result map. The method balances complexity and classification accuracy, and realizes coastal wetland classification and extraction across climate zones.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the field of deep learning, more particularly, to a coastal wetland classification method based on a lightweight multi-directional compressed attention network. BACKGROUND

[0002] With the vigorous development of artificial intelligence, deep learning technology is widely used to solve the problem of wetland classification.

[0003] Traditional wetland classification models are difficult to effectively process the same wetland type due to differences in latitude and terrain in cross-climate zone tasks, resulting in inaccurate cross-climate zone wetland classification. Meanwhile, general models rely on multi-head attention mechanism for axial attention implementation, making the structure complex and the model difficult to be lightweight.

[0004] The prior art discloses a coastal wetland remote sensing classification method based on a hierarchical strategy, comprising the following steps: step 1, preprocessing remote sensing data; step 2, sampling based on vegetation index, water index obtained by remote sensing index, and brightness auxiliary data obtained by the Canny transform; step 3, coarse classification of multi-spectral images and auxiliary data; step 4, masking of cultivated land, forest land, and urban areas; step 5, describing the local texture features of the image using the LBP local binary pattern operator; step 6, combining spectral information and spatial texture information to perform image segmentation on water bodies and wetland areas; step 7, obtaining coastal wetland vector data; and step 8, producing a coastal wetland thematic map. This method classifies wetlands based on traditional machine learning methods, and the remote sensing data information is not completely mined. SUMMARY

[0005] The present application provides a coastal wetland classification method based on a lightweight multi-directional compressed attention network to solve the problems of inaccurate cross-climate zone wetland classification and difficult model lightweight in the prior art. This method has the characteristics of accurate cross-climate zone wetland classification and lightweight model.

[0006] The primary object of the present application is to solve the above technical problems, and the technical solution of the present application is as follows:

[0007] A coastal wetland classification method based on a lightweight multi-directional compressed attention network, comprising:

[0008] S1: obtaining a remote sensing image and preprocessing it to obtain a preprocessed remote sensing image;

[0009] S2: wetland screening of the preprocessed remote sensing image to obtain a wetland image;

[0010] S3: inputting the wetland image into a lightweight multi-directional compressed attention network to obtain a final classification result map.

[0011] Further, in step S1, the preprocessing includes cloud removal and median filtering.

[0012] Further, the wetland screening includes:

[0013] S201: calculating a normalized difference built-up index NDBI, a normalized difference vegetation index NDVI, and a modified normalized difference water index MNDWI from the preprocessed remote sensing image;

[0014] S202: using Otsu algorithm to analyze the normalized difference built-up index NDBI, the normalized difference vegetation index NDVI, and the modified normalized difference water index MNDWI to obtain a decision tree threshold;

[0015] S203: using the decision tree threshold to determine whether each pixel in the preprocessed remote sensing image is a wetland using a decision tree algorithm, and collecting the determination results to obtain a wetland image.

[0016] Further, the normalized difference built-up index NDBI, the normalized difference vegetation index NDVI, and the modified normalized difference water index MNDWI are calculated according to the following formulas:

[0017]

[0018] NIR represents a near-infrared band in the remote sensing image, RED represents a red band in the remote sensing image, MIR represents a mid-infrared band in the remote sensing image, and GREEN represents a green band in the remote sensing image.

[0019] Further, the lightweight multi-direction compression attention network includes a lightweight attention enhanced convolution unit, a multi-direction axis compression attention unit, a cross attention unit, and a classification result generation unit.

[0020] The wetland image is input into the input end of the lightweight attention enhanced convolution unit, the output end of the lightweight attention enhanced convolution unit is connected to the input end of the multi-direction axis compression attention unit, the output end of the multi-direction axis compression attention unit is connected to the input end of the cross attention unit, the output end of the cross attention unit is connected to the input end of the classification result generation unit, and the output end of the classification result generation unit outputs a final classification result map.

[0021] Further, the lightweight attention enhanced convolution unit includes a first lightweight attention enhanced convolution module, a second lightweight attention enhanced convolution module, and a third lightweight attention enhanced convolution module.

[0022] The first lightweight attention enhanced convolution module, the second lightweight attention enhanced convolution module and the third lightweight attention enhanced convolution module are identical in structure and each include a first convolution layer, a second convolution layer, a third convolution layer, a first batch normalization layer, a second batch normalization layer, a third batch normalization layer, a first multiplication point, a second multiplication point, a fourth convolution layer, a fifth convolution layer, a sixth convolution layer, a fourth batch normalization layer, a fifth batch normalization layer, a sixth batch normalization layer, a first addition point, a second addition point, a seventh convolution layer, a seventh batch normalization layer and a first activation layer.

[0023] The output end of the first convolution layer is connected with the input end of the first batch normalization layer, the output end of the second convolution layer is connected with the input end of the second batch normalization layer, the output end of the third convolution layer is connected with the input end of the third batch normalization layer, the output end of the first batch normalization layer and the output end of the second batch normalization layer are connected with the input end of the first multiplication point, the output end of the first multiplication point and the output end of the third batch normalization layer are connected with the input end of the second multiplication point, the output end of the second multiplication point is connected with the input end of the fourth convolution layer, the input end of the fifth convolution layer and the input end of the sixth convolution layer, the output end of the fourth convolution layer is connected with the input end of the fourth batch normalization layer, the output end of the fifth convolution layer is connected with the input end of the fifth batch normalization layer, the output end of the sixth convolution layer is connected with the input end of the sixth batch normalization layer, the output end of the fourth batch normalization layer and the output end of the fifth batch normalization layer are connected with the input end of the first addition point, the output end of the first addition point and the output end of the sixth batch normalization layer are connected with the input end of the second addition point, the output end of the second addition point is connected with the input end of the seventh convolution layer, the output end of the seventh convolution layer is connected with the input end of the seventh batch normalization layer, and the output end of the seventh batch normalization layer is connected with the input end of the first activation layer.

[0024] Further, the multi-direction axial compression attention unit includes a first multi-direction axial compression attention module, a second multi-direction axial compression attention module and a third multi-direction axial compression attention module.

[0025] The first multi-direction axial compression attention module, the second multi-direction axial compression attention module and the third multi-direction axial compression attention module are identical in structure and each include an average pooling layer, a skewness calculation layer, a kurtosis calculation layer, a variance calculation layer, a third addition point and a fourth addition point.

[0026] The output end of the average pooling layer is connected with the input end of the skewness calculation layer, the input end of the kurtosis calculation layer and the input end of the variance calculation layer, the output end of the skewness calculation layer, the output end of the kurtosis calculation layer, the output end of the variance calculation layer and the input end of the average pooling layer are connected with the input end of the third addition point, and the output end of the third addition point is connected with the input end of the fourth addition point.

[0027] Further, the calculation formula of the skewness calculation layer is as follows:

[0028]

[0029] E represents expectation, i represents serial number, x i represents the i-th value of random variable X, mu represents the mean value of random variable value, and sigma represents the standard deviation of random variable value;

[0030] The calculation formula of the kurtosis calculation layer is as follows:

[0031]

[0032] X represents a random variable, n represents the total number of random variable values, i represents a serial number, and x i represents the i-th value of random variable X, represents the mean value of random variable X;

[0033] The calculation formula of the variance calculation layer is as follows:

[0034]

[0035] p i represents the probability that the random variable X takes x i , n represents the total number of random variable values, and x i represents the i-th value of random variable X, i represents a serial number, and X represents a random variable.

[0036] Further, the cross attention unit comprises: a first cross attention module, a second cross attention module, and a third cross attention module.

[0037] The first cross attention module, the second cross attention module, and the third cross attention module have the same structure and comprise: an eighth batch normalization layer, a ninth batch normalization layer, a first linear layer, a second linear layer, a third linear layer, a fourth linear layer, an attention score layer, and a result summary layer.

[0038] The output end of the eighth batch normalization layer is connected with the input end of the first linear layer, the output end of the first linear layer is connected with the input end of the second linear layer, the output end of the ninth batch normalization layer is connected with the input end of the third linear layer, the output end of the third linear layer is connected with the input end of the fourth linear layer, the output end of the second linear layer and the output end of the fourth linear layer are connected with the input end of the attention score layer, and the output end of the attention score layer and the output end of the second linear layer are connected with the input end of the result summary layer.

[0039] A coastal wetland classification system based on a light multi-directional compressed attention network comprises:

[0040] A preprocessing module: obtaining a remote sensing image and preprocessing the remote sensing image to obtain a preprocessed remote sensing image;

[0041] wetland screening module: wetland screening is performed on the pretreated remote sensing image to obtain a wetland image;

[0042] network inference module: the wetland image is input into a lightweight multi-directional compressed attention network to obtain a final classification result map.

[0043] Compared with the prior art, the present application has the following beneficial effects:

[0044] The present application uses a lightweight multi-directional compressed attention network, which has low model structure complexity, and the axial attention can play a greater role, can effectively capture the detailed information, direction dependence and mutual coordination between features in the image, has stronger adaptability and performance, and improves the performance in complex tasks. At the same time, the remote sensing image is obtained and pretreated; the pretreated remote sensing image is screened to obtain a wetland image; the remote sensing data information mining capability is expanded. In summary, the present application balances the complexity and classification accuracy, realizes the classification and extraction of coastal wetlands across climate zones. BRIEF DESCRIPTION OF DRAWINGS

[0045] Figure 1 A flowchart of a coastal wetland classification method based on a lightweight multi-directional compressed attention network provided for embodiment 1.

[0046] Figure 2 A flowchart of wetland screening provided for embodiment 1.

[0047] Figure 3 A structure diagram of a lightweight multi-directional compressed attention network provided for embodiment 1.

[0048] Figure 4 A principle diagram of a lightweight multi-directional compressed attention network provided for embodiment 1.

[0049] Figure 5 A structure diagram of a lightweight attention enhanced convolution module provided for embodiment 1.

[0050] Figure 6 A principle diagram of a lightweight attention enhanced convolution module provided for embodiment 1.

[0051] Figure 7 A structure diagram of a multi-directional axial compression attention module provided for embodiment 1.

[0052] Figure 8 A principle diagram of a multi-directional axial compression attention unit provided for embodiment 1.

[0053] Figure 9 A structure diagram of a cross-attention module provided for embodiment 1.

[0054] Figure 10 A schematic diagram of the principle of the cross-attention module provided for Example 1.

[0055] Figure 11 A comparison chart of the results of the classification of the coastal wetlands around the South China Sea provided for Example 1.

[0056] Figure 12 A comparison chart of the classification results of the first data set provided for Example 1.

[0057] Figure 13 A comparison chart of the classification results of the second data set provided for Example 1.

[0058] Figure 14 A comparison chart of the classification results of the third data set provided for Example 1. DETAILED DESCRIPTION

[0059] The accompanying drawings are only intended to illustrate the present patent, and cannot be understood as a limitation thereof;

[0060] In order to better illustrate the present embodiment, some components in the drawings may be omitted, enlarged or reduced, and do not represent the actual size of the product;

[0061] It is understandable for those skilled in the art that some well-known structures and their descriptions in the drawings may be omitted.

[0062] The technical solutions of the present application will be further described below in combination with the drawings and examples.

[0063] Example 1

[0064] As shown in Figure 1 A coastal wetland classification method based on a lightweight multi-directional compressed attention network includes:

[0065] S1: Obtain a remote sensing image and perform preprocessing to obtain a preprocessed remote sensing image;

[0066] S2: Perform wetland screening on the preprocessed remote sensing image to obtain a wetland image;

[0067] S3: Input the wetland image into a lightweight multi-directional compressed attention network to obtain a final classification result map.

[0068] Further, in step S1, the preprocessing includes cloud removal and median filtering.

[0069] In one specific embodiment, the preprocessing method is as follows: based on ArcGIS, a shp file of the study area is generated, projection and other geographic information is supplemented and updated, and the shp file is uploaded to GEE Assets. Based on the GEE remote sensing database, the Sentinel-2 image in the delineated study area is cloud-removed and median-filtered to obtain an image available for network processing.

[0070] Further, as shown in Figure 2 , the wetland screening includes:

[0071] S201: calculating a normalized building index NDBI, a normalized vegetation index NDVI, and a modified normalized water index MNDWI for the preprocessed remote sensing image;

[0072] S202: using the Otsu algorithm to analyze the normalized building index NDBI, the normalized vegetation index NDVI, and the modified normalized water index MNDWI to obtain a decision tree threshold;

[0073] S203: using the decision tree threshold to use a decision tree algorithm to determine whether each pixel in the preprocessed remote sensing image is a wetland, and collecting the wetland determination results to obtain a wetland image.

[0074] It should be noted that the Otsu algorithm (OTSU) refers to an automatic threshold selection algorithm for image segmentation, the core idea of which is to divide the image into foreground and background by traversing all possible thresholds, so that the intra-class variance between the two parts is minimized and the inter-class variance is maximized. As shown in the following formula:

[0075]

[0076] wherein, is the inter-class variance, defined as:

[0077]

[0078] wherein, w1(t) and w2(t) are the foreground and background weights of the threshold t. μ1(t) and μ2(t) are the mean values of the foreground and background. The NDBI value of the image NDBI(x,y) is in the interval [t L ,t U ], the NDVI value of the image NDVI(x,y) is in the interval [t L ,t U ], and the MNDWI value of the image MNDWI(x,y) is in the interval [t L ,t U ].

[0079] When the pixel value size meets the condition that the NDBI is less than the OTSU threshold value and the NDVI is greater than the OTSU threshold value, the pixel point is a vegetation or water area, otherwise, the pixel point is a building land or a bare land area without vegetation coverage. Considering that the high solar elevation angle in the tropics causes high reflectivity of water bodies, which makes the water bodies easily misjudged as buildings and excluded. Therefore, the MNDWI greater than the OTSU threshold value is also included in the maximum wetland range. This will effectively improve the classification efficiency.

[0080] Further, the calculation formulas of the normalized building index NDBI, the normalized vegetation index NDVI and the improved normalized water index MNDWI are as follows:

[0081]

[0082] NIR represents a near-infrared band (wavelength about 780-2526 nm) in the remote sensing image, RED represents a red light band (wavelength about 600-700 nm) in the remote sensing image, MIR represents a mid-infrared band (wavelength about 3.0-20 μm) in the remote sensing image, and GREEN represents a green light band (wavelength about 492-577 nm) in the remote sensing image.

[0083] Further, as shown in the figure, Figure 3 The light multi-directional compression attention network includes a light attention enhanced convolution unit, a multi-directional axial compression attention unit, a cross attention unit and a classification result generation unit.

[0084] The wetland image is input to the input end of the light attention enhanced convolution unit, the output end of the light attention enhanced convolution unit is connected with the input end of the multi-directional axial compression attention unit, the output end of the multi-directional axial compression attention unit is connected with the input end of the cross attention unit, the output end of the cross attention unit is connected with the input end of the classification result generation unit, and the output end of the classification result generation unit outputs a final classification result map.

[0085] It should be noted that, as shown in the figure, Figure 4 The input of the light multi-directional compression attention network is a data cube with a spatial range of 5x5 from a remote sensing image. First, the light attention enhanced convolution unit (LAConv) is used for detail enhancement. Then, the multi-directional axial compression attention unit (MASA) is used to perform attention enhancement on the data in three axial directions to generate three complementary cube features. Subsequently, these patch features are input into the cross attention unit (CA) for multi-feature collaborative fusion. Finally, the features are processed through a fully connected layer to output the prediction result of the network. This architecture can effectively capture the detailed information, direction-dependent relationship and mutual coordination between features in the image by introducing a multi-level attention mechanism.

[0086] Furthermore, the lightweight attention-enhanced convolutional unit includes: a first lightweight attention-enhanced convolutional module, a second lightweight attention-enhanced convolutional module, and a third lightweight attention-enhanced convolutional module;

[0087] like Figure 5 As shown, the first lightweight attention-enhanced convolutional module, the second lightweight attention-enhanced convolutional module, and the third lightweight attention-enhanced convolutional module have the same structure, each including: a first convolutional layer, a second convolutional layer, a third convolutional layer, a first batch normalization layer, a second batch normalization layer, a third batch normalization layer, a first multiplication point, a second multiplication point, a fourth convolutional layer, a fifth convolutional layer, a sixth convolutional layer, a fourth batch normalization layer, a fifth batch normalization layer, a sixth batch normalization layer, a first addition point, a second addition point, a seventh convolutional layer, a seventh batch normalization layer, and a first activation layer;

[0088] The output of the first convolutional layer is connected to the input of the first batch of normalization layers. The output of the second convolutional layer is connected to the input of the second batch of normalization layers. The output of the third convolutional layer is connected to the input of the third batch of normalization layers. The outputs of the first and second batches of normalization layers are connected to the input of the first multiplication point. The outputs of the first and third batches of normalization layers are connected to the input of the second multiplication point. The output of the second multiplication point is connected to the inputs of the fourth, fifth, and sixth convolutional layers. The output of the fourth convolutional layer is connected to the input of the fourth batch of normalization layers. The input of the normalization layer is connected to the first batch of normalization layers. The output of the fifth convolutional layer is connected to the input of the fifth batch of normalization layers. The output of the sixth convolutional layer is connected to the input of the sixth batch of normalization layers. The outputs of the fourth and fifth batches of normalization layers are connected to the input of the first addition point. The outputs of the first and sixth batches of normalization layers are connected to the input of the second addition point. The output of the second addition point is connected to the input of the seventh convolutional layer. The output of the seventh convolutional layer is connected to the input of the seventh batch of normalization layers. The output of the seventh batch of normalization layers is connected to the input of the first activation layer.

[0089] It should be noted that, as Figure 6As shown, the lightweight attention enhanced convolution unit (LAConv) is composed of three parallel branches, which plays an important role, especially in the enhancement of subsequent features in terms of detail. Each branch contains a 2D convolution layer and a batch normalization layer, and generates three matrices respectively: the query matrix q, the key matrix k and the value matrix v. Among them, the transpose of the key matrix k is multiplied by the query matrix q, and the resulting matrix is multiplied by the value matrix v, and then the calculation of the attention mechanism is realized through the convolution operation. In order to further enhance the feature details, the model uses depth separable convolution for subsequent feature refinement processing. In the multi-directional axial compression attention network, the first lightweight attention enhanced convolution module, the second lightweight attention enhanced convolution module and the third lightweight attention enhanced convolution module are arranged in parallel and share weights. This design not only generates three data cubes that have been enhanced in detail at the same time, providing a solid foundation for subsequent feature enhancement, but also effectively reduces the complexity of the model.

[0090] Further, the multi-directional axial compression attention unit includes a first multi-directional axial compression attention module, a second multi-directional axial compression attention module and a third multi-directional axial compression attention module.

[0091] As shown in Figure 7 , the first multi-directional axial compression attention module, the second multi-directional axial compression attention module and the third multi-directional axial compression attention module have the same structure, and each includes an average pooling layer, a skewness calculation layer, a kurtosis calculation layer, a variance calculation layer, a third addition point and a fourth addition point.

[0092] The output end of the average pooling layer is connected with the input end of the skewness calculation layer, the input end of the kurtosis calculation layer and the input end of the variance calculation layer. The output end of the skewness calculation layer, the output end of the kurtosis calculation layer, the output end of the variance calculation layer and the input end of the average pooling layer are connected with the input end of the third addition point. The output end of the third addition point is connected with the input end of the fourth addition point.

[0093] It should be noted that, as shown in Figure 8As shown, the multidirectional axial compression attention unit (MASA) optimizes the performance of the attention mechanism while maintaining effectiveness by enhancing the model's interpretability and reducing training difficulty. The core task of the multidirectional axial compression attention unit (MASA) is to process the three data cubes generated by the multidirectional axial compression attention unit (LAConv) and convert them into three vectors in different directions through pooling operations. These vectors are used for attention enhancement along the three axes (i.e., x-axis, y-axis, and z-axis), where skewness, kurtosis, and variance are introduced as statistical quantities. Specifically, variance is used to express the texture and edge information that may exist in the image, and it helps to identify channels that exhibit significant changes in the image in channel attention. Skewness helps to capture the asymmetry that may exist in the image, such as shadows or reflections, thereby enhancing the model's robustness and generalization ability in diverse environments. The application of skewness in channel attention further strengthens the nonlinear features on the channel. Kurtosis is usually used for outlier detection, and a high kurtosis value indicates that there may be significant features or noise in certain positions of the image along an axis. The three statistical quantities are weighted by three learnable parameters to ensure that the multidirectional axial compression attention unit (MASA) has stronger adaptability and performance while maintaining the lightweight of the module.

[0094] In one embodiment, an activation layer can be added before the third addition point.

[0095] Further, the calculation formula of the skewness calculation layer is as follows:

[0096]

[0097] E represents expectation, i represents the serial number, and x i represents the ith value of the random variable X, μ represents the mean of the random variable value, and σ represents the standard deviation of the random variable value;

[0098] The calculation formula of the kurtosis calculation layer is as follows:

[0099]

[0100] X represents a random variable, n represents the total number of random variable values, i represents the serial number, and x i represents the ith value of the random variable X, represents the mean of the random variable X;

[0101] The calculation formula of the variance calculation layer is as follows:

[0102]

[0103] p i represents the value of the random variable X taking x iThe probability, where n represents the total number of values ​​that the random variable can take, x i Let represent the i-th value of the random variable X, where i represents the index and X represents the random variable.

[0104] Furthermore, the cross-attention unit includes: a first cross-attention module, a second cross-attention module, and a third cross-attention module;

[0105] like Figure 9 As shown, the first cross-attention module, the second cross-attention module, and the third cross-attention module have the same structure, all including: the eighth batch normalization layer, the ninth batch normalization layer, the first linear layer, the second linear layer, the third linear layer, the fourth linear layer, the attention score layer, and the result summary layer.

[0106] The output of the eighth batch of normalization layers is connected to the input of the first linear layer, the output of the first linear layer is connected to the input of the second linear layer, the output of the ninth batch of normalization layers is connected to the input of the third linear layer, the output of the third linear layer is connected to the input of the fourth linear layer, the outputs of the second and fourth linear layers are connected to the input of the attention score layer, and the outputs of the attention score layer and the second linear layer are connected to the input of the result summarization layer.

[0107] It should be noted that, as Figure 10 As shown, Cross-Attention (CA) is a technique for information interaction across modalities or different scales. In this model, a CrossTransformer architecture based on cross-attention is employed to achieve effective complementarity of features from the three branches mentioned above. In summary, the three branches extract features from three directions, which serve as context features and target features for each other. By introducing bidirectional interactive attention, cross-channel information fusion can be achieved. This structural design allows cross-attention to effectively capture the interdependencies between features in different directions, thereby enhancing the model's feature representation capabilities. Through this information interaction mechanism, the model can more fully utilize the complementarity of features in different directions, improving its performance in complex tasks.

[0108] A coastal wetland classification system based on a lightweight multi-directional compressed attention network includes:

[0109] Preprocessing module: Acquires remote sensing images and performs preprocessing to obtain preprocessed remote sensing images;

[0110] Wetland screening module: performs wetland screening on the preprocessed remote sensing image to obtain wetland images;

[0111] The network inference module: inputting the wetland image into a light multi-directional compressed attention network to obtain a final classification result map.

[0112] It should be noted that, as shown in Figures 11 to 14 The light multi-directional compressed attention network (LMDSAN-CCWC) is suitable for large-scale, cross-climate zone and cloud deployment. It has a clever engineering design, successfully reduces the model parameter quantity to the minimum and maintains the model accuracy. The model is based on a convolution module, uses three visual Transformer structures with weight sharing to construct enhanced features, and calculates compressed attention on three axes based on the three features, and based on this, uses cross attention to cooperate the features of the three branches. The whole model integrates mathematical models and networks together, so that this kind of engineering design performs better than other classic models in three types of coastal wetland features (i.e. mangrove, bare beach and marsh). In the classification task of the coastal wetlands around the South China Sea, the overall accuracy OA of the present application is 1.0099 times that of SeaFormer (the OA of LMDSAN-CCWC is 0.9500, and the OA of SeaFormer is 0.9406) based on only 0.009 times the parameter quantity of the light neural network SeaFormer (the parameter quantity of LMDSAN-CCWC is 57KB, and the parameter quantity of SeaFormer is 6579KB). The training time is 0.6176 times that of SeaFormer (the training time of LMDSAN-CCWC is 106.27s, and the training time of SeaFormer is 172.06s). The method is proved to be deployable in the cloud, and effectively solves the classification accuracy problem of large-scale study area, and constructs high-precision coastal wetland mapping, which provides technical support for the research of coastal wetland resource management and ecological protection.

[0113] The same or similar reference signs correspond to the same or similar components;

[0114] The positional relationship described in the drawings is only used for illustrative description, and cannot be understood as a limitation on the patent;

[0115] Obviously, the above embodiments of the present application are only examples for clearly illustrating the present application, and are not intended to limit the embodiments of the present application. Based on the above description, other different forms of changes or variations can be made by those skilled in the art. Here, all the embodiments are not required to be exhausted. Any modification, equivalent replacement and improvement made within the spirit and principle of the present application shall be included in the protection scope of the claims of the present application.

Claims

1. A coastal wetland classification method based on a lightweight multi-directional compressed attention network, characterized in that, The method comprises: S1: obtaining a remote sensing image and performing preprocessing to obtain a preprocessed remote sensing image; S2: performing wetland screening on the preprocessed remote sensing image to obtain a wetland image; S3: inputting the wetland image into a lightweight multi-directional compression attention network to obtain a final classification result map; The lightweight multi-directional compression attention network comprises a lightweight attention enhanced convolution unit, a multi-directional axial compression attention unit, a cross attention unit, and a classification result generation unit. The input end of the wetland image is connected to the input end of the lightweight attention enhanced convolution unit, the output end of the lightweight attention enhanced convolution unit is connected to the input end of the multi-directional axial compression attention unit, the output end of the multi-directional axial compression attention unit is connected to the input end of the cross attention unit, the output end of the cross attention unit is connected to the input end of the classification result generation unit, and the output end of the classification result generation unit outputs the final classification result map. The lightweight attention enhanced convolution unit comprises a first lightweight attention enhanced convolution module, a second lightweight attention enhanced convolution module, and a third lightweight attention enhanced convolution module. The first lightweight attention enhanced convolution module, the second lightweight attention enhanced convolution module, and the third lightweight attention enhanced convolution module have the same structure and comprise a first convolution layer, a second convolution layer, a third convolution layer, a first batch normalization layer, a second batch normalization layer, a third batch normalization layer, a first multiplication point, a second multiplication point, a fourth convolution layer, a fifth convolution layer, a sixth convolution layer, a fourth batch normalization layer, a fifth batch normalization layer, a sixth batch normalization layer, a first addition point, a second addition point, a seventh convolution layer, a seventh batch normalization layer, and a first activation layer. The output end of the first convolution layer is connected to the input end of the first batch normalization layer, the output end of the second convolution layer is connected to the input end of the second batch normalization layer, the output end of the third convolution layer is connected to the input end of the third batch normalization layer, the output ends of the first batch normalization layer and the second batch normalization layer are connected to the input end of the first multiplication point, the output end of the first multiplication point and the output end of the third batch normalization layer are connected to the input end of the second multiplication point, the output end of the second multiplication point is connected to the input ends of the fourth convolution layer, the fifth convolution layer, and the sixth convolution layer, the output end of the fourth convolution layer is connected to the input end of the fourth batch normalization layer, the output end of the fifth convolution layer is connected to the input end of the fifth batch normalization layer, the output end of the sixth convolution layer is connected to the input end of the sixth batch normalization layer, the output ends of the fourth batch normalization layer and the fifth batch normalization layer are connected to the input end of the first addition point, the output end of the first addition point and the output end of the sixth batch normalization layer are connected to the input end of the second addition point, the output end of the second addition point is connected to the input end of the seventh convolution layer, the output end of the seventh convolution layer is connected to the input end of the seventh batch normalization layer, and the output end of the seventh batch normalization layer is connected to the input end of the first activation layer.

2. The coastal wetland classification method based on lightweight multi-directional compression attention network according to claim 1, characterized in that, In step S1, the preprocessing comprises cloud removal and median filtering.

3. The coastal wetland classification method based on lightweight multi-directional compression attention network according to claim 1, characterized in that, The wetland screening comprises: S201: calculating a normalized building index NDBI, a normalized vegetation index NDVI and a modified normalized water index MNDWI from the preprocessed remote sensing image; S202: obtaining a decision tree threshold by using the Otsu algorithm according to the normalized building index NDBI, the normalized vegetation index NDVI and the modified normalized water index MNDWI; S203: determining whether each pixel in the preprocessed remote sensing image is a wetland by using the decision tree algorithm with the decision tree threshold, and obtaining a wetland image by collecting the wetland determination results.

4. The coastal wetland classification method based on lightweight multi-directional compression attention network according to claim 3, characterized in that, The calculation formulas of the normalized building index NDBI, the normalized vegetation index NDVI and the modified normalized water index MNDWI are as follows: NIR represents a near-infrared band in the remote sensing image, RED represents a red band in the remote sensing image, MIR represents a mid-infrared band in the remote sensing image, and GREEN represents a green band in the remote sensing image.

5. The coastal wetland classification method based on lightweight multi-directional compression attention network according to claim 1, characterized in that, The multi-direction axial compression attention unit comprises a first multi-direction axial compression attention module, a second multi-direction axial compression attention module and a third multi-direction axial compression attention module. The first multi-direction axial compression attention module, the second multi-direction axial compression attention module and the third multi-direction axial compression attention module have the same structure and each comprises an average pooling layer, a skewness calculation layer, a kurtosis calculation layer, a variance calculation layer, a third addition point and a fourth addition point. The output end of the average pooling layer is connected with the input ends of the skewness calculation layer, the kurtosis calculation layer and the variance calculation layer, the output ends of the skewness calculation layer, the kurtosis calculation layer and the variance calculation layer and the input end of the average pooling layer are connected with the input end of the third addition point, and the output end of the third addition point is connected with the input end of the fourth addition point.

6. The coastal wetland classification method based on lightweight multi-directional compression attention network according to claim 5, characterized in that, The calculation formula of the skewness calculation layer is as follows: denotes expectation, i denotes the index, denotes a random variable the i-th value of, denotes the mean value of the values of the random variable, denotes the standard deviation of the values of the random variable; The calculation formula of the kurtosis calculation layer is as follows: X denotes a random variable, denotes the total number of values of the random variable X, i denotes the index, denotes the i-th value of the random variable X, denotes the mean value of the random variable X; The calculation formula of the variance calculation layer is as follows: then represents a random variable take the probability of denotes the total number of values that a random variable takes, denotes the ith value of a random variable X, where i denotes the index and X denotes the random variable.

7. The coastal wetland classification method based on lightweight multi-directional compression attention network according to claim 1, characterized in that, The cross attention unit comprises a first cross attention module, a second cross attention module and a third cross attention module. The first cross attention module, the second cross attention module and the third cross attention module have the same structure and each comprises an eighth batch normalization layer, a ninth batch normalization layer, a first linear layer, a second linear layer, a third linear layer, a fourth linear layer, an attention score layer and a result collection layer. The output end of the eighth batch normalization layer is connected with the input end of the first linear layer, the output end of the first linear layer is connected with the input end of the second linear layer, the output end of the ninth batch normalization layer is connected with the input end of the third linear layer, the output end of the third linear layer is connected with the input end of the fourth linear layer, the output ends of the second linear layer and the fourth linear layer are connected with the input end of the attention score layer, the output end of the attention score layer and the output end of the second linear layer are connected with the input end of the result collection layer.

8. A coastal wetland classification system based on lightweight multi-directional compressed attention network, applied to the classification method of any one of claims 1-7, characterized in that, The pre-processing module is configured to obtain a remote sensing image and pre-process the remote sensing image to obtain a pre-processed remote sensing image; The wetland screening module is configured to screen the pre-processed remote sensing image to obtain a wetland image; ​ Network inference module: input the wet image into a light multi-directional compression attention network to obtain a final classification result map.

Citation Information

Patent Citations

  • Hybrid precision quantification method of deep neural network and related device

    CN119204154A

  • Infrared spectrogram correlation intelligent detection method and apparatus

    WO2016106956A1