High-resolution remote sensing image small building extraction method and system fusing local feature perception and boundary constraint
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-23
- Publication Date
- 2026-08-11
AI Technical Summary
[0006]为此,本发明提供一种融合局部特征感知和边界约束的高分辨率遥感影像小建筑物提取方法及系统,解决现有模型对于小型建筑物特征提取能力和形状模式的学习能力的不足,改善复杂场景下小型建筑物的提取效果
Smart Images

Figure CN118823581B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of remote sensing data processing technology, and in particular to a method and system for extracting small buildings from high-resolution remote sensing images by integrating local feature perception and boundary constraints. Background Technology
[0002] Building extraction is one of the most important and widely studied applications in intelligent interpretation of remote sensing imagery. Accurate and timely spatial distribution data of buildings is crucial for accelerating modernization, detecting illegal structures, and promoting sustainable development. In recent years, with the rapid development of remote sensing technology, the ability to acquire observational data across multiple time phases, resolutions, and platforms has been greatly enhanced, providing an important data source for obtaining building information. Among these, ultra-high spatial resolution (VHR) remote sensing imagery (GSD ≤ 1m) provides rich spatial details, revealing a more refined spatial distribution of buildings. However, due to the spectral limitations and variability of VHR imagery, accurately extracting buildings from it remains extremely challenging.
[0003] Existing methods for building extraction from VHR remote sensing imagery can be broadly categorized into two types: traditional methods and deep learning-based methods. Traditional methods typically require manual feature selection and computation, such as spectral, textural, and geometric features based on remote sensing images, followed by classifier segmentation to separate building and non-building regions. However, traditional methods are overly sensitive to high-frequency image signals (such as edges and textures), leading to severe "salt-and-pepper noise" when extracting buildings from VHR images. To improve the accuracy of building extraction from VHR images using traditional methods, object-oriented building extraction methods have been proposed. Using image segmentation objects as the basic analytical unit for building recognition allows for full utilization of the object's contextual information, highlighting the textural and spatial features of the VHR imagery. However, object-oriented methods rely heavily on image segmentation performance, especially in complex environments where segmented objects struggle to accurately depict the geometric contours of objects. Furthermore, these methods cannot automatically extract high-level semantic features, limiting building extraction performance.
[0004] With the rapid development of deep learning technology, especially after the introduction and successful application of fully convolutional neural networks (FCNs) for building extraction, research on deep learning-based building extraction has become a hot topic. FCNs perform pixel-level classification of images, thus solving the semantic-level image segmentation problem. A fully convolutional neural network mainly consists of an encoder, a decoder, and a classification head. The encoder continuously performs convolution and pooling operations on the input image to extract high-level semantic features, while the decoder gradually recovers the spatial dimensions of the original image through a deconvolution module. Finally, the classification head obtains the building extraction results. Subsequently, improved versions of convolutional neural networks such as UNet, Deeplabv3, DenseNet, SegNet, and HRNet have emerged based on deep learning methods. The recently proposed Transformer has also been successfully applied to building extraction and has been shown to have superior global feature extraction capabilities compared to convolutional neural networks. Compared with traditional methods, the aforementioned deep learning-based building extraction methods have stronger learning and generalization abilities.
[0005] Currently, a major challenge in building extraction from VHR remote sensing imagery remains: the low consistency between extracted building boundaries and actual building boundaries due to occlusion and boundary blurring. Recent studies have proposed solutions from different perspectives. For example, Zhou et al. used a graph reasoning module to address intra-class discontinuities and then embedded directional information for building boundary correction. This method can achieve fine-grained building segmentation, but it is limited by severe occlusion from shadows and trees. Ding et al. designed a building shape optimizer based on generative adversarial networks to enhance the learning of building shape information. Dong et al. combined region line feature fusion with an object-based convolutional neural network to improve the consistency between extracted building boundaries and real boundaries. These methods have improved the geometric accuracy of extraction results to some extent when detecting regular large buildings in cities, but they remain insufficient for shape constraints on small-scale buildings. Currently, deep learning-based VHR image building extraction methods suffer from the following drawbacks: 1. There is a lack of research on the extraction of small buildings in complex scenes, resulting in serious missed detections in the extraction results of small, densely packed buildings in complex rural and suburban scenes; 2. The extracted building boundaries have a low degree of agreement with the actual building boundaries, especially for small buildings where shape constraints are still insufficient, leading to reduced geometric accuracy; 3. Supervised deep learning-based building extraction algorithms require a large number of labeled samples for training. Due to the specificity of each building instance and the complexity and variability of its surrounding environment, the performance of building extraction models largely depends on the quality and richness of the samples. However, manually labeling a large number of samples is time-consuming and labor-intensive, which is a major factor limiting the practical application of supervised deep learning-based building extraction algorithms. Summary of the Invention
[0006] To address this, the present invention provides a method and system for extracting small buildings from high-resolution remote sensing images by integrating local feature perception and boundary constraints. This addresses the shortcomings of existing models in terms of feature extraction and shape pattern learning capabilities for small buildings, and improves the extraction effect of small buildings in complex scenes.
[0007] According to the design scheme provided by the present invention, on the one hand, a method for extracting small buildings from high-resolution remote sensing images by integrating local feature perception and boundary constraints is provided, comprising:
[0008] Obtain a first sample dataset and a second sample dataset from the remote sensing image sample data. The first sample dataset is remote sensing image data with building labels, and the second sample dataset is remote sensing image data without building labels.
[0009] A building recognition model is constructed, and the building recognition model is trained using a first sample dataset and a second sample dataset to obtain a trained building target model. The building recognition model includes a dual heterogeneous feature encoder consisting of a main encoder and an auxiliary encoder, a decoder, a region classification head and a boundary classification head, and the region classification head and the boundary classification head share the encoder and decoder. The main encoder and the auxiliary encoder adopt different types of backbone networks.
[0010] The remote sensing image to be detected is input into the building target model, and the buildings in the remote sensing image to be detected are extracted using the building target model;
[0011] In the training of the building recognition model, firstly, the building recognition model is trained for the first time using the first sample dataset. Then, the second sample dataset is input into the building recognition model after the first training to obtain the instance pseudo-labels in the second sample dataset. The instance pseudo-labels and the corresponding second sample dataset and first sample dataset are combined as the input data for the model to be trained again. The building recognition model is trained again using this input data to obtain the building target model.
[0012] As a method for extracting small buildings from high-resolution remote sensing images that integrates local feature perception and boundary constraints, the auxiliary encoder is a four-stage encoder constructed by UNet. Each stage of the encoder contains two convolutional layers and one max pooling layer. The four stages of the encoder are used to continuously perform convolution and max pooling operations on the input image to obtain semantic features at four levels.
[0013] As a method for extracting small buildings from high-resolution remote sensing images that integrates local feature perception and boundary constraints according to the present invention, the main encoder further includes a segmentation embedding unit and four BiFormer units. In each BiFormer unit, the relative position is first implicitly encoded using convolution, and the cross position relationship and embedding position are simulated using a two-layer routing attention mechanism and a two-layer perception mechanism.
[0014] As a method for extracting small buildings from high-resolution remote sensing images that integrates local feature perception and boundary constraints according to the present invention, the region classification head and the boundary classification head are both composed of a convolutional kernel and a sigmoid activation function.
[0015] As a method for extracting small buildings from high-resolution remote sensing images that integrates local feature perception and boundary constraints according to the present invention, the building recognition model training process further includes:
[0016] A building boundary optimizer is constructed, and an adversarial learning process is formed between the building boundary optimizer and the building boundary extraction branch composed of boundary classification heads. In the model training, the building boundary optimizer guides the building boundary extraction branch to generate building boundaries similar to the real boundaries.
[0017] As a method for extracting small buildings from high-resolution remote sensing images that integrates local feature perception and boundary constraints according to the present invention, the training loss function of the building recognition model is further expressed as: ,in, , , These are the building area loss, building boundary loss, and boundary optimizer loss, respectively.
[0018] As a method for extracting small buildings from high-resolution remote sensing images that integrates local feature perception and boundary constraints, this invention further combines instance pseudo-labels with the corresponding second sample dataset and the first sample dataset, including:
[0019] The information entropy of each pixel in the instance pseudo-label is calculated based on the instance pseudo-label probability value at each pixel in the second sample dataset image generated by the region classification head;
[0020] Reliable pseudo-labels are filtered using a preset threshold and based on the information entropy of each pixel. The spatial range of each building instance and the percentage of building pixels in the instance pseudo-label are obtained based on the connected components of the real label and the reliable pseudo-label.
[0021] The pseudo-labels of the instances are filtered based on the proportion of building pixels in the image, and the labeled building instances are randomly transferred to the pseudo-label instances based on the spatial range of the building instances.
[0022] Furthermore, this invention also provides a high-resolution remote sensing image small building extraction system that integrates local feature perception and boundary constraints, comprising: a sample acquisition module, a model training module, and a target recognition module, wherein...
[0023] The sample acquisition module is used to acquire a first sample dataset and a second sample dataset from the remote sensing image sample data. The first sample dataset is remote sensing image data with building labels, and the second sample dataset is remote sensing image data without building labels.
[0024] The model training module is used to construct a building recognition model and train the building recognition model using a first sample dataset and a second sample dataset to obtain a trained building target model. The building recognition model includes a dual heterogeneous feature encoder consisting of a main encoder and an auxiliary encoder, a decoder, a region classification head and a boundary classification head, and the region classification head and the boundary classification head share the encoder and decoder. The main encoder and the auxiliary encoder adopt different types of backbone networks.
[0025] The target recognition module is used to input the remote sensing image to be detected into the building target model, and to extract the buildings in the remote sensing image to be detected using the building target model;
[0026] The building recognition model training process in the model training module includes: first, using the first sample dataset to train the building recognition model for the first time; then, inputting the second sample dataset into the initially trained building recognition model to obtain instance pseudo-labels in the second sample dataset; combining the instance pseudo-labels with the corresponding second sample dataset and the first sample dataset as input data for retraining the model; and using this input data to retrain the building recognition model to obtain the building target model.
[0027] The beneficial effects of this invention are:
[0028] This invention combines mainstream convolutional neural networks and Transformer backbone networks to construct a high-efficiency feature encoder. Based on multi-task learning and adversarial learning, it enhances the ability to perceive building shape patterns, effectively reducing the missed detection of small buildings and improving the geometric accuracy of building extraction results. Specifically, the dual heterogeneous feature encoder couples existing mainstream backbone networks. Based on pre-trained weights, it fine-tunes the model using a small number of target domain samples to achieve excellent building extraction performance. This significantly improves model training efficiency and reduces the model's dependence on the quality and quantity of the target domain dataset. Furthermore, the dual heterogeneous feature encoder employs a fully connected feature fusion approach, which fully utilizes the rich and detailed texture and geometric features in VHR remote sensing imagery while also considering the representational power of global semantic features, effectively improving the extraction accuracy of small buildings. By embedding a building edge detection auxiliary branch and an adversarial learning-based boundary optimizer, the model's ability to perceive the shape patterns of small buildings is enhanced. Compared to existing methods, the edge detection branch and the building extraction branch share the encoder and decoder, which reduces the number of training parameters and computational cost during training. The boundary optimizer based on adversarial learning, considering the special characteristics of small buildings, adopts a shallow convolutional network architecture to prevent feature loss of small buildings and adds an attention module to suppress irrelevant information, making it more effective for learning the shape patterns of small buildings. To reduce the dataset construction cost of supervised deep learning methods, a pseudo-sample generation strategy based on a self-training paradigm and random transfer of building instances is proposed. Reliable pseudo-labels are selected by calculating the pseudo-label information entropy, avoiding gradient vanishing or exploding phenomena during model training due to low-quality pseudo-labels. Furthermore, by transferring building instances with real labels to two pseudo-labels with a lower proportion of buildings, the ratio of positive to negative samples is balanced, enriching the sample background. This approach shows good application prospects in the field of remote sensing data processing technology. Attached Figure Description
[0029] Figure 1 This is a schematic diagram of the process for extracting small buildings from high-resolution remote sensing images that integrates local feature perception and boundary constraints in the embodiment.
[0030] Figure 2 This is a schematic diagram of the building recognition model training process in the embodiment;
[0031] Figure 3 This is a schematic diagram of the dual heterogeneous encoder structure in the embodiment;
[0032] Figure 4 This is a schematic diagram of the building boundary optimizer structure in the embodiment;
[0033] Figure 5 This is a schematic diagram illustrating the working principle of the pseudo-sample generation strategy based on self-training and random transfer of building instances in the embodiment. Detailed Implementation
[0034] To make the objectives, technical solutions, and advantages of this invention clearer and more understandable, the invention will be further described in detail below with reference to the accompanying drawings and technical solutions.
[0035] According to the embodiments of the present invention, see Figure 1 As shown, a method for extracting small buildings from high-resolution remote sensing images by fusing local feature perception and boundary constraints is provided for the compilation optimization of target program code, including:
[0036] S101. Obtain the first sample dataset and the second sample dataset from the remote sensing image sample data. The first sample dataset is remote sensing image data with building labels, and the second sample dataset is remote sensing image data without building labels.
[0037] S102. Construct a building recognition model and train the building recognition model using the first sample dataset and the second sample dataset to obtain a trained building target model. The building recognition model includes a dual heterogeneous feature encoder consisting of a main encoder and an auxiliary encoder, a decoder, a region classification head and a boundary classification head, and the region classification head and the boundary classification head share the encoder and decoder. The main encoder and the auxiliary encoder adopt different types of backbone networks.
[0038] S103. Input the remote sensing image to be detected into the building target model, and use the building target model to extract the buildings in the remote sensing image to be detected;
[0039] In the training of the building recognition model, firstly, the building recognition model is trained for the first time using the first sample dataset. Then, the second sample dataset is input into the building recognition model after the first training to obtain the instance pseudo-labels in the second sample dataset. The instance pseudo-labels and the corresponding second sample dataset and first sample dataset are combined as the input data for the model to be trained again. The building recognition model is trained again using this input data to obtain the building target model.
[0040] See Figure 2As shown, the building recognition model mainly consists of four parts. (1) Dual heterogeneous feature extractor: Combining mainstream convolutional neural networks (CNN) and Transformer, it effectively aggregates spatial details and global semantic features at different scales, gradually expanding the receptive field of the model, thereby improving the accuracy of small building extraction. (2) Building edge detection branch: Introducing a building edge detection (BED) auxiliary branch to enhance the model's ability to perceive building boundaries. (3) Building boundary optimizer: Constructing a building boundary optimizer based on adversarial learning mechanism. It, together with the building region extraction and edge detection branches, constitutes an adversarial learning system, gradually guiding the semantic segmentation network to generate building boundaries that are similar to the real boundaries. (4) Pseudo-sample generation strategy: Generating credible pseudo-samples based on the self-training paradigm and the random transfer strategy of building instances, reducing the cost of constructing the training dataset.
[0041] like Figure 3 As shown, a dual heterogeneous feature extractor is provided to effectively extract semantic features of small buildings, ensuring that the model can capture more building information, thereby improving the extraction effect of small buildings. In the dual heterogeneous feature extractor, firstly, mainstream deep learning backbone networks are selected to construct the dual heterogeneous feature extractor. The dual heterogeneous feature extractor considers the advantages of different types of backbone networks and consists of two encoders: a Transformer-based main encoder and a CNN-based auxiliary encoder. Secondly, UNet, commonly used in segmentation tasks, is selected to construct the auxiliary encoder to enhance the local feature extraction capability of the image and avoid missing small buildings. The aim is to utilize the auxiliary encoder to enhance local feature representation; therefore, only stages 1 to 4 of UNet are used. The auxiliary encoder consists of four stages, each containing two... Convolutional layer and one The maximum pooling layer. Its effect on the input image. ( and (These refer to the height, width, and number of channels of I, respectively.) Semantic features were obtained by continuously performing convolution and max pooling operations, resulting in four levels of semantic features. Then, the main encoder is built using BiFormer, combined with... Multi-level rich local features acquired by the auxiliary encoder It models global features with high-level contextual semantic information. The main encoder contains a Patch Embedding and four BiFormer modules. In each BiFormer, it first uses... The convolutions implicitly encode relative positions. Subsequently, a two-layer routed attention (BRA) module and a spread ratio of [missing information] are used sequentially. A two-layer MLP module is used to simulate the intersection relationship and embed each position separately. Assume... This indicates that ME has obtained the first Layer features, The subscript indicates the upsampling operation, and its subscript indicates the sampling scale. Equation (1) shows the fully connected feature fusion operation between two heterogeneous encoders. For example, an image and characteristics at all levels After fusion, it is fed into the first stage of the main encoder; and After merging, it is input into the second stage of the main encoder.
[0042] (1)
[0043] To automate the integration of building boundary information and thus constrain the Building Region Extraction (BRE) results, a BED branch is added. The BED and BRE branches share the encoder and decoder; the difference between these two tasks lies in the two shallow classification heads at the end: the Region Classification Head (RCH) and the Boundary Classification Head (ECH). In this embodiment, the constructed multi-task architecture enhances the correlation between tasks, reduces the number of parameters to be trained on the model, thereby improving the accuracy and efficiency of building extraction. The specific process can be summarized as follows:
[0044] Decoder: The decoder upsamples the multi-scale features extracted by the encoder, progressively restoring the feature dimensions to the size space of the original input image. The decoder contains four upsampling modules, each consisting of a... The module consists of a convolutional layer and an upsampling layer. To further reduce the loss of spatial detail and improve the recognition ability of small target buildings, two strategies are adopted: 1) using a multi-scale feature "skip-layer connection" strategy; 2) fusing the first-stage features of the auxiliary encoder in the last upsampling module. .
[0045] Region classification head and boundary classification head: Both have the same structure but do not share weights. Each classification head consists of a... Convolution and a sigmoid activation function Composition. Obtained by the decoder. Input the region classification header and boundary classification header respectively to obtain the building region. The calculation process is shown in Formula 2:
[0046]
[0047] (2)
[0048] The combination of instance pseudo-labels and the corresponding second and first sample datasets can be designed to include:
[0049] The information entropy of each pixel in the instance pseudo-label is calculated based on the instance pseudo-label probability value at each pixel in the second sample dataset image generated by the region classification head;
[0050] Reliable pseudo-labels are filtered using a preset threshold and based on the information entropy of each pixel. The spatial range of each building instance and the percentage of building pixels in the instance pseudo-label are obtained based on the connected components of the real label and the reliable pseudo-label.
[0051] The pseudo-labels of the instances are filtered based on the percentage of building pixels, and the labeled building instances are randomly transferred to the pseudo-label instances based on the spatial range of the building instances.
[0052] During training, the building boundary optimizer and the building boundary extraction branch form an adversarial learning system. The building boundary optimizer gradually guides the building boundary extraction branch to generate building boundaries that resemble the real boundaries. Considering that excessive downsampling operations can lead to the loss of features for small targets, a boundary optimizer with a shallow convolutional network structure is designed to improve the perception of small building shapes. It includes three downsampling modules, one convolutional block attention module, and one... The convolutional layer. The building boundary optimizer structure is as follows: Figure 4 As shown, the specific process is as follows:
[0053] (1) Use downsampling to soften building boundary labels This makes the boundary optimizer easier to fit;
[0054] (2) Extract using the downsampling module in the boundary optimizer Or predicted building boundaries Advanced features. The input is fed into three downsampling modules, and the output features are obtained after each downsampling. The number of channels increased to 32, 64 and 128 respectively, while the feature resolution decreased to H / 4, H / 8 and H / 16 respectively;
[0055] (3) A convolutional block attention module is integrated into the boundary optimizer, making the boundary optimizer pay more attention to the key positions of the input features;
[0056] (4) Perform a 1×1 convolution operation on the features reshaped by the attention module.
[0057] In this embodiment, a pseudo-sample generation strategy is used to augment building samples, thereby reducing the cost of building dataset construction and improving the generalization ability of the building extraction method when there are few samples. The specific process of the pseudo-sample generation strategy is as follows: Figure 5 As shown, the specific technical solution can be summarized as follows:
[0058] (1) First, a building extraction model is trained using a small number of building samples, and the best model weights obtained from the training are used to extract buildings from the unlabeled image as initial pseudo-labels.
[0059] (2) Reliable pseudo-labels are filtered by calculating the information entropy of each pixel in the initial pseudo-labels to avoid obtaining poor-quality pseudo-labels. This represents the first region classification head generated. Pixels in an unlabeled image The sigmoid probability value at point, where It can be 0 (non-building) or 1 (building). Its entropy is calculated using the following formula:
[0060] (3)
[0061] It is the first Dimensional The entropy value, based on this, we will consider the entropy value exceeding the threshold. The pixels in this category are classified as unreliable pseudo-labels. Therefore, we... pixel number The pseudo-label of an unlabeled image is defined as:
[0062] (4)
[0063] in, This represents the entropy threshold, which is set to 0.1. It is the entropy function for each pixel.
[0064] (3) Perform connected component analysis on real labels and high-quality pseudo labels to obtain the spatial extent of each building instance. At the same time, the percentage of pixels belonging to buildings in the pseudo labels can also be obtained.
[0065] (4) Based on the results of (3) above, pseudo-labels were selected where the building area was less than 20%. For these pseudo-labels, labeled building instances were randomly copied and pasted into the pseudo-labels. During the transfer process, the transferred building instances could avoid overlapping or covering with building instances in the pseudo-labels based on the obtained building space range. In this way, the ratio of positive and negative samples was effectively balanced, and the background diversity of the pseudo-samples was also enhanced. Finally, we combined the pseudo-samples and labeled samples to retrain the building extraction model.
[0066] Based on the model structure described above, three loss functions can be used to supervise the training of this method, namely, building area loss. Building boundary loss and boundary optimizer loss .make and These indicate that the building area and boundary classifications are incorrect. Representing pixels in image space The position in the middle. They represent and The predicted probability. Calculated using NLL loss. and :
[0067]
[0068] (5)
[0069] The boundary optimizer is trained adversarially using the BCE loss function:
[0070] (6)
[0071]
[0072] in, This represents the expected value of different types of input samples. It is a boundary optimizer. It is an edge detector. and These are the ground truth boundary and the prediction boundary, respectively. It is the encoded signal of the input data, which is either "1" (GT) or "0" (prediction boundary). This is the optimizer output, indicating that the input data is... The probability of.
[0073] Finally, the joint loss function is defined as follows:
[0074] (7)
[0075] Furthermore, based on the above method, this embodiment of the invention also provides a high-resolution remote sensing image small building extraction system that integrates local feature perception and boundary constraints, comprising: a sample acquisition module, a model training module, and a target recognition module, wherein,
[0076] The sample acquisition module is used to acquire a first sample dataset and a second sample dataset from the remote sensing image sample data. The first sample dataset is remote sensing image data with building labels, and the second sample dataset is remote sensing image data without building labels.
[0077] The model training module is used to construct a building recognition model and train the building recognition model using a first sample dataset and a second sample dataset to obtain a trained building target model. The building recognition model includes a dual heterogeneous feature encoder consisting of a main encoder and an auxiliary encoder, a decoder, a region classification head and a boundary classification head, and the region classification head and the boundary classification head share the encoder and decoder. The main encoder and the auxiliary encoder adopt different types of backbone networks.
[0078] The target recognition module is used to input the remote sensing image to be detected into the building target model, and to extract the buildings in the remote sensing image to be detected using the building target model;
[0079] The building recognition model training process in the model training module includes: first, using the first sample dataset to train the building recognition model for the first time; then, inputting the second sample dataset into the initially trained building recognition model to obtain instance pseudo-labels in the second sample dataset; combining the instance pseudo-labels with the corresponding second sample dataset and the first sample dataset as input data for retraining the model; and using this input data to retrain the building recognition model to obtain the building target model.
[0080] Unless otherwise specifically stated, the relative steps, numerical expressions, and values of the components and steps described in these embodiments do not limit the scope of the invention.
[0081] The various embodiments in this specification are described in a progressive manner, with each embodiment focusing on its differences from other embodiments. Similar or identical parts between embodiments can be referred to interchangeably. For the systems disclosed in the embodiments, since they correspond to the methods disclosed in the embodiments, the descriptions are relatively simple; relevant parts can be referred to the method section.
[0082] The units and method steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of both. To clearly illustrate the interchangeability of hardware and software, the components and steps of each example have been generally described in terms of functionality in the foregoing description. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementations are not considered to be beyond the scope of this invention.
[0083] Those skilled in the art will understand that all or part of the steps in the above methods can be implemented by a program instructing related hardware, and the program can be stored in a computer-readable storage medium, such as a read-only memory, a disk, or an optical disk. Optionally, all or part of the steps in the above embodiments can also be implemented using one or more integrated circuits. Accordingly, each module / unit in the above embodiments can be implemented in hardware or as a software functional module. This invention is not limited to any particular combination of hardware and software.
[0084] Finally, it should be noted that the above-described embodiments are merely specific implementations of the present invention, used to illustrate the technical solutions of the present invention, and not to limit it. The scope of protection of the present invention is not limited thereto. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that any person skilled in the art can still modify or easily conceive of changes to the technical solutions described in the foregoing embodiments within the technical scope disclosed in the present invention, or make equivalent substitutions for some of the technical features; and these modifications, changes, or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention, and should all be covered within the scope of protection of the present invention. Therefore, the scope of protection of the present invention should be determined by the scope of the claims.
Claims
1. A method for extracting small buildings from high-resolution remote sensing images by integrating local feature perception and boundary constraints, characterized in that, Include: Obtain a first sample dataset and a second sample dataset from the remote sensing image sample data. The first sample dataset is remote sensing image data with building labels, and the second sample dataset is remote sensing image data without building labels. A building recognition model is constructed, and the building recognition model is trained using a first sample dataset and a second sample dataset to obtain a trained building target model. The building recognition model includes a dual heterogeneous feature encoder consisting of a main encoder and an auxiliary encoder, a decoder, a region classification head and a boundary classification head, and the region classification head and the boundary classification head share the encoder and decoder. The main encoder and the auxiliary encoder adopt different types of backbone networks. The remote sensing image to be detected is input into the building target model, and the buildings in the remote sensing image to be detected are extracted using the building target model; In the training of the building recognition model, firstly, the building recognition model is trained for the first time using the first sample dataset. Then, the second sample dataset is input into the building recognition model after the first training to obtain the instance pseudo-labels in the second sample dataset. The instance pseudo-labels and the corresponding second and first sample datasets are combined as input data for retraining the model. The building recognition model is then retrained using this input data to obtain the building target model.
2. The method for extracting small buildings from high-resolution remote sensing images by fusing local feature perception and boundary constraints according to claim 1, characterized in that, The auxiliary encoder is a four-stage encoder built by UNet. Each stage of the encoder contains two convolutional layers and one max pooling layer. The four stages of the encoder are used to continuously perform convolution and max pooling operations on the input image to obtain semantic features at four levels.
3. The method for extracting small buildings from high-resolution remote sensing images by fusing local feature perception and boundary constraints according to claim 1, characterized in that, The main encoder includes a segmentation embedding unit and four BiFormer units. In each BiFormer unit, the relative positions are first implicitly encoded using convolution, and then the cross-positional relationships and embedding positions are simulated using a two-layer routing attention mechanism and a two-layer perception mechanism.
4. The method for extracting small buildings from high-resolution remote sensing images by fusing local feature perception and boundary constraints according to claim 1, characterized in that, Both the region classification head and the boundary classification head consist of a convolutional kernel and a sigmoid activation function.
5. The method for extracting small buildings from high-resolution remote sensing images by fusing local feature perception and boundary constraints according to claim 1, characterized in that, The training process for the building recognition model also includes: A building boundary optimizer is constructed, and an adversarial learning system is formed by combining the building boundary optimizer and the building boundary extraction branch composed of boundary classification heads. During model training, the building boundary optimizer guides the building boundary extraction branch to generate building boundaries similar to the real boundaries.
6. The method for extracting small buildings from high-resolution remote sensing images by fusing local feature perception and boundary constraints according to claim 5, characterized in that, The training loss function for the building recognition model is expressed as: ,in, , , These are the building area loss, building boundary loss, and boundary optimizer loss, respectively.
7. The method for extracting small buildings from high-resolution remote sensing images by fusing local feature perception and boundary constraints according to claim 1, characterized in that, The instance pseudo-labels are combined with the corresponding second sample dataset and the first sample dataset, including: The information entropy of each pixel in the instance pseudo-label is calculated based on the instance pseudo-label probability value at each pixel in the second sample dataset image generated by the region classification head; Reliable pseudo-labels are filtered using a preset threshold and based on the information entropy of each pixel. The spatial range of each building instance and the percentage of building pixels in the instance pseudo-label are obtained based on the connected components of the real label and the reliable pseudo-label. The pseudo-labels of the instances are filtered based on the proportion of building pixels in the image, and the labeled building instances are randomly transferred to the pseudo-label instances based on the spatial range of the building instances.
8. A system for extracting small buildings from high-resolution remote sensing images by integrating local feature perception and boundary constraints, characterized in that, It includes: a sample acquisition module, a model training module, and an object recognition module, among which, The sample acquisition module is used to acquire a first sample dataset and a second sample dataset from the remote sensing image sample data. The first sample dataset is remote sensing image data with building labels, and the second sample dataset is remote sensing image data without building labels. The model training module is used to construct a building recognition model and train the building recognition model using a first sample dataset and a second sample dataset to obtain a trained building target model. The building recognition model includes a dual heterogeneous feature encoder consisting of a main encoder and an auxiliary encoder, a decoder, a region classification head and a boundary classification head, and the region classification head and the boundary classification head share the encoder and decoder. The main encoder and the auxiliary encoder adopt different types of backbone networks. The target recognition module is used to input the remote sensing image to be detected into the building target model, and to extract the buildings in the remote sensing image to be detected using the building target model; The building recognition model training process in the model training module includes: first, using the first sample dataset to train the building recognition model for the first time; then, inputting the second sample dataset into the initially trained building recognition model to obtain instance pseudo-labels in the second sample dataset; combining the instance pseudo-labels with the corresponding second sample dataset and the first sample dataset as input data for retraining the model; and using this input data to retrain the building recognition model to obtain the building target model.
9. An electronic device, characterized in that, include: At least one processor, and a memory coupled to said at least one processor; The memory stores a computer program that can be executed by the at least one processor to implement the method as described in any one of claims 1 to 7.
10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when executed, enables the implementation of the method as described in any one of claims 1 to 7.
Citation Information
Patent Citations
Unmanned aerial vehicle remote sensing small target detection method based on improved YOLOv7
CN118411634A
Building extraction method based on multi-level perception and boundary joint constraint
CN118918481A