A Wetland Mapping Method and System Based on Pre-trained Models and Characteristic Distillation Models
By combining pre-trained models and feature distillation models, the problem of insufficient sample quantity in wetland remote sensing image classification is solved, and efficient and accurate wetland landscape classification is achieved.
Patent Information
- Application Number
- CN202511189963.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-08-25
- Publication Date
- 2025-10-31
- Estimated Expiration
- 2045-08-25
AI Technical Summary
Existing technologies require a large amount of labeled data and complex models for wetland remote sensing image classification, resulting in high computational costs and making it difficult to classify wetland images quickly.
We employ a method based on pre-trained models and feature distillation models to extract deep features through self-supervised learning and use a lightweight model for semantic segmentation to achieve wetland landscape classification.
It reduces the dependence on the number of samples, improves the accuracy of wetland landscape classification and the stability of the model, and is suitable for small sample learning scenarios.
Smart Images

Figure CN120687520B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of remote sensing information processing technology, specifically to a wetland mapping method and system based on a pre-trained model and a feature distillation model. Background Technology
[0002] Wetland monitoring and mapping are crucial prerequisites for wetland protection, ecological restoration, wetland management, and ultimately, sustainable development. Traditional wetland survey methods primarily rely on manual investigations and visits, which are time-consuming, labor-intensive, and inherently dangerous. With the development of geographic information science and remote sensing technology, wetland mapping and monitoring of dynamic changes can be achieved through remote sensing. Supervised classification methods, such as random forests, can extract abstract features from multi-source imagery and geographic information data, and can autonomously learn and optimize models, thus enabling large-scale automated mapping. However, there is still significant room for improvement in mapping accuracy and efficiency.
[0003] Currently, deep learning methods have shown good results in wetland remote sensing image classification and mapping. However, deep learning requires a large amount of labeled data, or the complex AI model structure leads to high computational costs, placing a huge cost and time burden on wetland mapping over long periods. Therefore, how to quickly classify wetland images using fewer samples is an urgent problem to be solved. This invention provides a wetland mapping method and system based on a pre-trained model and a feature distillation model, which enables the classification of wetland landscapes with fewer samples, improving the accuracy of wetland landscape classification. Summary of the Invention
[0004] The purpose of this invention is to address the technical problem of difficulty in quickly classifying wetland images using a limited number of samples in existing technologies. The invention provides a wetland mapping method and system based on a pre-trained model and a feature distillation model. This method involves designing a pre-trained self-supervised learning model to extract deep features, inputting these features into a lightweight model obtained through feature distillation based on the pre-trained model, and then performing supervised wetland landscape classification using a linear multilayer perceptron within the lightweight model. This achieves the technical effect of classifying wetland landscapes using a limited number of samples.
[0005] To achieve the above-mentioned objectives, the present invention provides the following technical solution:
[0006] Wetland mapping methods based on pre-trained models and feature distillation models include:
[0007] Remote sensing images of the wetland at different times are acquired, the remote sensing images including images of the wetland with different remote sensing parameters; the remote sensing images are classified into regions based on the topographic relief in the remote sensing parameters to obtain the core area representing the wetland; pixels are obtained from the core area.
[0008] Different remote sensing parameters of the corresponding pixels at the same time are combined to obtain a parameter sequence; the parameter sequence is then input into the first model.
[0009] The first model converts the combined parameter sequence into a multidimensional image using multiple functions; the multidimensional image is semantically segmented using a pre-trained model and a lightweight model to obtain the wetland category represented by the pixel for wetland landscape classification; the lightweight model is obtained by knowledge distillation of the pre-trained model based on spectral and spatial features.
[0010] Import the wetland category and the corresponding pixel location into the geographic information system to create a wetland type map.
[0011] As a preferred embodiment of the present invention, after acquiring remote sensing images with multiple different remote sensing parameters, the method further includes: classifying the remote sensing images into regions based on the topographic relief in the remote sensing parameters, including:
[0012] At least one first threshold and at least one second threshold are preset, wherein the first threshold is less than the second threshold; pixels with terrain relief less than the first threshold are denoted as core areas representing wetlands; pixels with terrain relief greater than or equal to the second threshold are denoted as mountainous areas;
[0013] Pixels whose terrain undulation is greater than or equal to the first threshold and less than the second threshold are denoted as buffer zones representing alternating wetlands and mountains.
[0014] As a preferred technical solution of the present invention, after the region classification, the method further includes: performing binary classification on the buffer zone using the first model to divide the buffer zone into wetland pixels and mountain pixels; and adding the wetland pixels of the buffer zone to the core region.
[0015] As a preferred technical solution of the present invention, at least one interval threshold is preset between the first threshold and the second threshold to obtain multiple buffers.
[0016] As a preferred technical solution of the present invention, the combination of different remote sensing parameters of the corresponding pixel includes:
[0017] The remote sensing images of different spectral bands are combined using a geographic information system to form a true-color image representing spectral characteristics, thereby obtaining the RGB values of the remote sensing images.
[0018] For all the aforementioned pixels, the RGB values, slope index, aspect index, normalized vegetation index (NDVI), normalized water index (NDWI), and visible atmospheric drag index (VARI) of the pixel are combined into the parameter sequence.
[0019] For each cell in the buffer, calculate the first distance from the cell to the inner boundary that is the smallest, where the inner boundary is a plurality of cells corresponding to the first threshold; calculate the second distance from the cell to the outer boundary that is the smallest, where the outer boundary is a plurality of cells corresponding to the second threshold; calculate the ratio of the first distance to the second distance to obtain the distance ratio; add the terrain undulation and the distance ratio to the parameter sequence;
[0020] The slope index and aspect index of the remote sensing image were extracted using a geographic information system based on DEM data.
[0021] The Normalized Difference Vegetation Index (NDVI), Normalized Difference Water Index (NDWI), and Visible Atmospheric Drag Index (VARI) were calculated using a Geographic Information System based on the spectral bands and reflectance of the remote sensing images.
[0022] The terrain relief is obtained by calculating the elevation based on the remote sensing image using a geographic information system.
[0023] As a preferred embodiment of the present invention, the step of converting the parameter sequence into a multidimensional image includes:
[0024] The parameter sequence is subjected to Grammy angle field transformation, and the values in the resulting two-dimensional Grammy angle field matrix are converted into angles to obtain the first channel image;
[0025] The parameter sequence is subjected to Markov transition field transformation, and the resulting transition matrix is used as the second channel diagram.
[0026] The parameter sequence is transformed into a recursive graph, and the resulting recursive matrix is used as the third channel graph.
[0027] The first channel image, the second channel image, and the third channel image are combined into an HSV color space. One of the channel images is converted into an H channel, one of the remaining two channel images is converted into an S channel or a V channel, and the last channel image is converted into a V channel or an S channel. After converting the HSV color space into an RGB color space, the multidimensional image is obtained.
[0028] As a preferred embodiment of the present invention, after acquiring remote sensing images with multiple different remote sensing parameters, the method further includes: standardizing the remote sensing images based on the remote sensing parameters, including:
[0029] From the remote sensing images acquired by different sensors, the remote sensing images with the same spectral band are selected to obtain multispectral remote sensing images;
[0030] If the multispectral remote sensing image has a panchromatic spectral band, the panchromatic spectral remote sensing image and the multispectral remote sensing image are fused to improve the resolution; if the multispectral remote sensing image does not have a panchromatic spectral band, the resolution of the multispectral remote sensing image is improved by k-nearest neighbor interpolation.
[0031] The radiometric resolution of the multispectral remote sensing image is adjusted to a preset quantization bit depth.
[0032] As a preferred technical solution of the present invention, the semantic segmentation includes:
[0033] Depth features are extracted from the multidimensional image using a pre-trained model, and the depth features are enhanced using a lightweight model to extract pixel ultimate features. The parameter sequence is then fused with the pixel ultimate features through a residual network to obtain new pixel ultimate features, which are then used as input to the classifier.
[0034] As a preferred technical solution of the present invention, when training the first model, before inputting the parameter sequence into the first model, the method further includes: classifying multiple parameter sequences based on spatial distance and / or feature similarity, wherein the method includes:
[0035] Traverse all the pixels corresponding to the parameter sequence to obtain the current pixel;
[0036] Obtain multiple pixels adjacent to the current pixel and denot them as adjacent pixels; traverse the adjacent pixels and combine them with the current pixel to form a pair of pixels; classify the multiple pairs of pixels as spatial proximity positive samples.
[0037] Based on the parameter sequence of the current pixel, the feature similarity is calculated with other pixels to obtain multiple pixels whose feature similarity is greater than a preset similarity threshold, and these are recorded as similar pixels; the similar pixels are traversed and combined with the current pixel to form a pair of pixels, and the multiple pairs of pixels are classified as feature neighbor positive samples;
[0038] Multiple pixels whose feature similarity is less than or equal to the similarity threshold are obtained and denoted as negative class pixels; the negative class pixels are traversed and combined with the current pixel to form a pair of pixels, and the multiple pairs of pixels are classified as negative class samples.
[0039] As a preferred embodiment of the present invention, training the first model includes:
[0040] The first model obtains paired pixels from the spatially neighboring positive class samples, the feature-nearest positive class samples, and the negative class samples, respectively. The first model receives the paired pixels as input, converts the parameter sequences of the paired pixels into the multidimensional image, extracts features from the paired pixels using the pre-trained model and the lightweight model, and constructs a sample loss function based on the feature similarity of the paired pixels. The sample loss functions for different sample categories are summed to obtain the loss function L of the first model, as shown in the following formula:
[0041] ;
[0042] in, For the paired pixels, i = 1, 2, 3; when i = 1, The sample loss function is the spatially nearest positive class sample; when i=2, The sample loss function is the feature's nearest positive class sample; when i=3, The sample loss function for negative class samples; These are the weighting coefficients; This is a hyperparameter.
[0043] As a preferred embodiment of the present invention, the method for constructing the sample loss function includes:
[0044] The pre-trained model is used to extract depth features from the paired pixels, and the class similarity between the depth features is calculated to obtain the first decision feature.
[0045] The deep features are enhanced by the lightweight model, the final features of the paired pixels are extracted, the class similarity between the final features of the pixels is calculated, and the second decision feature is obtained.
[0046] The sample loss function of the lightweight model is constructed based on the first decision feature and the second decision feature, such that the more similar the first decision feature and the second decision feature are, the smaller the value of the sample loss function.
[0047] This invention also provides a wetland mapping system based on a pre-trained model and a feature distillation model, comprising:
[0048] The preprocessing module is used to acquire multiple remote sensing images with different remote sensing parameters, obtain pixels from the remote sensing images, combine different remote sensing parameters of the pixels at corresponding locations to obtain a parameter sequence, and input the parameter sequence into the first model.
[0049] The semantic segmentation module is used to convert the parameter sequence into a multi-dimensional image using the first model, perform semantic segmentation on the multi-dimensional image using a pre-trained model and a lightweight model to obtain pixel final features, and classify the pixel final features using a classifier to obtain the wetland category of the pixel; the lightweight model is obtained by knowledge distillation of the pre-trained model based on spectral features and spatial features;
[0050] The mapping module imports the wetland category and the corresponding pixel location into the geographic information system to create a wetland type map.
[0051] Compared with the prior art, the beneficial effects of the present invention are as follows:
[0052] 1. The wetland mapping method provided by this invention, based on remote sensing image pixels, enhances the parameter sequence of pixels from one dimension to a high dimension, inputs it into a pre-trained self-supervised learning model to extract depth features from the pixels, and enhances the depth features with a lightweight model distilled from the pre-trained model, reducing the input data required for semantic segmentation; by fusing the initial pixel parameter sequence with the enhanced features through a residual network, the technical effect of accurately classifying wetland landscapes with fewer samples is achieved, which is conducive to better capturing various patterns and relationships in the image, improving the expressive power of the model, and providing more accurate modeling results.
[0053] 2. There is an overlapping transitional zone between mountainous areas and wetlands, which is difficult to distinguish clearly. In order to capture the distribution of wetland landscape in this transitional zone, the remote sensing image is divided into three distinct blocks: mountainous area, buffer zone, and core zone. The pixels in the buffer zone are further classified, and the wetland parts in the buffer zone are merged into the core zone. The remote sensing image of the core zone is used for wetland landscape classification, which increases the expression of wetland characteristics and helps to improve the completeness and accuracy of wetland mapping.
[0054] 3. While dimensionality upscaling enhances the ability of each pixel to represent features, it still involves simple transformations and combinations of the original features, making it difficult to directly reflect deep features. After dimensionality upscaling, the pixel classification task transforms into classifying RGB images representing the pixels. The pre-trained DINOv2 model already possesses general feature extraction capabilities. Using the DINOv2 model to extract deep features from multi-dimensional images reduces reliance on large amounts of labeled data, improves model stability and overfitting resistance, and is suitable for small-sample learning scenarios. Attached Figure Description
[0055] Figure 1 This is a schematic diagram of the structure of the wetland mapping system provided by the present invention;
[0056] Figure 2 This is a flowchart illustrating the wetland mapping method provided by the present invention.
[0057] Figure 3 This is a schematic diagram showing the results of regional classification of remote sensing images.
[0058] Figure 4 Remote sensing image maps corresponding to multiple input features;
[0059] Figure 5 This is a schematic diagram of the structure of the first model;
[0060] Figure 6 A flowchart illustrating the semantic segmentation process for the first model;
[0061] Figure 7 This is a flowchart illustrating the process of feature upscaling of a one-dimensional sequence of pixels.
[0062] Figure 8 This is a schematic diagram of the lightweight model. Detailed Implementation
[0063] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments.
[0064] Therefore, the following detailed description of embodiments of the present invention is not intended to limit the scope of the claimed invention, but merely illustrates some embodiments of the invention. All other embodiments obtained by those skilled in the art based on the embodiments of the present invention without inventive effort are within the scope of protection of the present invention.
[0065] It should be noted that, unless otherwise specified, the embodiments and features and technical solutions in the present invention can be combined with each other.
[0066] It should be noted that similar labels and letters in the following figures indicate similar items. Therefore, once an item is defined in one figure, it does not need to be further defined and explained in subsequent figures.
[0067] In the description of this invention, it should be noted that the terms "upper," "lower," etc., indicate the orientation or positional relationship based on the orientation or positional relationship shown in the accompanying drawings, or the orientation or positional relationship commonly used when the product of this invention is in use, or the orientation or positional relationship commonly understood by those skilled in the art. These terms are only for the convenience of describing this invention and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation, and therefore should not be construed as a limitation of this invention. In addition, the terms "first," "second," etc., are only used to distinguish descriptions and should not be construed as indicating or implying relative importance.
[0068] For example Figure 1 As shown, the wetland mapping system based on a pre-trained model and a feature distillation model provided in this embodiment includes:
[0069] The preprocessing module is used to acquire multiple remote sensing images with different remote sensing parameters, obtain pixels from the remote sensing images, combine different remote sensing parameters of the pixels at corresponding locations to obtain a parameter sequence, and input the parameter sequence into the first model.
[0070] The semantic segmentation module is used to convert the parameter sequence into a multi-dimensional image using the first model, perform semantic segmentation on the multi-dimensional image using a pre-trained model and a lightweight model to obtain pixel final features, and classify the pixel final features using a classifier to obtain the wetland category of the pixel; the lightweight model is obtained by knowledge distillation of the pre-trained model based on spectral features and spatial features;
[0071] The mapping module imports the wetland category and the corresponding pixel location into the geographic information system to create a wetland type map.
[0072] In this embodiment, for example Figure 2 As shown, the wetland mapping system is used to execute the wetland mapping method based on a pre-trained model and a feature distillation model provided in this embodiment, including:
[0073] Remote sensing images of the wetland at different times are acquired, the remote sensing images including images of the wetland with different remote sensing parameters; the remote sensing images are classified into regions based on the topographic relief in the remote sensing parameters to obtain the core area representing the wetland; pixels are obtained from the core area.
[0074] Different remote sensing parameters of the corresponding pixels at the same time are combined to obtain a parameter sequence; the parameter sequence is then input into the first model.
[0075] The first model converts the combined parameter sequence into a multi-dimensional image using multiple functions; semantic segmentation of the multi-dimensional image is performed using a pre-trained model and a lightweight model to obtain the wetland category represented by the pixel for wetland landscape classification. In this embodiment, the wetland categories include: river-lake, marsh, marshy meadow, meadow, meadow-shrub-tree, bare sand, building-road, and mountain. The lightweight model is obtained by knowledge distillation of the pre-trained model based on spectral and spatial features.
[0076] The wetland categories and the corresponding pixel locations are imported into geographic information systems such as ArcGIS to create wetland type maps.
[0077] In this embodiment, the research area of the remote sensing image is set as the Ruoergai Wetland Nature Reserve, whose administrative area includes Sichuan Province and Gansu Province; among them, Sichuan Province includes Aba County, Ruoergai County, Hongyuan County and Songpan County, and Gansu Province includes Maqu County and Luqu County.
[0078] In this embodiment, the research time series of remote sensing images is set to 30 years. Due to the long time series, the types of remote sensing images available are limited; simultaneously, clouds have a significant impact on the quality of remote sensing images, necessitating the selection of images with fewer clouds in the core research area as input data. Optionally, the method also includes interpolating the pixels corresponding to clouds in the remote sensing images using the k-nearest neighbor algorithm based on the pixels corresponding to adjacent land cover, thereby achieving the purpose of cloud removal. Considering the image acquisition time, imaging quality and stability, spectral consistency, and data acquisition cost, Landsat surface reflectance data is used, as shown in Table 1. Landsat surface reflectance data varies in data type due to differences in sensors used by different satellites. Therefore, standardization processing of Landsat surface reflectance data is required.
[0079] Table 1. Data Sources and Corresponding Years
[0080] ;
[0081] In one embodiment, remote sensing parameters based on Landsat surface reflectance data, including but not limited to spectral band type, spatial resolution, and radiometric resolution, are used to standardize the remote sensing image. The number of spectral band types determines the amount of data for different types of remote sensing images; spatial resolution measures the ground extent corresponding to a single pixel in the remote sensing image and is a key factor in determining the usability of the classification results; improving the spatial resolution of the image can reduce interference from mixed pixels; radiometric resolution reflects the sensor's ability to distinguish differences in radiation intensity.
[0082] In one specific implementation, for Landsat data with different sensor parameters, remote sensing images with the same spectral bands are selected. Different spectral bands in the remote sensing images correspond to different data sizes. Furthermore, remote sensing images with the same or similar wavelength parameters are selected based on the sensor parameters of the Landsat surface reflectance data. Specifically, Landsat5 and Landsat7 have identical sensor parameters, Landsat8 and Landsat9 have identical sensor parameters, and the wavelength values between Landsat5 / 7 and Landsat8 / 9 are very close. Therefore, for different types of Landsat surface reflectance data from all years, remote sensing images with six common spectral bands for Landsat5 / 7 / 8 / 9 are retained to obtain multispectral remote sensing images, including blue spectral band B1, green spectral band B2, red spectral band B3, near-infrared spectral band B4, shortwave infrared 1 spectral band B5, and shortwave infrared 2 spectral band B6.
[0083] In another specific implementation, the resolution of multispectral remote sensing images with the same spectral bands is improved. Panchromatic spectral bands are added to Landsat 7 / 8 / 9 remote sensing images. Fusing the panchromatic spectral images with the multispectral images can improve the spatial resolution from 30m to 15m. Since the Landsat 5 sensor design does not include panchromatic spectral bands, to ensure all input remote sensing images have the same spatial resolution, a super-resolution operation with a scaling factor of 2 is performed on the Landsat 5 remote sensing images using k-nearest neighbor interpolation, improving the spatial resolution of Landsat 5 from 30m to 15m resolution multispectral remote sensing images.
[0084] In another specific implementation, the radiometric resolution of the unified multispectral remote sensing images is set to a preset quantization bit depth. In this embodiment, the quantization bit depth of all multispectral remote sensing images is converted to 16-bit.
[0085] In this embodiment, after acquiring remote sensing images with multiple different remote sensing parameters, the method further includes: classifying the remote sensing images into regions based on the topographic relief in the remote sensing parameters. For example, in this embodiment... Figure 3 As shown in (a), multiple classification results are marked and distinguished using multiple different colors, where gray represents mountainous areas, yellow represents buffer zones, and green represents core areas. Methods for region classification include:
[0086] The terrain relief is calculated based on the elevation of the remote sensing image using geographic information systems such as ArcGIS. At least one first threshold and at least one second threshold are preset, where the first threshold is less than the second threshold. Pixels with terrain relief less than the first threshold are designated as core areas representing wetlands. Pixels with terrain relief greater than or equal to the first threshold and less than the second threshold are designated as buffer zones representing the intersection of wetlands and mountains. A schematic diagram of the buffer zones is shown below. Figure 3 (b) and Figure 3 As shown in (d), the pixels with terrain undulation greater than or equal to the second threshold are denoted as mountainous areas.
[0087] Optionally, at least one interval threshold is preset between the first threshold and the second threshold to obtain multiple buffers.
[0088] In another embodiment, for example Figure 3 (c) and Figure 3 As shown in (e), after the region classification, the method further includes: inputting the remote sensing image corresponding to the buffer into the first model, performing binary classification based on the terrain undulation, recording the pixels with terrain undulation less than a preset third threshold as wetland pixels, and adding the wetland pixels of the buffer to the core area; recording the pixels with terrain undulation greater than or equal to the third threshold as mountain pixels, and adding the mountain pixels of the buffer to the mountain area. Figure 3 middle, Figure 3 (c) is Figure 3 (b) Schematic diagram after regional classification; Figure 3 (e) is Figure 3 (d) Schematic diagram after regional classification.
[0089] There is a transitional zone between mountainous areas and wetlands that is difficult to distinguish clearly. In order to capture the distribution of wetland landscapes in this transitional zone, remote sensing images are divided into three distinct blocks: mountainous areas, buffer zones, and core zones. Pixels in the buffer zones are further classified, and the wetland parts in the buffer zones are merged into the core zones. Remote sensing images of the core zones are used for wetland landscape classification, which increases the expression of wetland characteristics and helps to improve the completeness and accuracy of wetland mapping.
[0090] Furthermore, the accuracy of pixel-based remote sensing image segmentation depends on the features of each pixel. In this embodiment, the input feature data types of the first model are shown in Table 2, and different combinations of remote sensing parameters are used to obtain parameter sequences for the pixels classified in different regions.
[0091] Table 2 Input Features and Their Meanings
[0092] ;
[0093] Specifically, for example Figure 4 As shown in (a), remote sensing images of six spectral bands are combined into a true-color image using ArcGIS software to represent the spectral characteristics of the remote sensing images.
[0094] Secondly, since vegetation growth and water content are core characteristics of wetlands, vegetation images are obtained by calculating the Normalized Difference Vegetation Index (NDVI) based on spectral bands and reflectance using ArcGIS software, for example... Figure 4 As shown in (b), the Normalized Difference Vegetation Index (NDWI) ranges from -0.18 to 0.63. The Normalized Difference Water Index (NDWI) is calculated using ArcGIS software to obtain the water index image, for example... Figure 4 As shown in (c), the normalized water index takes values of [-0.88, 0.17]; the visible atmospheric drag index (VARI) is calculated using ArcGIS software to obtain atmospheric images, for example... Figure 4 As shown in (d), the atmospheric drag index is visible, with values ranging from -0.57 to 0.19. Vegetation, water index, and atmospheric images are used to represent wetland surface cover characteristics.
[0095] In addition, since topography and landforms also affect the distribution of wetland landscapes, this embodiment also acquired ALOS 12.5-meter resolution DEM remote sensing images. The slope index was calculated from the DEM remote sensing images using ArcGIS software to obtain slope index images, for example... Figure 4 As shown in (e), the slope index ranges from -1 degree to 359.87 degrees. The slope aspect index is calculated using ArcGIS software to obtain an aspect index image, for example... Figure 4 As shown in (f), the aspect index takes values of [0 degrees, 84.74 degrees]. Slope index images and aspect index images are used to represent the spatial characteristics of topographic features.
[0096] Because the buffer zone contains a mix of wetlands and mountains, and the mountainous and wetland core areas differ significantly in geomorphological features while exhibiting spatial proximity, the remote sensing images within the buffer zone are supplemented with topographic relief (RDLS) and distance-to-buffer-boundary ratio (PBBI). This results in relief images and distance-to-buffer-boundary ratio images, for example... Figure 4 (g) and Figure 4 As shown in (h), it is used to represent the characteristics of the buffer space.
[0097] Topographic relief (RDLS) is calculated by taking the difference between the highest and lowest elevations within a specific area. The formula is as follows:
[0098] ;
[0099] Among them, H maxH represents the altitude of the highest point. min This represents the altitude of the lowest point. In this embodiment, for example... Figure 4 As shown in (g), the terrain relief value is [0 m, 1307 m], where m is the unit of terrain relief: meters.
[0100] The formula for calculating the distance to the buffer boundary ratio PBBI is as follows:
[0101] ;
[0102] Where, d inner This represents the first distance from a buffer cell to the minimum inner boundary, where the inner boundary is a plurality of cells corresponding to the first threshold; d outer This represents the second distance from the buffer cell to the minimum outer boundary, where the outer boundary is a plurality of cells corresponding to the second threshold. In this embodiment, for example... Figure 4 As shown in (h), the distance ratio takes values of [0, 1265].
[0103] It should be noted that in this embodiment, Figure 4 (b) – Figure 4 In (h), different colors are used to represent different values of the corresponding remote sensing parameters.
[0104] In one optional implementation, the input feature data corresponds to all the pixels in the remote sensing image. The RGB values, slope index, aspect index, normalized difference vegetation index (NDVI), normalized difference water index (NDWI), and visible atmospheric drag index (VARI) of the pixels are combined into a parameter sequence, denoted as the first parameter sequence. For the pixels in the buffer zone, the terrain relief and the distance ratio are added to the parameter sequence, denoted as the second parameter sequence.
[0105] Preferably, in order to reduce the amount of data in the first model, since the present invention only classifies wetland landscapes, it is preferable that the input feature data corresponds to the pixels of the core area, the first parameter sequence is used for the pixels of the core area, and the second parameter sequence is used for the pixels of the buffer area.
[0106] In this embodiment, the structure diagram of the first model is as follows: Figure 5 As shown, it includes: a high-dimensional mapping network for feature upscaling; the pre-trained model with pre-trained and frozen parameters; a lightweight model obtained by knowledge distillation of the pre-trained model based on spectral and spatial features; a residual network for fusing the parameter sequence and the pixel final features; and the high-dimensional mapping network, the pre-trained model, and the lightweight model are connected in series.
[0107] The first model performs semantic segmentation, for example Figure 6As shown, the steps include:
[0108] Depth features are extracted from the multidimensional image using a pre-trained model, and the depth features are enhanced using a lightweight model to extract pixel ultimate features. The parameter sequence is fused with the pixel ultimate features through a residual network to obtain new pixel ultimate features. The new pixel ultimate features are used as input to the classifier to obtain the wetland category of the pixel.
[0109] In this embodiment, for example Figure 7 (a) shows a schematic diagram of the parameter sequence of a pixel. The method for converting the parameter sequence into a multidimensional image includes: using Matlab software to increase the dimensionality of the pixel parameter sequence through the Gramian Angular Field (GAF) method, outputting a Gramian Angular Field matrix of dimension H x W, and visualizing the Gramian Angular Field matrix using H, W, and GAF values as coordinate axes through Matlab. The result is as follows: Figure 7 As shown in (c). Since the GAF value range is [-1, 1], the GAF value multiplied by 2π can be used as the H channel in the HSV color space. Therefore, in this embodiment, the values in the obtained two-dimensional Grammy angle field matrix are converted into angles to obtain the first channel image. The parameter sequence of the paired pixels is increased in dimension using the Markov Transition Field (MTF) method in Matlab software, and a transition matrix with dimension H x W is output. The transition matrix is visualized in Matlab with H, W and MTF values as coordinate axes. The results are as follows: Figure 7 As shown in (d). Since the MTF value range is [0, 1], it can be used as the S channel in the HSV color space. Therefore, in this embodiment, the obtained transfer matrix is used as the second channel map. Using Matlab software, the parameter sequence of the paired pixels is increased in dimension by the Recurrence Plot (RP) method based on the similarity metric function, and a recurrence matrix of dimension H x W is output. The recurrence matrix is visualized by Matlab with H, W and RP values as coordinate axes. The result is as follows: Figure 7 As shown in (e). Since RP takes values in the range [0, 1], it can be used as the V channel in the HSV color space. Therefore, in this embodiment, the obtained recursive matrix is used as the third channel image. The HSV color space obtained by combining the first channel image, the second channel image, and the third channel image is converted into the RGB color space to obtain the multidimensional image input to the pre-trained model, for example... Figure 7As shown in (b), H and W are the height and width of the input multidimensional image. The parameter sequence of a pixel is a one-dimensional feature representation, which has a low degree of representation of pixel features, making it difficult for the model to capture this feature representation of the pixel. Therefore, the one-dimensional sequence is converted into a high-dimensional sequence so that the feature representation can include or highlight more features.
[0110] In other embodiments, the values of the first channel graph are transformed into the numerical range [0, 1], for example, by taking absolute values, and can be used as the S channel or V channel. The second channel graph can be directly used as the V channel; or the values of the second channel graph can be transformed into the numerical range [-1, 1], for example, by normalization, and can be used as the H channel. The values of the third channel graph are transformed into the numerical range [-1, 1], for example, by normalization, and can be used as the H channel; or the third channel graph can be directly used as the S channel.
[0111] The parameter sequence of a pixel represents a one-dimensional feature, which has a low degree of representation of pixel features, making it difficult for the model to capture this feature representation. By increasing the parameter sequence from one dimension to a higher dimension, the high-dimensional feature representation can include or highlight more features, thus helping to better capture various patterns and relationships in the image, improving the model's expressive power, and providing more accurate modeling results.
[0112] In this embodiment, before inputting the parameter sequence into the first model during training, the method further includes: classifying multiple parameter sequences based on spatial distance and / or feature similarity, wherein the method includes:
[0113] Traverse all the pixels corresponding to the parameter sequence to obtain the current pixel;
[0114] Wetland landscape classification has a certain area coverage, and its spatial distribution is usually in the form of patches, meaning that adjacent pixels may have the same category. Multiple pixels adjacent to the current pixel are obtained and denoted as adjacent pixels; these adjacent pixels are traversed, and each is combined with the current pixel to form a pair of pixels. The resulting pairs of pixels are then classified as spatially nearest positive class samples.
[0115] Based on the parameter sequence of the current pixel, the feature similarity is calculated with other pixels to obtain multiple pixels whose feature similarity is greater than a preset similarity threshold, and these are recorded as similar pixels; the similar pixels are traversed and combined with the current pixel to form a pair of pixels, and the multiple pairs of pixels are classified as feature neighbor positive samples;
[0116] Multiple pixels whose feature similarity is less than or equal to the similarity threshold are obtained and denoted as negative class pixels; the negative class pixels are traversed and combined with the current pixel to form a pair of pixels, and the multiple pairs of pixels are classified as negative class samples.
[0117] In one specific embodiment, the method for calculating feature similarity includes the K-nearest neighbor algorithm, which calculates the feature space distance between the current pixel and other pixels, such as Euclidean distance, and uses the reciprocal of the feature space distance as the feature similarity. The smaller the feature space distance, the higher the feature similarity.
[0118] In another embodiment, the method for calculating feature similarity includes using the parameter sequence as a vector to calculate cosine similarity, and using the cosine similarity as the feature similarity, wherein the greater the cosine similarity, the higher the feature similarity.
[0119] In this embodiment, training the first model includes:
[0120] The paired pixels are obtained from the spatially neighboring positive class samples, the feature-nearest positive class samples, and the negative class samples, respectively, and the first model receives the paired pixels as input. Preferably, to increase the generalization ability of the model, only one pair of the paired pixels is randomly selected from the feature-nearest positive class samples as input. The parameter sequences of the paired pixels are then converted into the multidimensional image.
[0121] Specifically, the pre-trained model extracts depth features from the multidimensional image, including: acquiring the multidimensional image corresponding to the paired pixels; using the pre-trained model to extract depth features from the multidimensional image; calculating category similarity for the depth features corresponding to the paired pixels to obtain a first decision feature, which is used to indicate whether the paired pixels belong to the same category.
[0122] Specifically, in a preferred embodiment, the formula for extracting deep features using a pre-trained model is as follows:
[0123] ;
[0124] in, This is a multidimensional image of paired pixels after feature upscaling, where O is the sample set consisting of spatially neighboring positive samples, feature-nearest positive samples, and negative samples; C = 3 is the number of RGB channels; and H and W are the height and width of the upscaled RGB image; M pt The model is a pre-trained model obtained by pre-training an existing model; l and m are the two output depth features corresponding to the paired pixels; vec() represents a function that flattens the matrix into a vector. For the paired pixels, the similarity between depth features l and m indicates whether they belong to the same category. The formula for calculating category similarity is as follows:
[0125] ;
[0126] The larger the first decision feature, the higher the probability that paired pixels belong to the same category. Preferably, the pre-trained model M... pt This refers to DINOv2 using the ViT-g / 14 parameter. The method for obtaining this model involves pre-training using a comparative approach, selecting the model based on the highest classification accuracy from existing models SimCLRv2, MoCov2, YOLOv5, YOLOv8, and DINOv2. It's important to note that the parameters of the pre-trained model are frozen during training.
[0127] Each pixel undergoing dimensionality upscaling enhances its ability to represent features; however, dimensionality upscaling still involves simple transformations and combinations of the original features, making it difficult to directly reflect deep features. After dimensionality upscaling, the pixel classification task transforms into the classification task of RGB images representing pixels. The pre-trained DINOv2 model already possesses general feature extraction capabilities. Using the DINOv2 model to extract deep features from multi-dimensional images reduces the dependence on large amounts of labeled data, which is beneficial for improving model stability and overfitting resistance, making it suitable for small-sample learning scenarios.
[0128] Specifically, the lightweight model enhances the depth features by: inputting the depth features corresponding to the paired pixels into the lightweight model and extracting the corresponding pixel final features. The structure of the lightweight model is as follows: Figure 8 As shown, a multilayer perceptron consists of multiple linear layers, with ReLU activation connections between them. Here, B represents the number of training batches. Let N represent the dimension of the depth features, N be the dimension of the linear layer, and Φ be the dimension of the final pixel features. The formula for extracting the final pixel features using the lightweight model is as follows:
[0129] ;
[0130] Where l and m are the deep features extracted by the pre-trained model; p and q are the pixel final features after enhancement by the lightweight model; M light The lightweight model calculates category similarity for the final features of each pixel to obtain a second decision feature, which is used to determine whether the paired pixels belong to the same category. The formula for calculating the second decision feature S is as follows:
[0131] ;
[0132] During training, a sample loss function for the lightweight model is constructed based on the first decision feature and the second decision feature. The more similar the first and second decision features are, the smaller the value of the sample loss function, indicating a higher consistency between the pre-trained model's extraction of deep features and the lightweight model's extraction of pixel-level final features. The formula for the sample loss function is as follows:
[0133] ;
[0134] Where F is the first decision feature; S is the second decision feature; and β is a preset hyperparameter used to determine whether the paired pixels belong to the positive or negative class. For input positive class samples, setting the hyperparameter β will make F-β positive, minimizing the loss function value will increase S, indicating that the final feature similarity between positive class samples is higher. For input negative class samples, setting the hyperparameter β will make F-β negative, minimizing the loss function value will decrease S, indicating that the final feature similarity between negative class samples is lower, ultimately achieving the clustering effect.
[0135] After extracting features from the paired pixels using the pre-trained model and the lightweight model, a sample loss function is constructed based on the feature similarity of the paired pixels. Based on the sample loss functions of the spatially neighboring positive class samples, the feature-nearest positive class samples, and the negative class samples, the three sample loss functions are weighted and summed to construct the model loss function L, as shown in the following formula:
[0136] ;
[0137] in, For the paired pixels, i = 1, 2, 3; when i = 1, The sample loss function is the spatially nearest positive class sample; when i=2, The sample loss function is the feature's nearest positive class sample; when i=3, The sample loss function for negative class samples; These are the weighting coefficients; These are hyperparameters. During training, minimizing the model loss function of the first model represents maximizing the similarity between positive class samples and minimizing the similarity between negative class samples. This balance is achieved by... and It changes with adjustments.
[0138] In this embodiment, the first model uses the Adam optimizer with a learning rate of 0.0001. The training batch size is set to 256, the validation batch size is set to 512, and the classifier is a Softmax linear classifier. During model validation, the linear probe uses a simple perceptron structure and employs the cross-entropy loss function to train the linear projection from the final features to the class labels. The optimization method also uses Adam with a learning rate of 0.001. All experiments are implemented using the PyTorch framework, with an NVIDIA GeForce RTX 3080 GPU and 10GB of processor cache. The training time is approximately 12 hours. The specific hyperparameter settings for the first model are shown in Table 3.
[0139] Table 3 Hyperparameter configuration of the first model
[0140] ;
[0141] Where K1 is the number of spatially neighboring positive class samples in this embodiment, K2 is the number of feature-near positive class samples, K3 is the number of negative class samples; and λ is the number of linear layers in the lightweight model.
[0142] During training, this invention selected seven deep learning models—KNN, SimCLRv2, MoCov2, Swin-Transformer, DINOv2, IIC, and ResNet50—and compared them with the first model in a comparative experiment. The F1 score, overall accuracy (OA), and Kappa coefficient values for the wetland category are shown in Table 4.
[0143] Table 4 Results of the Multi-Model Wetland Landscape Classification Experiment
[0144] ;
[0145] Comparative experiments show that the classification results of the first model are superior to those of other deep learning model algorithms, proving that the first model can be applied to wetland landscape mapping.
[0146] This invention focuses on the subdivision of the same land cover within the core area of wetlands. For example, rivers, lakes, and marshes can be roughly classified as water bodies. The emphasis is placed on the feature sequence carried by each pixel rather than the edge features reflecting the relationships between pixels. However, since the remote sensing images used in the long-term series studies of this invention are medium-resolution images, inaccurate edge mapping is prone to occur. The wetland mapping method provided by this invention, based on remote sensing image pixels, enhances the parameter sequence of pixels from one dimension to a higher dimension. This sequence is then input into a pre-trained self-supervised learning model to extract depth features from the pixels. A lightweight model distilled from the pre-trained model is used to enhance these depth features, reducing the input data required for semantic segmentation. By fusing the initial pixel parameter sequence with the enhanced features through a residual network, the technical effect of accurately classifying wetland landscapes with fewer samples is achieved. This facilitates better capture of various patterns and relationships in the image, improves the model's expressive power, and provides more accurate modeling results.
[0147] It will be understood by those skilled in the art that all or some of the steps and systems in the methods disclosed above can be implemented as software, firmware, hardware, and suitable combinations thereof. Some or all of the physical components can be implemented as software executed by a processor, such as a central processing unit, digital signal processor, or microprocessor, or as hardware, or as an integrated circuit, such as an application-specific integrated circuit. Such software can be distributed on a computer-readable medium, which can include computer storage media (or non-transitory media) and communication media (or transient media). As is known to those skilled in the art, the term computer storage media includes volatile and non-volatile, removable and non-removable media implemented in any method or technology for storing information (such as computer-readable instructions, data structures, program modules, or other data). Computer storage media includes, but is not limited to, RAM, ROM, EEPROM, flash memory or other memory technologies, CD-ROM, digital versatile disc (DVD) or other optical disc storage, magnetic cartridges, magnetic tape, disk storage or other magnetic storage devices, or any other medium that can be used to store desired information and is accessible to a computer. Furthermore, as is known to those skilled in the art, communication media typically contain computer-readable instructions, data structures, program modules, or other data in modulated data signals such as carrier waves or other transmission mechanisms, and may include any information delivery medium.
[0148] The above embodiments are only used to illustrate the present invention and are not intended to limit the technical solutions described herein. Although the present invention has been described in detail with reference to the above embodiments, the present invention is not limited to the specific embodiments described above. Therefore, any modifications or equivalent substitutions to the present invention, as well as all technical solutions and improvements that do not depart from the spirit and scope of the invention, are covered within the scope of the claims of the present invention.
Claims
1. A wetland mapping method based on a pre-trained model and a feature distillation model, characterized in that, include: Acquire remote sensing images with multiple different remote sensing parameters, and obtain pixels from the remote sensing images; combine the different remote sensing parameters of the pixels at corresponding locations to obtain a parameter sequence; input the parameter sequence into a first model; The parameter sequence is converted into a multidimensional image using the first model. The multidimensional image is semantically segmented using a pre-trained model and a lightweight model to obtain the pixel final features. The pixel final features are then classified using a classifier to obtain the wetland category of the pixel. The lightweight model is obtained by knowledge distillation of the pre-trained model based on spectral and spatial features; The semantic segmentation includes: extracting depth features from the multidimensional image using a pre-trained model, enhancing the depth features using a lightweight model, and extracting pixel ultimate features; fusing the parameter sequence with the pixel ultimate features through a residual network to obtain new pixel ultimate features, and using the new pixel ultimate features as input to the classifier; Import the wetland category and the corresponding pixel location into the geographic information system to create a wetland type map.
2. The method as described in claim 1, characterized in that, After acquiring remote sensing images with multiple different remote sensing parameters, the method further includes: classifying the remote sensing images into regions based on the topographic relief in the remote sensing parameters, including: At least one first threshold and at least one second threshold are preset, wherein the first threshold is less than the second threshold; the pixels whose topographic relief is less than the first threshold are denoted as the core area representing the wetland; The pixels whose terrain undulation is greater than or equal to the first threshold and less than the second threshold are denoted as buffer zones representing alternating wetlands and mountains; the pixels of the core area are used as input to the first model.
3. The method as described in claim 2, characterized in that, The combination of different remote sensing parameters of the corresponding pixel includes: The remote sensing images of different spectral bands are combined into a true-color image to represent spectral features, and the RGB values of the remote sensing images are obtained. For all the aforementioned pixels, the RGB values, slope index, aspect index, normalized vegetation index, normalized water index, and visible atmospheric drag index are combined into the parameter sequence. For each cell in the buffer, calculate the first distance from the cell to the inner boundary, where the inner boundary is the cell corresponding to the first threshold; calculate the second distance from the cell to the outer boundary, where the outer boundary is the cell corresponding to the second threshold; calculate the ratio of the first distance to the second distance to obtain the distance ratio; add the terrain undulation and the distance ratio to the parameter sequence.
4. The method as described in claim 1, characterized in that, The step of converting the parameter sequence into a multidimensional image includes: The parameter sequence is subjected to Grammy angle field transformation, and the values in the resulting two-dimensional Grammy angle field matrix are converted into angles to obtain the first channel image; The parameter sequence is subjected to Markov transition field transformation, and the resulting transition matrix is used as the second channel diagram. The parameter sequence is transformed into a recursive graph, and the resulting recursive matrix is used as the third channel graph. The first channel image, the second channel image, and the third channel image are combined into an HSV color space, and then converted into an RGB color space to obtain the multidimensional image.
5. The method as described in claim 1, characterized in that, After acquiring remote sensing images with multiple different remote sensing parameters, the method further includes: performing standardization on the remote sensing images based on the remote sensing parameters, including: From the remote sensing images acquired by different sensors, the remote sensing images with the same spectral band are selected to obtain multispectral remote sensing images; If the multispectral remote sensing image has a panchromatic spectral band, the panchromatic spectral remote sensing image and the multispectral remote sensing image are fused to improve the resolution; if the multispectral remote sensing image does not have a panchromatic spectral band, the resolution of the multispectral remote sensing image is improved by k-nearest neighbor interpolation. The radiometric resolution of the multispectral remote sensing image is adjusted to a preset quantization bit depth.
6. The method according to any one of claims 1-5, characterized in that, Before inputting the parameter sequence into the first model during training, the method further includes: classifying multiple parameter sequences based on spatial distance and / or feature similarity, wherein the method includes: Traverse all the pixels corresponding to the parameter sequence to obtain the current pixel; Obtain multiple pixels adjacent to the current pixel, combine them with the current pixel respectively, and classify the resulting multiple pairs of pixels as spatially nearest positive samples; Based on the parameter sequence of the current pixel, the feature similarity is calculated with other pixels to obtain multiple pixels whose feature similarity is greater than a preset similarity threshold. These pixels are then combined with the current pixel to classify the resulting multiple pairs of pixels as feature-nearest positive samples. Multiple pixels whose feature similarity is less than or equal to the similarity threshold are obtained, and each pixel is combined with the current pixel to classify the resulting multiple paired pixels as negative samples.
7. The method as described in claim 6, characterized in that, Training the first model includes: The first model obtains paired pixels from the spatially neighboring positive class samples, the feature-nearest positive class samples, and the negative class samples, respectively. The first model receives the paired pixels as input, converts the parameter sequences of the paired pixels into the multidimensional image, extracts features from the paired pixels through the pre-trained model and the lightweight model, and constructs a sample loss function based on the feature similarity of the paired pixels. The sample loss functions of different sample categories are summed to obtain the loss function of the first model.
8. The method as described in claim 7, characterized in that, The method for constructing the sample loss function includes: The pre-trained model is used to extract depth features from the paired pixels, and the class similarity between the depth features is calculated to obtain the first decision feature. The deep features are enhanced by the lightweight model, the final features of the paired pixels are extracted, the class similarity between the final features of the pixels is calculated, and the second decision feature is obtained. The sample loss function of the lightweight model is constructed based on the first decision feature and the second decision feature, such that the more similar the first decision feature and the second decision feature are, the smaller the value of the sample loss function.
9. A wetland mapping system based on a pre-trained model and a feature distillation model, characterized in that, include: The preprocessing module is used to acquire multiple remote sensing images with different remote sensing parameters, obtain pixels from the remote sensing images, combine different remote sensing parameters of the pixels at corresponding locations to obtain a parameter sequence, and input the parameter sequence into the first model. The semantic segmentation module is used to convert the parameter sequence into a multi-dimensional image through the first model, perform semantic segmentation on the multi-dimensional image through a pre-trained model and a lightweight model to obtain the pixel final features, and classify the pixel final features through a classifier to obtain the wetland category of the pixel. The lightweight model is obtained by knowledge distillation of the pre-trained model based on spectral and spatial features; The semantic segmentation includes: extracting depth features from the multidimensional image using a pre-trained model, enhancing the depth features using a lightweight model, and extracting pixel ultimate features; fusing the parameter sequence with the pixel ultimate features through a residual network to obtain new pixel ultimate features, and using the new pixel ultimate features as input to the classifier; The mapping module imports the wetland category and the corresponding pixel location into the geographic information system to create a wetland type map.
Citation Information
Patent Citations
Full-modal and missing-modal land coverage classification method based on multi-modal online distillation framework
CN118196649A
Remote sensing image multi-class ground feature recognition method based on self-supervised learning
CN119810672A