Natural field type extraction method based on remote sensing large model pre-training and multi-granularity boundary supervision
By using a remote sensing large model pre-training and multi-granularity boundary supervision method, the boundary adaptability and generalization problems of natural field pattern extraction in complex terrain and cross-regional applications are solved, achieving high-precision field pattern extraction and improving the extraction effect in hilly and mountainous areas.
Patent Information
- Application Number
- CN202610035550.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-01-12
- Publication Date
- 2026-02-10
AI Technical Summary
Existing natural field pattern extraction methods suffer from poor boundary scale adaptability, weak cross-regional generalization ability, and insufficient detail capture in complex terrain and cross-regional applications. In particular, in heterogeneous terrain areas such as hilly and mountainous areas, traditional methods are prone to over-segmentation or under-segmentation, and are sensitive to noise interference from remote sensing images, resulting in a decrease in extraction accuracy.
By employing a remote sensing large model pre-training and multi-granularity boundary supervision method, high-precision natural field type extraction results are generated through spatiotemporal spectrum integrated model pre-training, multi-branch plot structure analysis, multi-granularity boundary enhancement, and dynamic attention fusion.
The model's robustness to different terrains and remote sensing image noise has been improved, the accuracy of boundary detection and cross-regional adaptability have been enhanced, the extraction accuracy of small-scale fields has been improved, and the extraction error in complex scenes has been reduced.
Smart Images

Figure CN121505458A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of intelligent processing of remote sensing images and agricultural information extraction technology, specifically a method for extracting natural field patterns using remote sensing large model pre-training and multi-granularity boundary supervision. Background Technology
[0002] Automatic extraction of natural field topography is a core component of agricultural remote sensing technology, and its accuracy directly determines the reliability of downstream applications such as arable land resource surveys, crop yield estimation, and farmland disaster monitoring. Traditional methods for extracting natural field topography mainly rely on conventional image processing techniques such as regular raster segmentation and morphological filtering. They delineate plot boundaries by setting fixed thresholds or geometric rules. However, these methods have significant limitations: First, they are difficult to adapt to the "irregular and multi-scale" morphological characteristics of actual field boundaries, especially in heterogeneous terrain areas such as hilly and mountainous regions, where fields are fragmented due to topographic undulations and slope changes, making traditional methods prone to over-segmentation or under-segmentation. Second, traditional methods are highly dependent on input data. When remote sensing images are affected by cloud cover, noise interference, or spectral changes in ground features due to crop growth cycles, the extraction accuracy drops significantly, making it difficult to meet the application needs of complex agricultural scenarios.
[0003] In recent years, with the development of deep learning technology, large remote sensing models (such as SatMAE and SegFormer) have made breakthroughs in urban scene land cover segmentation tasks, but they still face three major technical bottlenecks in agricultural natural field pattern extraction scenarios: Existing models mostly use boundary labels with a single thickness (such as a fixed 3 pixels) for training, while the actual width of agricultural field ridges has a spatial heterogeneity of 2-5 pixels (affected by regional planting patterns and terrain conditions), which leads to a mismatch between the boundary features learned by the model and the real field ridge structure, resulting in boundary offset or boundary blurring problems. Existing large remote sensing models are mostly pre-trained based on urban scene data and have not been optimized for cross-terrain and cross-temporal features in agricultural scenes. When the model is migrated from plains to hilly areas, the feature distribution shift caused by terrain differences leads to a sharp drop in extraction performance.
[0004] Regular grid segmentation and single-branch network structures struggle to balance global layout with local details. The F1 score for identifying fragmented small plots (area less than 100㎡) is generally below 60%, especially in key areas such as broken field ridges and plot junctions, where the error is more significant.
[0005] To address the aforementioned issues, there is an urgent need in this field for a natural field extraction technique that can adapt to complex terrains and take into account both multi-scale boundary modeling and cross-regional generalization capabilities, in order to overcome the accuracy bottlenecks and application limitations of existing methods. Summary of the Invention
[0006] The purpose of this invention is to provide a method for extracting natural field patterns using pre-training of a large remote sensing model and multi-granularity boundary supervision, in order to solve the technical problems of poor boundary scale adaptability, weak cross-regional generalization ability, and insufficient detail capture in existing natural field pattern extraction methods proposed in the background art.
[0007] To solve the above-mentioned technical problems, the technical solution adopted by the present invention is as follows: A method for extracting natural field patterns using remote sensing large-scale model pre-training and multi-granularity boundary supervision includes the following steps: Step S1, pre-training a large remote sensing model as a feature extractor: pre-training a spatiotemporal spectrum integrated model on a large-scale spatiotemporal spectrum structured remote sensing dataset, and realizing unified modeling of multimodal information of remote sensing images through anchor point sensing masking mechanism and geographic information coding module, to obtain a backbone network with cross-resolution, cross-temporal and cross-spectral feature extraction capabilities; Step S2, Multi-branch plot structure analysis: Input the multi-scale feature map output in step S1 into the multi-branch structure perception network. This network adopts a high-resolution-low-resolution dual-input branch architecture, focusing on local texture details and global spatial context respectively, and outputs a natural field-shaped semantic segmentation prediction map through a dynamic attention fusion mechanism. Step S3, Multi-granularity boundary enhancement: Generate multi-scale field boundary labels based on morphological dilation and erosion operations, construct a boundary-guided feature enhancement module with frequency and space dual domains, split the feature map output in step S1 into two branches in the spatial domain and frequency domain for targeted enhancement, and output the field boundary prediction map in combination with a multi-task supervision mechanism. Step S4, Fusion Optimization: After aligning the semantic segmentation prediction map from Step S2 with the boundary prediction map from Step S3 in terms of spatial coordinates, redundant prediction regions are eliminated through pixel-level logical operations to generate a high-precision natural field extraction result.
[0008] According to the above technical solution, the large-scale spatiotemporal spectral structured remote sensing dataset in step S1 includes the spatial structure features, temporal variation features and spectral response features of multi-source satellite remote sensing images, and the data covers different terrain types and crop growth cycles, which can provide diverse samples required for cross-scene generalization training of the spatiotemporal spectral integrated model.
[0009] According to the above technical solution, in step S1, the anchor point sensing masking mechanism determines the anchor point area by analyzing the terrain complexity, land cover heterogeneity and imaging quality of the remote sensing image. It prioritizes retaining unmasked features of key semantic areas such as field boundaries and land cover junctions, and implements dynamic masking for homogeneous background areas. During the masking process, a cross-source collaborative masking strategy is adopted for multi-source data, and a temporal complementary masking strategy is adopted for multi-temporal data to enhance the model's ability to learn the features of key agricultural land cover.
[0010] According to the above technical solution, in step S1, the geographic information encoding module performs spatial encoding on the image coverage area by dividing it into quadtree grids, converting latitude and longitude coordinates into hierarchical binary vectors, and combining the spatial scale factor calculated by ground sampling distance GSD, and mapping it to the same dimension as the image feature token through a lightweight neural network, thereby realizing channel-level splicing and fusion of geospatial information and visual features, and improving the model's spatial positioning accuracy for fields of different scales.
[0011] According to the above technical solution, in step S2, the dual-input branch architecture is specifically as follows: The high-resolution branch uses convolution operations with a stride of 1 and skip connections to preserve fine-grained spatial information such as field boundaries and field ridge textures in the original feature map; The low-resolution branch expands the receptive field through dilated convolution and combines spatial attention mechanisms to capture the global layout of the field cluster and the topological relationship between adjacent plots. The dynamic attention fusion mechanism works as follows: Uncertainty is determined based on the pixel-level entropy value of the branch prediction result. Higher entropy values increase the weight of high-resolution branch features, while lower entropy values enhance the contribution of low-resolution branches. The fusion formula is as follows:
[0012] in This is the output value after feature fusion of the two branches. For high-resolution branch output, For low-resolution branch output, For adaptive attention weights.
[0013] According to the above technical solution, in step S3, the multi-scale field boundary label is specifically: the structural element parameters of morphological operation are dynamically selected according to the spatial heterogeneity of the field boundary of the area to be extracted, and a continuous boundary label sequence with a thickness of 2-5 pixels is generated; the label sequence constructs a hierarchical supervision loss, the coarse-grained label guides the model to learn the main outline of the field, and the fine-grained label strengthens the model's feature capture of small field ridges and boundary fracture areas.
[0014] According to the above technical solution, in step S3, the frequency-space dual-domain enhancement specifically involves: the spatial domain branch constructing a boundary-sensitive feature mapping through 3×3 convolution and batch normalization, combined with granular weighting factors. Enhance the response intensity of boundaries at different scales; the frequency domain branch separates the high-frequency and low-frequency components of the feature map through discrete Fourier transform, utilizing... The boundary details in the high-frequency components are amplified, restored to the spatial domain by inverse Fourier transform, and then concatenated with the spatial domain enhancement features at the channel level. The result is then input into the decoder to generate a boundary prediction map.
[0015] According to the above technical solution, in step S4, the pixel-level logical operation is a pixel-by-pixel XOR operation. The operation rule is: if a pixel is a field category in the semantic segmentation prediction map and a boundary category in the boundary prediction map, then the pixel is determined to be a redundant prediction and set to 0; the remaining pixels retain their original category values; after the operation, the small holes in the boundary area are eliminated by morphological closing operation to further optimize the integrity of the field outline.
[0016] According to the above technical solution, in step S1, the spatiotemporal spectrum integrated model adopts the ViT-Large architecture as the encoder and the decoder adopts an 8-layer Transformer structure. The pre-training process uses the AdamW optimizer with an initial learning rate of 1e-4 and adopts Cosine learning rate scheduling. The mean square error (MSE) loss constrains the image reconstruction accuracy, and finally outputs 256-1024-dimensional multi-scale spatiotemporal spectrum fusion features.
[0017] According to the above technical solution, in the dynamic attention fusion mechanism, the calculation of attention weight A is based on the cross-entropy loss derivative of the branch prediction result: when the absolute value of the derivative is ≥0.5, A takes the value of 0.6-0.8; when the absolute value of the derivative is ≤0.2, A takes the value of 0.2-0.4; when the absolute value of the derivative is between 0.2 and 0.5, A increases linearly with the increase of the absolute value of the derivative, and the weight range threshold is dynamically adjusted by the boundary detection F1 value of the validation set.
[0018] Compared with the prior art, the present invention has the following beneficial effects: In this invention, through the spatiotemporal spectrum integrated pre-training model and geographic information coding module, the model can fully learn the agricultural land cover features of different terrains and different time phases. In cross-regional migration tasks, the global classification error (GTC) is significantly reduced compared with the existing general domain adaptation model, solving the core problem of poor regional adaptability of traditional models.
[0019] Furthermore, in this invention, through the synergistic effect of multi-granularity boundary labels and frequency-space dual-domain enhancement, the model can be adapted to field ridge structures with a width of 2-5 pixels. In small-scale field extraction tasks, the boundary detection value is significantly improved, and the boundary closure rate is also significantly improved compared with the existing technology, effectively solving the problems of boundary blurring and breakage.
[0020] In addition, the dual-branch structure and dynamic attention fusion mechanism in this invention enable the model to simultaneously capture the global layout and local texture details of the field, taking into account the extraction accuracy of large contiguous fields and small fragmented fields; the anchor point perception mask mechanism and multimodal feature fusion enable the model to be highly robust to interference such as cloud cover and noise, with the extraction accuracy attenuation of less than 5% under interference scenarios, making it suitable for agricultural scenarios under complex imaging conditions. Attached Figure Description
[0021] Figure 1 This is a diagram illustrating the overall framework for multi-scale natural field pattern extraction based on a remote sensing fundamental model, as presented in this invention. Figure 2 This is a flowchart of the multi-branch domain adaptation module (AgriStructNet) of the present invention; Figure 3 This is a flowchart of the Boundary Guiding Feature Enhancement Module (BSPM) of the present invention; Figure 4 This is a multi-granularity label diagram of the present invention. Detailed Implementation
[0022] 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. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0023] Example 1 like Figure 1 As shown, the present invention adopts the following technical solution, specifically including four core steps: Step 1: Pre-train a large-scale remote sensing model as a feature extractor on a large-scale spatiotemporal spectral structured remote sensing dataset, including the spatial structure features, temporal variation features, and spectral response features of multi-source satellite imagery, covering different terrain types such as hills, mountains, and plains, as well as the entire crop growth cycle. The specific process of pre-training the spatiotemporal spectral integrated model is as follows: Anchor point regions are determined by analyzing the topographic complexity (slope, aspect standard deviation), land cover heterogeneity (NDVI index coefficient of variation), and imaging quality (cloud cover ratio, noise intensity) of remote sensing images. Unmasked features are retained for key semantic regions such as field boundaries and land cover junctions, while dynamic masking is applied to homogeneous background regions (such as contiguous wastelands). For multi-source data (such as simultaneous input of Sentinel-2 and Gaofen-2 images), cross-source collaborative masking is adopted, that is, non-anchor point images and anchor point images use the same mask to enhance cross-source feature alignment. For multi-temporal data, temporal complementary masking is adopted, with the mask ratio controlled at 75%, which improves the model's learning efficiency for key agricultural land cover while ensuring feature diversity.
[0024] Spatial encoding of the image coverage area is performed by dividing it into quadtree grids, converting latitude and longitude coordinates into hierarchical binary vectors (each layer corresponding to a spatial grid of different scales). The spatial scale factor is calculated by combining the ground sampling distance (GSD), specifically: Scale factor = GSD / 10m The baseline resolution is 10m. Geographic information is mapped to the same dimension as image feature tokens using a 2-3 layer lightweight multilayer perceptron (MLP), achieving channel-level stitching and fusion of geospatial information and visual features, thereby improving the model's spatial positioning accuracy for fields at different scales.
[0025] Model architecture and training parameters: The ViT-Large architecture is used as the encoder, which contains 24 Transformer blocks, 16 attention heads, and 1024 hidden layer dimensions. The decoder uses an 8-layer Transformer structure. The training process uses the AdamW optimizer with a weight decay coefficient of 1e-5 and an initial learning rate of 1e-4. Cosine learning rate scheduling is used, and the learning rate decays to 1e-3 of the initial value at the end of training. The mean squared error (MSE) loss is used to constrain the image reconstruction accuracy. Finally, a backbone network with cross-resolution, cross-temporal (i.e., full growth cycle), and cross-spectral (i.e., visible light-near infrared-shortwave infrared) feature extraction capabilities is obtained, which serves as the feature extractor for subsequent field identification tasks.
[0026] Step 2: Multi-branch parcel structure analysis. The multi-scale feature map output from Step 1 is input into the multi-branch structure perception network. This network adopts a high-resolution-low-resolution dual-input branch architecture, which is implemented as follows: High-resolution branch (HR): Employs 3×3 convolution operations with a stride of 1 and skip connections to preserve fine-grained spatial information such as field boundaries and ridge textures in the original feature map. After convolution, feature representation is enhanced by batch normalization and ReLU activation function.
[0027] Low-resolution branch (LR): Expands the receptive field (up to 64×64 pixels) through dilated convolution, and captures the global layout of the field cluster and the topological relationship between adjacent fields (such as field connectivity and arrangement patterns) by combining spatial attention mechanism. The spatial attention mechanism is used to calculate the weight coefficients at each position of the feature map to enhance the response of the core area of the field. Dynamic attention fusion mechanism: Uncertainty is determined based on the pixel-level entropy value of the prediction result of the context branch (low-resolution branch) (the higher the entropy value, the greater the prediction uncertainty). When the entropy value is ≥0.8, the feature weight of the high-resolution branch is increased (weight coefficient A∈[0.6,0.8]); when the entropy value is ≤0.5, the contribution of the low-resolution branch is enhanced (weight coefficient A∈[0.2,0.4]); when the entropy value is between 0.5 and 0.8, A increases linearly with the entropy value. Dual-branch feature fusion is achieved through the following calculation formula:
[0028] in This is the output value after feature fusion of the two branches. For high-resolution branch output, The low-resolution branch output is used to finally output a natural field-shaped semantic segmentation prediction map.
[0029] Step 3: Multi-granularity boundary enhancement. Based on morphological operations, multi-scale field boundary labels are generated, and a boundary-guided feature enhancement module with frequency space dual domains is constructed. The specific process is as follows: Based on the original binary field boundary labels (GT), the structural element parameters for morphological operations are dynamically selected according to the spatial heterogeneity of the field boundaries in the area to be extracted (variance coefficient of field ridge width). When the variation coefficient is ≥0.3 (i.e., large differences in boundary width), two types of square structural elements, 3×3 and 5×5, are used; when the variation coefficient is <0.3 (i.e., relatively uniform boundary width), a single 3×3 structural element is used. A continuous boundary label sequence with a thickness of 2-5 pixels is generated through morphological dilation and erosion operations, using the following formula:
[0030] Where g∈{2,3,4,5} represents the boundary thickness; a hierarchical supervised loss is constructed, with coarse-grained labels (4-5 pixels) guiding the model to learn the main outline of the field, and fine-grained labels (2-3 pixels) strengthening the model's feature capture of small field ridges and boundary fracture areas.
[0031] Frequency-space dual-domain enhancement includes spatial domain enhancement and frequency domain enhancement. Specifically, spatial domain enhancement involves splitting the feature map output from step 1 along the channel dimension to obtain a spatial domain feature branch (F1). A boundary-sensitive feature map is constructed using 3×3 convolution (SAME padding, ensuring the feature map size remains unchanged) and batch normalization, combined with granular weighting factors. (Inversely proportional to the boundary thickness and weighted by the sample distribution density, formula:)
[0032] Enhance the response intensity of boundaries at different scales and output the enhanced spatial features. .
[0033] Frequency domain enhancement specifically involves splitting the feature map to obtain a frequency domain feature branch (F2), and using Discrete Fourier Transform (DFT) to separate high-frequency components (i.e., energy percentage ≥30%, corresponding to boundary, texture, and other detailed information) from low-frequency components (corresponding to background and global structure information). The calculation formula for amplifying boundary details in high-frequency components is shown below:
[0034] in The original high-frequency components are fused with the enhanced high-frequency components, and then restored to the spatial domain using inverse Fourier transform (IDFT) to obtain the enhanced frequency domain features. Then and The data is concatenated along the channel dimension, inputting the corresponding decoder branch (each granular label corresponds to one decoder branch), outputting boundary response maps for each granularity, and combining multi-task supervised loss (weighted cross-entropy loss, with each granularity weight dynamically allocated according to the proportion of field ridge width) to optimize model parameters, finally outputting a predicted field boundary map.
[0035] Step 4: Fusion Optimization. After aligning the semantic segmentation prediction map output from Step 2 with the boundary prediction map output from Step 3 in terms of spatial coordinates (to ensure pixel-level spatial location matching), redundant prediction regions are removed through pixel-by-pixel XOR operations. The specific rules are as follows: If a pixel is classified as a field (value 1) in both the semantic segmentation prediction map and the boundary prediction map (value 1), then the pixel is considered a redundant prediction (misjudged as a boundary inside a field) and is set to 0; the remaining pixels retain their original category values; after the operation, morphological closing operations (3×3 square structuring elements) are used to eliminate tiny holes (area < 3 pixels) in the boundary region, further optimizing the integrity of the field outline, and finally generating a high-precision natural field shape extraction result.
[0036] Example 2 This embodiment is a further refinement of Embodiment 1. Using the remote sensing pre-trained model A²-MAE as the feature extractor, it enhances the spatiotemporal spectral modeling capability of the input image through anchor point sensing masking and geocoding. It introduces a multi-branch structure sensing network and a frequency-space dual-domain boundary enhancement module, supplemented by multi-scale supervised labels, to achieve high-precision segmentation and multi-scale generalization of natural field boundaries. The specific implementation steps include the following: Step 1: A²-MAE model pre-training. A²-MAE model pre-training specifically includes: Step 101, Training Data Preparation: Acquire remote sensing data from multiple satellite platforms, including the Gaofen series, Sentinel-2, and Landsat-8, covering the visible, near-infrared, and short-wave infrared bands. Perform spatial registration, temporal alignment, and radiometric normalization on data with different temporal and spatial resolutions and spectral ranges to ensure that the input data are aligned in a unified coordinate system. Divide the data into blocks according to the set slice size (e.g., 512×512 pixels) and perform spectral channel normalization for input into model training.
[0037] In this invention, the STSSD (Spatial-Temporal-Spectral Structured Dataset) large-scale remote sensing dataset is used as the pre-training foundation. This dataset is constructed from 4.2 million original images worldwide (covering approximately 1.045 million sampling locations), ultimately containing 510,000 image sets, totaling approximately 2.5 million images. The data covers over 12,000 city centers and over 10,000 nature reserves globally, spanning a 3-year timeframe and including both growing season and non-growing season samples. Data sources include Sentinel-2 (13 bands, 10m), Landsat-8 (7 bands, 30m), Gaofen-1 (4 bands, 1m), and Gaofen-2 (4 bands, 0.8m), with a resolution range of 0.8–30m / pixel, ensuring diversity across time, space, and spectrum.
[0038] Step 102, Anchor-Aware Mask Generation: To address occlusion and cloud interference issues in remote sensing images, key anchor point regions are dynamically selected for mask reconstruction. Specifically, candidate anchor point positions are determined based on the input image's metadata (including imaging time, observation angle, spatial resolution, etc.). Anchor-Aware Masks are dynamically generated by combining image texture variations and spatial location information. When the image group consists of multi-source images from the same time period, non-anchor images use the same mask as the anchor points to promote cross-source alignment; when the image group consists of images from the same source but from different times, non-anchor images use complementary masks of the anchor points to promote temporal complementarity; in other cases, random masks are used.
[0039] Furthermore, subsampling is performed on a subset of spectral bands randomly selected from the anchor point imagery to enhance cross-spectral robustness. A mask ratio of 75% is maintained to improve model generalization ability while ensuring diversity in feature learning.
[0040] Step 103, Geoencoder Embedding: The latitude and longitude coordinates (GPS) and ground sampling distance (GSD) corresponding to the image are converted into continuous real-valued vectors. A multi-level quadtree mesh is used to encode the geospatial data, converting latitude and longitude into binary hierarchical codes, and combining this with sinusoidal position coding for continuous representation. This geographic information is projected onto the same dimension as the image token using a lightweight multilayer perceptron (MLP, 2–3 layers), and then stitched together with the visual features of the image patch. This allows the model to perceive geographic location information during feature learning, enhancing its ability to perceive regional spatial positioning and scale changes.
[0041] Step 104, Encoder-Decoder Architecture: The encoder uses the ViT-Large architecture as the backbone network, containing 24 Transformer blocks, each with a hidden dimension of 1024, 16 attention heads, and an MLP hidden layer dimension of 4096. The input is an image patch with a resolution of 224×224 and a size of 16×16 patches. The encoder receives unoccluded image patches and, combined with the embedding information from the geoencoder, learns a joint spatial-spectral-temporal representation.
[0042] Decoder: Input the encoded visible block features and position embedding, reconstruct the pixel values of the occluded area, and realize the self-supervised mask reconstruction task.
[0043] Step 105, Optimization objective: Use mean squared error (MSE) as the reconstruction loss to constrain the consistency between the decoded output and the original pixels in the spectral and spatial domains.
[0044] Step 106, Output and Saving: On 8 NVIDIA A800 GPUs, using the AdamW optimizer, an initial learning rate of 1e-4, and Cosine learning rate scheduling, with a total batch size of 1024, training for 130 epochs. The final result is an A²-MAE encoder model with strong generalization capabilities. In subsequent downstream tasks, it is used only as a feature extractor and does not directly participate in end-to-end prediction.
[0045] Step 2, Feature extraction using the A²-MAE pre-trained model: The input image is fed into the A²-MAE model pre-trained on large-scale multi-source remote sensing data to extract multi-scale spatiotemporal spectral feature maps. The output feature maps contain spectral correlation, spatial structure, and geographic location embedding information, providing a unified feature representation for downstream tasks.
[0046] Step 3, using a multi-branch domain adaptation structure (AgriStructNet) to achieve semantic segmentation (e.g.) Figure 2 As shown in the diagram): In this step, multi-scale feature maps from the A²-MAE pre-trained large model are used as input and fed into a multi-branch domain adaptation structure to capture detailed textures and global contextual information respectively, thereby improving the accuracy of parcel semantic segmentation. Specifically, this includes the following steps: Step 301, Input and Feature Splitting: Detail Branch (High-Resolution Branch): Extract high-resolution features from the feature map to retain more boundary and texture details; Context Branch (Low-Resolution Branch): Downsample the input features to obtain a larger receptive field and capture the overall layout of the fields.
[0047] Step 302, Encoding-Decoding Stage: The detail branch encoder performs local convolution and normalization operations on high-resolution features, emphasizing fine-grained boundary information. The context branch encoder uses dilated convolution and attention mechanisms to extract global associations across fields.
[0048] The detail branch decoder uses skip connections to fuse shallow features and recover fine texture structure. The context branch decoder progressively upsamples and fuses global semantic information to enhance the consistency of field outlines.
[0049] Step 303, Multi-branch feature fusion: An attention mechanism is introduced to perform feature weighted fusion of the detail prediction map and the context prediction map. The final output is the natural field-shaped semantic segmentation result.
[0050] In the feature fusion stage, an attention mechanism is introduced to dynamically balance the contributions of the detail branch and the context branch. Specifically, when the context prediction is stable, more weight is given to the context branch; when there is uncertainty in the context, the weight of the detail branch is increased accordingly. That is, the attention weight A is defined using the confidence level of the context branch, and the fusion formula is as follows:
[0051] in This is the output value after feature fusion of the two branches. For high-resolution branch output, For low-resolution branch output, For adaptive attention weights.
[0052] Step 4, the Boundary Guidance Enhancement Module (BSPM) implements edge detection (e.g., Figure 3 As shown): The input features of the BSPM model are also multi-scale feature maps of a pre-trained A²-MAE large model. It primarily uses joint enhancement in the spatial and frequency domains to accurately detect the boundaries of naturally shaped plots. Specifically, it includes the following steps: Step 401, Feature Channel Segmentation: Morphological erosion and dilation operations are applied to the original land parcel boundary labels to generate boundary labels with thicknesses of 2px, 3px, 4px, and 5px, respectively. These labels serve as supervision signals, guiding the network to learn boundary features at different scales. The specific generation method is as follows: In this embodiment, 3×3 and 5×5 square structural elements are used as core parameters. The 3×3 structural element is used to generate finer boundaries (such as 2px or 3px thickness), and the 5×5 structural element is used to generate thicker boundaries (such as 4px or 5px thickness). The formula is as follows:
[0053] Where GT is the binary label of the original block boundary, Dilate and Erode represent morphological dilation and erosion operations respectively, and g represents the boundary thickness (pixels). The results are as follows: Figure 4 As shown, the left image is the original satellite image, and the right images represent the boundary labels corresponding to g∈{2,3,4,5}.
[0054] Step 402, Feature Channel Segmentation: Divide the feature map into spatial domain features F1 and frequency domain features F2 according to the channel dimension.
[0055] Step 403, Granularity Embedding: Calculate granularity factor based on multi-granularity boundary labels , directly A constant, inversely proportional to the boundary thickness, represents the granularity weight of the boundary label. Each granularity... These techniques are applied to the spatial domain enhancement and frequency domain enhancement processes, respectively, to achieve thickness-sensitive feature modulation.
[0056] Step 404, Spatial and Frequency Domain Enhancement: Spatial domain enhancement: Apply corresponding granularity to F1 The enhanced spatial features are obtained through the following steps: the input spatial domain features F1 are first passed through two 3×3 convolutional layers, followed by batch normalization and ReLU activation functions after each layer to form boundary-sensitive feature maps. During training, granular weighting factors are utilized. The convolution output is weighted and modulated.
[0057]
[0058] This allows for enhanced response for different boundary thicknesses (2px, 3px, 4px, 5px) and suppression of homogeneous internal regions.
[0059] Frequency domain enhancement: First, perform a Discrete Fourier Transform (DFT) on F2 to separate the high-frequency component F. 2h With low-frequency component F 2l .
[0060] The high-frequency component carries detailed information about boundaries and textures, through granularity weighting factors. Enlarge:
[0061] Then the enhanced high-frequency components F with low-frequency components 2l And by returning to the spatial domain through the inverse Fourier transform (IDFT), we obtain... .
[0062]
[0063] This allows for highlighting fine-grained boundary structures in the frequency space while preserving overall background information.
[0064] Step 405, Feature Fusion and Multi-Branch Prediction: For each granularity g, the enhanced feature... and The data is concatenated along the channel dimension and fed into the corresponding decoder branch D. g Each branch predicts the boundary response map F corresponding to the thickness. g .
[0065] Step 406, Multi-granularity loss fusion: Supervise the prediction of different thicknesses using a weighted loss function:
[0066] in, For granularity weight, This is the boundary label for the corresponding thickness.
[0067] This design enables BSPM to simultaneously monitor both thin and thick boundaries, achieving more stable boundary detection performance in natural field-shaped scenarios.
[0068] Step 5, Segmentation-Boundary Fusion Optimization: After aligning the semantic segmentation prediction map of the plots output by AgriStructNet with the binary boundary prediction map output by BSPM in spatial dimensions, a pixel-wise XOR operation is performed: if a pixel is 1 in both the semantic segmentation result and the boundary prediction result, then the pixel is set to 0 to remove redundant predictions in the boundary region; the values of other pixels remain unchanged. This operation can remove noisy pixels located on the boundary in the prediction while maintaining the integrity of the main region, thereby generating a final natural field-shaped plot extraction result with cleaner contours and more accurate boundaries.
[0069] This embodiment, through the steps described above, helps to overcome the technical bottleneck of extracting irregularly shaped land parcels. This embodiment designs a standard domain adaptation experiment on the publicly available GTPBD dataset, the first refined parcel and boundary dataset for global terraced fields, containing 47,537 high-resolution terraced field images, distributed across three geographic subdomains (South, North, and Global), each with different topographic relief and parcel density differences. One subdomain is used as the source domain, and the other as the target domain. During the training phase, unlabeled images of the target domain are allowed for adaptation, but their labels are not used.
[0070] Experimental results show that, in cross-domain combinations such as South→North, North→Global, and Global→South, compared with general unsupervised domain adaptation models (such as Pipa) and edge detection models (such as MuGE), this method reduces the error of the object-level error metric GTC (Global Total Classification Error) by approximately 3%–8%, and improves the edge detection metrics F1 and AP by approximately 2%–5%, respectively. This indicates that this method can effectively alleviate the performance degradation caused by differences in terrain, crop structure, and imaging conditions between different regions, and has strong cross-domain adaptability.
[0071] Example 3 Based on the above technical solution, this embodiment conducts a natural field pattern extraction experiment in a hilly and mountainous agricultural scenario. The experimental area is located in Yucheng District, Ya'an City, Sichuan Province (typical hilly terrain with highly fragmented fields and field ridges 2-5 pixels wide), to verify the effectiveness of the method of the present invention. The experimental data uses Sentinel-2 (13 bands, 10m resolution) and Gaofen-2 (4 bands, 0.8m resolution) remote sensing images, covering the crop growing season of 2023 (April-October). After data preprocessing, 12,000 512×512 pixel samples were obtained (8,400 images for training, 2,400 images for validation, and 1,200 images for test). Manually labeled field boundary vector data are used as ground truth (GT).
[0072] The specific implementation steps include: Step 1: Collect the STSSD spatiotemporal spectral structured dataset, which includes multi-source, multi-temporal remote sensing data, covering different terrains and crop cycles. Spatial registration (error ≤ 1 pixel) is performed on the data, the time series is divided according to the growth cycle, and the reflectance of each band is normalized to [0,1]. The data is divided into 512×512 pixel blocks, and the spectral channels are standardized (mean = 0.485, standard deviation = 0.229).
[0073] Anchor point areas are determined based on the NDVI index variation coefficient (threshold 0.3) and cloud cover ratio (threshold 20%) of the image. Field boundary areas (NDVI variation coefficient ≥ 0.3) are left unmasked, while homogeneous background areas (NDVI variation coefficient < 0.3) are masked. Cross-source collaborative masking is used for multi-source data, and temporal complementary masking is used for multi-temporal data, with a masking ratio of 75%.
[0074] The image's latitude and longitude (e.g., 103.0°-103.5°E, 29.5°-30.0°N) are divided into four layers using a quadtree grid, with each layer having a grid size of 10km×10km, 1km×1km, 100m×100m, and 10m×10m respectively. The scale factor is calculated using GSD (10m for Sentinel-2 and 0.8m for Gaofen-2), and then mapped to 1024 dimensions using a two-layer MLP (512-dimensional hidden layer) before being stitched together with image features.
[0075] Eight NVIDIA A800 GPUs were used, with a total batch size of 1024, and training lasted for 130 epochs. The first 10 epochs were a warm-up period (the learning rate was increased from 1e-6 to 1e-4), and Cosine learning rate scheduling was used thereafter. The reconstruction accuracy was constrained by MSE loss, and the reconstruction error (RMSE) was reduced to below 0.02 at the end of training. After training, the A²-MAE encoder was saved as a feature extractor (the parameters were frozen and did not participate in the fine-tuning of downstream tasks).
[0076] Step 2: The multi-scale feature map output by A²-MAE (resolution 256×256, 1024 channels) is divided into two paths: a high-resolution branch that is directly input (preserving the 256×256 resolution) and a low-resolution branch that is downsampled by 2 times (resolution 128×128). The high-resolution branch is processed by three 3×3 convolutions with a stride of 1, with channels of 512, 256, and 128 respectively, and skip connections, outputting a 128-channel detail feature map. The low-resolution branch is processed by three dilated convolutions and a spatial attention mechanism (dilation rates of 2, 3, and 4 respectively, with the same number of channels as the high-resolution branch), outputting a 128-channel context feature map. Both feature maps are then upsampled to 256×256 resolution using transposed convolutions to obtain the detail prediction map. With context prediction graph .
[0077] calculate The pixel-level entropy value (average entropy = 0.62) is used to assign an attention weight A = 0.55 based on the entropy value, using the formula... By fusing the results of the two branches, a semantic segmentation prediction map is obtained, with the pixel category being either field or non-field.
[0078] Step 3: Based on the manually annotated truth boundaries (GT), generate 2px and 3px thickness labels using 3×3 structural elements, and generate 4px and 5px thickness labels using 5×5 structural elements. Calculate the results. .
[0079] The feature map output by A²-MAE is split into F1 (first 512 channels, spatial domain) and F2 (last 512 channels, frequency domain) by channel; F1 is then processed by two 3×3 convolution layers and combined with... Weighted ,in F2 is separated into high-frequency components F by DFT. 2h With low-frequency component F 2l By amplifying F 2h get After fusion, it is obtained via IDFT. .
[0080] splicing and The input consists of four decoder branches (corresponding to four granularity labels), and the output is the boundary response map of each granularity. A weighted cross-entropy loss is used (weights are allocated according to the width of the field ridges). The model is optimized so that the pixel category of the boundary prediction map after training is either boundary or non-boundary.
[0081] Step 4: Based on the image geographic metadata (top left corner coordinates, resolution), the semantic segmentation prediction map and the boundary prediction map are aligned pixel by pixel (error ≤ 0.5 pixels); a pixel-by-pixel XOR operation is performed on the two aligned images to remove redundant pixels of fields and boundaries (accounting for about 3.2%); a 3×3 square structuring element is used to perform a closing operation to eliminate small holes in the boundary area (average number of holes eliminated = 2.1 per sample), and the final natural field pattern extraction result is obtained.
[0082] It should be noted that, in this document, relational terms such as "first" and "second" are used only to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such process, method, article, or apparatus.
[0083] Finally, it should be noted that the above descriptions are merely preferred embodiments of the present invention and are not intended to limit the present invention. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art can still modify the technical solutions described in the foregoing embodiments or make equivalent substitutions for some of the technical features. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the protection scope of the present invention.
Claims
1. A method for extracting natural field patterns using remote sensing large-scale model pre-training and multi-granularity boundary supervision, characterized in that: Includes the following steps: Step S1, pre-training a large remote sensing model as a feature extractor: pre-training a spatiotemporal spectrum integrated model on a large-scale spatiotemporal spectrum structured remote sensing dataset, and realizing unified modeling of multimodal information of remote sensing images through anchor point sensing masking mechanism and geographic information coding module, to obtain a backbone network with cross-resolution, cross-temporal and cross-spectral feature extraction capabilities; Step S2, Multi-branch plot structure analysis: Input the multi-scale feature map output in step S1 into the multi-branch structure perception network. This network adopts a high-resolution-low-resolution dual-input branch architecture, focusing on local texture details and global spatial context respectively, and outputs a natural field-shaped semantic segmentation prediction map through a dynamic attention fusion mechanism. Step S3, Multi-granularity boundary enhancement: Generate multi-scale field boundary labels based on morphological dilation and erosion operations, construct a boundary-guided feature enhancement module with frequency and space dual domains, split the feature map output in step S1 into two branches in the spatial domain and frequency domain for targeted enhancement, and output the field boundary prediction map in combination with a multi-task supervision mechanism. Step S4, Fusion Optimization: After aligning the semantic segmentation prediction map from Step S2 with the boundary prediction map from Step S3 in terms of spatial coordinates, redundant prediction regions are eliminated through pixel-level logical operations to generate a high-precision natural field extraction result.
2. The method for extracting natural field patterns using remote sensing large model pre-training and multi-granularity boundary supervision as described in claim 1, characterized in that: The large-scale spatiotemporal spectral structured remote sensing dataset in step S1 contains the spatial structure features, temporal variation features, and spectral response features of multi-source satellite remote sensing images. The data covers different terrain types and crop growth cycles, and can provide diverse samples for training the spatiotemporal spectral integrated model to achieve cross-scene generalization capabilities.
3. The method for extracting natural field patterns using remote sensing large model pre-training and multi-granularity boundary supervision as described in claim 2, characterized in that: In step S1, the anchor point sensing masking mechanism determines the anchor point area by analyzing the terrain complexity, land cover heterogeneity and imaging quality of the remote sensing image, and performs dynamic masking on homogeneous background areas. During the masking process, a cross-source collaborative masking strategy is adopted for multi-source data and a temporal complementary masking strategy is adopted for multi-temporal data to enhance the model's ability to learn the features of key agricultural land cover.
4. The method for extracting natural field patterns using remote sensing large model pre-training and multi-granularity boundary supervision as described in claim 3, characterized in that: In step S1, the geographic information encoding module spatially encodes the image coverage area by dividing it into quadtree grids, converting latitude and longitude coordinates into hierarchical binary vectors, and combining the spatial scale factor calculated by ground sampling distance (GSD). This is then mapped to the same dimension as the image feature token through a lightweight neural network, achieving channel-level stitching and fusion of geospatial information and visual features, thereby improving the model's spatial positioning accuracy for fields at different scales.
5. The method for extracting natural field patterns using remote sensing large model pre-training and multi-granularity boundary supervision as described in claim 1, characterized in that: In step S2, the dual-input branch architecture is specifically as follows: The high-resolution branch uses convolution operations with a stride of 1 and skip connections to preserve fine-grained spatial information of field boundaries and ridge textures in the original feature map. The low-resolution branch expands the receptive field through dilated convolution and combines spatial attention mechanisms to capture the global layout of the field cluster and the topological relationship between adjacent plots. The dynamic attention fusion mechanism works as follows: Uncertainty is determined based on the pixel-level entropy value of the branch prediction result. Higher entropy values increase the weight of high-resolution branch features, while lower entropy values enhance the contribution of low-resolution branches. The fusion formula is as follows: in This is the output value after feature fusion of the two branches. For high-resolution branch output, For low-resolution branch output, For adaptive attention weights.
6. The method for extracting natural field patterns through pre-training of a large remote sensing model and multi-granularity boundary supervision as described in claim 1, characterized in that: In step S3, the multi-scale field boundary labeling is specifically as follows: based on the spatial heterogeneity of the field boundaries in the area to be extracted, the structural element parameters of the morphological operation are dynamically selected to generate a continuous boundary label sequence with a thickness of 2-5 pixels; the label sequence is used to construct a hierarchical supervised loss, with coarse-grained labels guiding the model to learn the main outline of the field, and fine-grained labels enhancing the model's feature capture of small field ridges and boundary fracture areas.
7. The method for extracting natural field patterns using remote sensing large model pre-training and multi-granularity boundary supervision as described in claim 6, characterized in that: In step S3, the frequency-space dual-domain enhancement specifically involves: the spatial domain branch constructing a boundary-sensitive feature map through 3×3 convolution and batch normalization, combined with granular weighting factors. Enhance the response intensity of boundaries at different scales; the frequency domain branch separates the high-frequency and low-frequency components of the feature map through discrete Fourier transform, utilizing... The boundary details in the high-frequency components are amplified, restored to the spatial domain by inverse Fourier transform, and then concatenated with the spatial domain enhancement features at the channel level. The result is then input into the decoder to generate a boundary prediction map.
8. The method for extracting natural field patterns through pre-training of a large remote sensing model and multi-granularity boundary supervision as described in claim 1, characterized in that: In step S4, the pixel-level logical operation is a pixel-by-pixel XOR operation. The operation rule is: if a pixel is a field category in the semantic segmentation prediction map and a boundary category in the boundary prediction map, then the pixel is determined to be a redundant prediction and set to 0; the remaining pixels retain their original category values; after the operation, morphological closing operation is used to eliminate small holes in the boundary area, further optimizing the integrity of the field outline.
9. The method for extracting natural field patterns through pre-training of a large remote sensing model and multi-granularity boundary supervision as described in claim 1, characterized in that: In step S1, the spatiotemporal spectrum integrated model adopts the ViT-Large architecture as the encoder and the decoder adopts an 8-layer Transformer structure. The pre-training process uses the AdamW optimizer with an initial learning rate of 1e-4 and Cosine learning rate scheduling. The mean square error (MSE) loss constrains the image reconstruction accuracy, and finally outputs 256-1024-dimensional multi-scale spatiotemporal spectrum fusion features.
10. The method for extracting natural field patterns through pre-training of a large remote sensing model and multi-granularity boundary supervision according to claim 1, characterized in that: In the dynamic attention fusion mechanism, the attention weight A is calculated based on the cross-entropy loss derivative of the branch prediction results: when the absolute value of the derivative is ≥0.5, A takes the value of 0.6-0.8; when the absolute value of the derivative is ≤0.2, A takes the value of 0.2-0.4; when the absolute value of the derivative is between 0.2 and 0.5, A increases linearly with the increase of the absolute value of the derivative, and the weight range threshold is dynamically adjusted by the boundary detection F1 value of the validation set.
Citation Information
Patent Citations
Field extraction method, device and equipment based on multi-task deep learning
CN117197544A
Remote sensing image general basic model construction and analysis method based on grid coding
CN120495899A
Image feature extraction method based on multi-dimensional decomposition
CN121053475A
Cited By
Farmland parcel boundary instance segmentation method, system, equipment and medium
CN121962618A
A farmland plot boundary instance segmentation method, system, device and medium
CN121962618B
Road crack remote sensing image semantic segmentation active learning method based on self-supervised dual representation mechanism
CN122135149A
Multi-task drawing extraction system and method for remote sensing image farmland protection forest
CN122176533A