A method and system for extracting individual trees based on multispectral data
By constructing an end-to-end radiation correction system and a multi-scale attention fusion network based on condition generation adversarial network, the interference problems of atmospheric scattering, terrain shadowing and geometric distortion in the traditional single-wood extraction method are solved, and high-precision single-wood extraction and error quantification are achieved, improving the reliability and efficiency of single-wood segmentation.
Patent Information
- Application Number
- CN202510665494.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-22
- Publication Date
- 2025-08-05
- Estimated Expiration
- 2045-05-22
AI Technical Summary
The traditional single-wood extraction method is disturbed by factors such as atmospheric scattering, terrain shadows and geometric distortions during multi-spectral imaging, resulting in spectral information distortion and spatial position shift, affecting the accuracy and reliability of single-wood segmentation. In addition, the existing technology is difficult to effectively reduce these interferences and cannot adapt to the application limitations in complex scenarios.
An end-to-end radiation correction system based on conditional generation adversarial network (cGAN) is constructed, combined with multi-scale attention fusion network and terrain adaptive geometric correction strategy, through the collaborative training of atmospheric parameter generator and terrain shadow discriminator, reverse modeling and terrain shadow compensation of atmospheric radiation transmission process are realized, and geometric distortion correction is used to be performed using SuperPoint feature detection and SuperGlue matching algorithm, and a ReliefF-PCA feature selection framework is designed for feature screening and error quantification.
The accuracy and robustness of single-wood extraction in complex scenarios are significantly improved, and the error contribution of each processing link is quantified through the error transfer evaluation model, which achieves high-precision single-wood segmentation and spatial positioning, and improves the reliability and efficiency of the method.
Smart Images

Figure CN120182838B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of remote sensing image processing and forest resource monitoring, and in particular to a single tree extraction method and system based on multispectral data. Background Art
[0002] Single tree extraction, as a core technology for forest resource monitoring and ecological research, is of great significance to precise forestry management and carbon sink measurement. Traditional single tree extraction methods mainly rely on optical remote sensing data, but the multispectral imaging process is inevitably interfered by factors such as atmospheric scattering, terrain shadows and geometric distortion, resulting in spectral information distortion and spatial position offset, which seriously affects the accuracy and reliability of single tree segmentation.
[0003] At present, the existing Chinese patent application number is "CN202410855855.6" which discloses a eucalyptus extraction method based on hyperspectral data and its device, equipment, and medium; wherein the method includes: obtaining a first satellite remote sensing image, eucalyptus sample vector data, and cultivated land range data of the target study area; performing image preprocessing on the first satellite remote sensing image to obtain a second satellite remote sensing image; performing image feature difference analysis based on the second satellite remote sensing image and the eucalyptus sample vector data to extract the feature interpretation marks of multiple typical features in the second satellite remote sensing image; performing target feature analysis based on the multiple feature interpretation marks and the second satellite remote sensing image to obtain eucalyptus spectral features and eucalyptus vegetation index features; performing regional screening based on the eucalyptus spectral features, eucalyptus vegetation index features, preset thresholds, cultivated land range data, and preset screening conditions to obtain the spatial distribution extraction results of eucalyptus in the cultivated land; although it can also identify individual trees, it cannot effectively reduce inevitable interference, such as atmospheric scattering, terrain shadows, etc.
[0004] Traditional radiation correction relies on physical model parameter assumptions and is difficult to adapt to the nonlinear interference of complex atmospheric conditions and terrain shadows; multimodal feature fusion often adopts simple weighting or splicing methods, which cannot dynamically explore the deep complementarity of spectral-texture features; geometric alignment lacks terrain adaptability and has significant interpolation errors in complex areas; the feature selection process relies on empirical thresholds, which easily leads to dimensionality disasters and low computational efficiency; the error transmission mechanism is unclear, and it is difficult to quantify the influence of each processing link on the final result; in addition, noise interference and edge blurring in low-quality remote sensing data further restrict the integrity of single tree segmentation and spatial positioning accuracy; therefore, there is an urgent need for an intelligent single tree extraction method that integrates radiation correction, feature fusion, geometric alignment and error control to break through the application limitations of existing technologies in complex scenarios. Summary of the Invention
[0005] (1) Technical problems solved
[0006] In response to the shortcomings of the existing technology, the present invention provides a method and system for extracting individual trees based on multispectral data. It constructs an end-to-end multispectral individual tree extraction framework, uses a conditional generative adversarial network to simultaneously compensate for the influence of atmosphere and terrain, designs a multi-scale attention fusion network to achieve deep feature correlation, and introduces a terrain-adaptive geometric correction strategy. At the same time, an error transfer evaluation model is constructed to quantify the error contribution of each link, providing reliability assurance for multimodal data fusion. This solution effectively solves the core problems of traditional methods, such as radiation distortion, inefficient feature fusion, geometric registration errors, and difficulty in error tracing, and significantly improves the accuracy and robustness of individual tree extraction in complex scenarios.
[0007] (2) Technical solution
[0008] To achieve the above objectives, the present invention is implemented through the following technical solutions:
[0009] A single tree extraction method based on multispectral data, the extraction method comprising:
[0010] Construct a radiation correction system to eliminate the atmospheric and topographic effects in the collected multispectral datasets, and extract universal spectral data from the multispectral datasets after eliminating the effects;
[0011] The universal spectral data is fused with the texture features extracted from the grayscale co-occurrence matrix to segment the individual tree crowns in the universal spectral data to form an independent single tree dataset.
[0012] SuperPoint feature detection combined with the SuperGlue matching algorithm is used to establish pairs of homonymous points. The registration parameters are adjusted using the RANSAC algorithm. According to the complexity of the terrain, corresponding interpolation is used to correct geometric distortion to form a spatially aligned dataset.
[0013] The geometric distortion-corrected data is denoised, and the attention network model is used to enhance the edge features of the target. The dataset is used to train the ReliefF-PCA feature selection framework to screen out the optimal combination of spectral, texture, and structural features.
[0014] A quantitative evaluation index of radiation was constructed, and the error transmission effect of each processing link was evaluated using the error analysis method. Through cross-validation, a single tree multimodal dataset was extracted from the single tree dataset.
[0015] Furthermore, the radiation correction system adopts an end-to-end architecture based on a conditional generative adversarial network, which includes an atmospheric parameter generator, a terrain shadow discriminator, and a joint discriminator;
[0016] Among them, the atmospheric parameter generator adopts an atmospheric parameter generator based on the U-Net structure, which includes 5 downsampling layers and 5 upsampling layers. Each layer uses the ReLU activation function and batch normalization. The downsampling layer uses a 3×3 convolution kernel to extract high-level features, and the upsampling layer restores the spatial resolution through transposed convolution. At the same time, skip connections are set to fuse high- and low-level features.
[0017] The terrain shadow discriminator adopts the PatchGAN structure, which contains 4 convolutional layers, each with a stride of 2 and uses the LeakyReLU activation function;
[0018] The joint discriminator consists of three fully connected layers and is used to simultaneously receive the corrected spectrum and the real surface reflectance data.
[0019] Furthermore, the elimination of atmospheric and topographical influences in the collected multispectral data set comprises the following specific steps:
[0020] The atmospheric parameters and DEM terrain data simulated by MODTRAN are input into the atmospheric parameter generator, and then the DEM data is mapped to the spectral data coordinate system through the spatial transformation layer;
[0021] The atmospheric parameter generator reconstructs the atmospheric radiation transfer process through the deconvolution layer, and combines the downsampling layer, upsampling layer and skip connection to output the corrected spectral data. The terrain shadow compensation module is then used to compensate for the terrain shadow on the corrected spectral data, preliminarily processing the influence of terrain on multispectral data.
[0022] The Adam optimizer is used to train the model, and the network parameters are optimized through the generator loss and the discriminator loss.
[0023] Furthermore, when segmenting the single tree crown in the general spectral data, a multi-scale attention fusion network is used to achieve deep fusion of spectral and texture features, specifically including:
[0024] A dual-branch attention network is constructed based on the channel-level attention mechanism and the spatial-level attention mechanism. The attention weight matrix of spectral features and texture features is calculated through global average pooling and fully connected layers, and the fusion ratio is dynamically adjusted.
[0025] A 5-layer U-Net architecture is constructed, with each layer consisting of 2 convolutional blocks and 1 maximum pooling layer. Upsampling is performed through transposed convolution in the decoding stage, and skip connections are used to fuse the spectral reflectance mean and grayscale co-occurrence matrix features at different scales.
[0026] By combining the loss function , and obtain the combined loss coefficient , where is the focal loss function, Calculate the Dice coefficient for the edge truth value extracted based on the Canny operator. They are and The corresponding weight.
[0027] Furthermore, when forming the independent single tree dataset, a morphological reconstruction algorithm is used to remove hole noise in the segmentation results, and then the crown spatial adjacency relationship is established through Delaunay triangulation. The confidence assessment model is constructed by combining the mean spectral reflectance and texture entropy value to screen out complete single tree samples.
[0028] Furthermore, the SuperGlue matching algorithm is used to establish pairs of points with the same name, and the specific steps include:
[0029] S1. Use the SuperPoint network for end-to-end keypoint detection and descriptor extraction. The network includes a feature pyramid module and a differentiable non-maximum suppression layer to output sparse keypoints and their descriptors.
[0030] S2, using the SuperGlue algorithm to perform cross-view feature matching, using the attention mechanism to build a matching matrix, combined with the Sinkhorn algorithm for optimal matching allocation;
[0031] S3. Apply the RANSAC algorithm to purify the initial matching point pairs, set the maximum number of iterations to 1000 and the distance threshold to 3 pixels, and retain the matching pairs with an inlier ratio of more than 85%;
[0032] S4. Select the interpolation method based on the terrain complexity: bilinear interpolation is used for flat areas, cubic spline interpolation is used for medium areas, and thin plate spline interpolation is used for complex areas;
[0033] S5. Use the improved TPS algorithm to correct geometric distortion, calculate terrain relief in combination with DEM data, and dynamically adjust the control point density.
[0034] Furthermore, the data denoising adopts a hybrid denoising method combining a non-local mean denoising algorithm with an adaptive median filter, and retains edge information by setting a spectral similarity threshold and a spatial neighborhood window;
[0035] The attention network model adopts a dual-branch attention architecture, which includes a channel attention module and a spatial attention module. The channel attention module generates spectral feature weights through global average pooling and a fully connected layer, and the spatial attention module generates position weights through convolution operations, and finally outputs an enhanced edge feature map.
[0036] Furthermore, the training process of the ReliefF-PCA feature selection framework includes:
[0037] Calculate the ReliefF weight of each feature, set the number of iterations and the number of neighbors, and evaluate the correlation between features and categories through mutual information;
[0038] PCA was used for dimensionality reduction, and the principal components with cumulative variance contribution rate ≥ 95% were retained;
[0039] Construct a multimodal feature fusion space and standardize the spectral reflectance, grayscale co-occurrence matrix texture and morphological structure features;
[0040] The feature combination is optimized through cross-validation to screen out the optimal feature subset.
[0041] Furthermore, the evaluation of the error propagation effect includes:
[0042] a. Define a set of radiometric correction quality evaluation indicators, including root mean square error, mean absolute error, structural similarity, and spectral angle matching, and evaluate the radiometric fidelity of the corrected spectral data through multi-indicator fusion;
[0043] b. Construct an error propagation model and analyze the error contributions of atmospheric correction, terrain compensation, feature fusion, and other processing steps based on error propagation theory, and quantify the weight of the impact of the errors in each processing step on the final single tree extraction results;
[0044] c. Design a cross-validation experiment, divide the multispectral dataset into training, validation, and test sets, and calculate the confidence interval of the error propagation path through Monte Carlo simulation;
[0045] d. Establish multimodal data fusion rules, standardize and fuse the error-verified spectral data with texture and structural features, construct a feature space using principal component analysis, and implement hierarchical extraction of single-tree multimodal datasets through K-means clustering;
[0046] Among them, the error transfer model derives the covariance matrix of the processing link error through the chain rule, and combines sensitivity analysis to determine the key error sources; the multimodal dataset includes multispectral reflectance after radiation correction, grayscale co-occurrence matrix texture parameters and morphological structure characteristics.
[0047] A single tree extraction system based on multispectral data, the system comprising:
[0048] Radiation Correction Module: This module builds an end-to-end radiation correction system based on a conditional generative adversarial network. Through the collaborative training of an atmospheric parameter generator, a terrain shadow discriminator, and a joint discriminator, it eliminates atmospheric interference and terrain shadows in multispectral data and outputs universal spectral data.
[0049] Feature fusion and segmentation module: Design a multi-scale attention fusion network to dynamically fuse general spectral data with grayscale co-occurrence matrix texture features to achieve accurate segmentation of individual tree crowns and generate independent individual tree datasets;
[0050] Geometric correction module: SuperPoint feature detection combined with SuperGlue matching algorithm is used to establish pairs of points with the same name. The interpolation method is dynamically selected based on the complexity of the terrain to correct geometric distortion and form a spatially aligned dataset.
[0051] Data enhancement module: Builds an attention-enhanced denoising network, combines non-local mean filtering with adaptive median filtering for noise suppression, and enhances target edge features through channel attention and spatial attention mechanisms;
[0052] Feature selection module: Establish the ReliefF-PCA feature selection framework and screen the optimal combination of spectral-textural-structural features through mutual information evaluation and principal component analysis;
[0053] Error assessment module: Build an error transfer assessment model, quantify the error contribution of each processing link, and generate a single tree multimodal dataset after cross-validation.
[0054] (3) Beneficial effects
[0055] The present invention provides a method and system for extracting single trees based on multispectral data, which has the following beneficial effects:
[0056] Radiation correction system: An end-to-end model is constructed using a conditional generative adversarial network (cGAN). Through adversarial training of an atmospheric parameter generator (U-Net structure) and a terrain shadow discriminator (PatchGAN structure), the inverse modeling of the atmospheric radiation transfer process and terrain shadow compensation are achieved. The system maps DEM data to a spectral coordinate system through a spatial transformation layer, and reconstructs the radiation transmission path in combination with a deconvolution layer, thereby eliminating interference from atmospheric scattering and terrain shadows while retaining hyperspectral feature information.
[0057] Multimodal feature fusion network: A dual-branch attention mechanism is designed to calculate the feature weight matrix through global average pooling and fully connected layers, and dynamically adjust the fusion ratio of the spectral reflectance mean and the grayscale co-occurrence matrix texture; combining the morphological reconstruction algorithm and Delaunay triangulation technology to establish the spatial adjacency relationship of tree crowns while suppressing hole noise, effectively solving the problem of segmenting overlapping tree crowns in complex forest stands.
[0058] Adaptive geometric registration strategy: Based on the terrain complexity level, the interpolation method (bilinear interpolation in flat areas and thin plate spline interpolation in complex areas) is selected, and the density of control points is adjusted in combination with the improved TPS algorithm to achieve high-precision spatial alignment of multi-view data.
[0059] ReliefF-PCA feature selection framework: The ReliefF algorithm is used to calculate feature weights (assessing feature-category correlation based on mutual information), combined with PCA dimensionality reduction to retain principal component information, ultimately selecting the optimal feature combination containing spectral reflectance, texture parameters, and morphological features. This framework reduces redundant feature dimensions while maintaining classification accuracy, improving model training efficiency.
[0060] Quantitative analysis of error propagation: An error propagation model based on the chain rule is established. The error contribution of each processing link is analyzed through the covariance matrix, and the key error sources are identified by combining Monte Carlo simulation. This mechanism achieves quantitative control of errors in links such as atmospheric correction and feature fusion, improving the reliability and repeatability of the method.
[0061] Attention-enhanced denoising network: A dual-branch attention module (channel attention + spatial attention) is designed to collaboratively enhance target edge features. A hybrid denoising method combining non-local mean and adaptive median filtering is used to suppress noise while retaining image edge details, improving segmentation performance in low-quality data scenarios. BRIEF DESCRIPTION OF THE DRAWINGS
[0062] Figure 1 It is a flow chart of the overall structure of the present invention. DETAILED DESCRIPTION
[0063] The following will provide a clear and complete description of the technical solutions in the embodiments of the present invention in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. All other embodiments obtained by ordinary technicians in this field based on the embodiments of the present invention without making any creative efforts shall fall within the scope of protection of the present invention.
[0064] Forests play a vital role in global ecosystem services, supporting carbon sequestration, biodiversity conservation and ecosystem resilience. They are also an important part of comprehensive natural resource surveys. In this context, accurate estimation of forest stand and individual tree parameters is crucial for effective ecosystem management and forestry practices. Advances in remote sensing technology, coupled with increased availability of remote sensing data and improved methods, have partially solved the difficulties in conducting forest resource surveys in complex terrain and significantly improved efficiency. These advances help meet the demand for efficient, large-scale forest resource assessments.
[0065] As a core technology for forest resource monitoring and ecological research, individual tree segmentation is of great significance for precise forestry management and carbon sequestration measurement. Traditional individual tree segmentation methods rely primarily on optical remote sensing data. However, multispectral imaging is inevitably affected by factors such as atmospheric scattering, terrain shadows, and geometric distortion, leading to spectral distortion and spatial position shifts, which seriously affect the accuracy and reliability of individual tree segmentation.
[0066] The details are as follows:
[0067] First, in the field of radiation correction, traditional MODTRAN-based atmospheric correction models rely on preset a priori parameters such as aerosol type and water vapor content, making it difficult to adapt to the complex and changeable atmospheric environment, and unable to synchronously compensate for the nonlinear effects of terrain shadows on the spectrum; for example, the reflectivity attenuation of shadowed areas in mountainous terrain is often misjudged as differences in vegetation types, leading to subsequent classification errors; in addition, traditional methods adopt a step-by-step correction strategy (atmosphere first, then terrain), ignoring the interaction between atmospheric parameters and terrain characteristics, and the corrected data is prone to spectral discontinuities.
[0068] Secondly, in the feature fusion and segmentation stages, existing technologies mostly use simple spectral-texture feature splicing or linear weighting methods, which make it difficult to capture the deep correlation between multimodal data; for example, the gray-level co-occurrence matrix (GLCM) texture features are easily contaminated by noise in low-resolution images, and traditional convolutional neural networks lack a dynamic attention allocation mechanism for multi-scale features, resulting in blurred segmentation boundaries between adjacent tree crowns in complex forest stands, and the existence of over-segmentation or under-segmentation problems.
[0069] Third, in the data enhancement and feature selection process, traditional Gaussian filtering or mean filtering is prone to losing edge details during the denoising process, while the denoising network based on deep learning lacks targeted optimization of spectral features; in terms of feature selection, when the existing ReliefF or PCA methods are used alone, it is difficult to balance feature discrimination and computational efficiency, and the redundancy between multimodal features is not considered, resulting in excessively high feature space dimensions or missing information.
[0070] Now in response to the above-mentioned problems, Figure 1 The specific improvements are as follows:
[0071] 1. Data Collection
[0072] A drone system equipped with a multispectral camera (LightGene MF620 camera) was used to acquire image data in five bands (blue, green, red, red-edge, and near-infrared) and simultaneously record POS positioning information. The flight parameters were set as follows: altitude 150 m, ground resolution 0.05 m, heading overlap rate 75%, and lateral overlap rate 60%.
[0073] 2. Radiation correction
[0074] 2.1 Network Architecture
[0075] An end-to-end radiation correction model based on the conditional generative adversarial network (CGAN) is constructed, which includes an atmospheric parameter generator (U-Net structure), a terrain shadow discriminator (PatchGAN) and a joint discriminator.
[0076] The atmospheric parameter generator uses a 6-layer downsampling and upsampling structure (for example, satellite images are downsampled from 1024x1024 to 16x16 and then restored). Each layer contains 3×3 convolution, batch normalization and ReLU activation function, and skip connections fuse high- and low-level features (similar to the highway structure, allowing deep-layer features to be directly transferred to shallow layers).
[0077] The terrain shadow discriminator consists of 4 convolutional layers with a stride of 2 and uses the LeakyReLU activation function to discriminate the terrain shadow compensation effect of the corrected spectrum.
[0078] The joint discriminator consists of three fully connected layers (the number of neurons is 1024, 512, and 1 respectively). It receives the corrected spectral data and the real surface reflectance data at the same time and optimizes the network parameters by comparing the differences between the two.
[0079] 2.2. Training data preparation:
[0080] Atmospheric parameter dataset: 100,000 atmospheric parameter combinations with different aerosol types (rural, urban, and ocean), water vapor content (0.5-5 cm), and solar zenith angles (0°-70°) were generated through MODTRAN simulation.
[0081] Terrain shadow dataset: Terrain shadow masks with different slopes (0°-60°) and aspects (0°-360°) are generated based on ASTERGDEMV3 data and registered with the synchronously acquired multispectral images.
[0082] 2.3 Training process:
[0083] The atmospheric parameters and DEM data simulated by MODTRAN are input, and the DEM is mapped to the spectral coordinate system through the spatial transformation layer (affine transformation matrix).
[0084] The atmospheric parameter generator reconstructs the radiation transfer process (simulating the path of light passing through the atmosphere) through the deconvolution layer and outputs corrected spectral data; it restores the blurred image to a clear image.
[0085] The terrain shadow compensation module calculates the slope and aspect (such as sunny mountain side and shady mountain side) based on the DEM and generates a shadow mask for compensation.
[0086] 2.4 Model training
[0087] Using Adam optimizer , set the generator learning rate to 1e-4, the discriminator learning rate to 4e-4, and the loss function includes the generator loss (L1 loss) and the discriminator loss (adversarial loss + terrain shadow compensation loss). During the training process, the correction effect is evaluated every 50 epochs, and the model performance is verified using indicators such as RMSE and MAE.
[0088] The loss function is: ,in, is the total loss function, It is an adversarial loss used for game training between the discriminator and the generator; is the L1 norm loss , a measure of the absolute error between the corrected spectrum and the true reflectance; Compensate for shadow losses , calculated based on DEM slope and aspect.
[0089] 3. Feature fusion segmentation
[0090] 3.1 Network Design
[0091] A dual-branch attention fusion network is constructed. The channel attention branch generates weights (8×8×64, similar to assigning different weights to different spectral bands) through global average pooling and fully connected layers, and the spatial attention branch uses 7×7 convolution to generate position weights.
[0092] The U-Net architecture consists of a four-layer encoding-decoding structure (e.g., compression from 256×256 to 32×32 and then restoration). Each convolutional block contains two 3×3 convolutional layers, and skip connections fuse features of different scales (spectral mean, GLCM entropy, contrast, for example, distinguishing between broad-leaved and coniferous forests). In the decoding stage, upsampling is performed through transposed convolution, and skip connections fuse the spectral mean (6-dimensional) with the gray-level co-occurrence matrix (GLCM) texture (4-dimensional).
[0093] 3.2 Feature Fusion
[0094] Dynamic fusion formula:
[0095] ,in, is the fused feature vector, Dynamically calculated by the attention weight matrix, range [0.3, 0.7], is the spectral feature vector after radiation correction (6 dimensions); The texture feature vector (4-dimensional) extracted from the gray-level co-occurrence matrix.
[0096] 3.3 Training strategy:
[0097] The combined loss function is focal loss (γ=2, focusing on difficult-to-classify samples) and marginal Dice loss (λ=0.5, protecting boundary information), and the AdamW optimizer (learning rate 1e-4) is used.
[0098] Data augmentation includes random rotation (±30°, simulating different shooting angles), scaling (0.8-1.2 times, adapting to shooting at different distances), and Gaussian noise (σ=0.01, simulating sensor error).
[0099] 3.4. Design of combined loss function:
[0100] Using a combined loss function:
[0101] ,in, is the combined loss function, is the focal loss function, Calculate the Dice coefficient for the edge truth value extracted based on the Canny operator. They are and The corresponding weight, =0.7, =0.3.
[0102] 3.5. Post-segmentation processing:
[0103] Morphological reconstruction uses opening and closing operations to eliminate holes (such as filling small gaps in tree crowns), Delaunay triangulation to establish adjacency relationships, and the confidence model combines the mean spectral reflectance (μ>0.6, such as the green band mean of healthy vegetation is higher), texture entropy (E>4.2, such as the entropy value of rough bark is higher), and the number of adjacent tree crowns (N) to segment the universal spectral data and obtain universal single-tree spectral data.
[0104] 3.6 Confidence Assessment Model
[0105] Construct a three-tuple evaluation indicator: mean spectral reflectance (μ), texture entropy (E), and number of adjacent tree crowns (N).
[0106] Confidence formula:
[0107] ,in, is the confidence level, μ is the mean value of the current crown spectral reflectance; is the average spectral reflectance of universal single tree spectral data; N is the number of adjacent crowns of the current crown; is the maximum number of adjacent crowns in the universal single tree spectral data; E is the current crown texture entropy value; is the average texture entropy value of universal single-wood spectral data; are the maximum and minimum values of texture entropy, respectively; samples with confidence ≥ 0.7 are selected as the final single tree dataset.
[0108] 4. Geometric correction
[0109] 4.1 Feature Matching
[0110] The SuperPoint network contains 3 layers of feature pyramids (stride = 2, 4, 8), outputs 2048-dimensional descriptors, and retains the top-1000 key points with non-maximum suppression.
[0111] The SuperGlue matching matrix was optimized by 50 iterations of the Sinkhorn algorithm and 500 iterations of RANSAC (random sampling verification to exclude false matches), with the distance threshold set to 3 pixels.
[0112] 4.2 Terrain Adaptive Interpolation
[0113] The terrain relief (standard deviation) is calculated based on the DEM. Bilinear interpolation (simple and fast) is used in flat areas (<2m, such as the North China Plain), cubic spline interpolation (smoother) is used in medium areas (2-5m, such as the Loess Plateau), and complex areas (>5m, such as the Hengduan Mountains).
[0114] Dynamically adjust the control point density (0.5-2 / 100m², more dense in mountainous areas), and modify the transformation parameters in combination with the DEM slope.
[0115] 4.3 Terrain complexity classification:
[0116] Calculate the terrain relief (RuggednessIndex) based on DEM data:
[0117] ,in, is the terrain relief (unit: meter); is the elevation difference between the i-th adjacent grid; n is the number of grid neighborhoods (usually 8 neighborhoods); classification standards: flat area (RI < 2m), medium area (2m ≤ RI ≤ 5m), complex area (RI > 5m).
[0118] 4.4. Interpolation method selection:
[0119] Flat area: bilinear interpolation (error ≤ 0.5 pixel);
[0120] Medium area: cubic spline interpolation (error ≤ 0.8 pixels);
[0121] Complex areas: Thin plate spline interpolation (TPS), dynamic adjustment of control point density (interval 5-20m).
[0122] 5. Data Augmentation
[0123] 5.1. Hybrid denoising:
[0124] The non-local mean filter window size was set to 7 × 7 (considering the surrounding 49 pixels), and the similarity threshold τ = 0.05 (differences less than 5% were considered similar). The adaptive median filter was iterated three times (gradually expanding the window to process salt and pepper noise) to retain valid edges in the salt and pepper noise (e.g., wires were still visible in the noise).
[0125] 5.2. Attention Enhanced Network
[0126] The channel attention module generates spectral weights (64 dimensions, such as giving higher weight to the near-infrared band), and the spatial attention module generates a 256×256 weight map through convolution (such as highlighting road areas). On the forest dataset, the edge retention rate after denoising reaches 94% (similar to erasing photo noise but retaining hair details), and the noise variance is reduced from 0.03 to 0.008.
[0127] 6. Feature Selection
[0128] 6.1. ReliefF-PCA Framework
[0129] Calculate the ReliefF weights of 10 nearest neighbors for 50 iterations (similar to voting to select important features), and filter the features with the top 30% weights; PCA retains 95% variance (for example, compressing 32 spectral bands into 8 principal components) and compresses the 32-dimensional features to 8 dimensions.
[0130] 6.2. ReliefF weight calculation:
[0131] The number of iterations is 1000, the number of neighbors is 50, and the correlation between features and categories is calculated:
[0132] ,in, is the weight value of the i-th feature; is the number of neighbor samples (value is 50); is the difference between the current sample and its jth neighbor in feature i; is the prior probability of class c; is the category to which the current sample belongs; is the difference between the current sample and the jth nearest neighbor of class c on feature i; the features with the top 20% weight are retained.
[0133] 6.3 Multimodal Fusion
[0134] After standardization, spectral features (average of 7 bands, such as red, green, and blue), texture features (5 parameters such as GLCM contrast and entropy, such as bark texture), and morphological features (4 parameters such as area and perimeter, such as crown shape) were fused, and the classification accuracy of the feature subset reached 93.6% (for example, distinguishing between pine trees and fir trees).
[0135] 7. Error Assessment
[0136] 7.1, Transfer Model:
[0137] The error covariance matrix was derived based on the chain rule (e.g., calculating the impact of each module error on the final result). The atmospheric correction link had the largest error contribution (28%), and the error confidence interval was determined through Monte Carlo simulation (1000 times, random sampling test).
[0138] 7.2 Cross-validation
[0139] The multispectral dataset was divided into training / validation / test sets at a ratio of 7:2:1 (e.g., 1,000 images were divided into 700 / 200 / 100). Error propagation path analysis showed that the feature fusion link amplified the error by 1.5 times. After optimization, the error confidence interval was compressed from ±5.2% to ±3.1%.
[0140] In the application, the several formulas involved are all calculated by taking their numerical values after removing the dimensions, and the formulas are established by collecting a large amount of data and performing software simulation to obtain a formula for the most recent real situation. Some coefficients or weights in the formulas are set by technical personnel in this field according to actual conditions, so they will not be elaborated here.
[0141] The above embodiments can be implemented in whole or in part by software, hardware, firmware, or any other combination thereof. When implemented using software, the above embodiments can be implemented in whole or in part in the form of a computer program product. Those skilled in the art will appreciate that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution.
[0142] The units described as separate components may or may not be physically separate, and the components shown as units may or may not be physical units, and may be located in one place or distributed across multiple network units. Some or all of these units may be selected to achieve the purpose of this embodiment as needed.
[0143] The above is only a specific implementation method of the present application, but the scope of protection of the present application is not limited thereto. Any technician familiar with this technical field can easily think of changes or replacements within the technical scope disclosed in this application, which should be covered by the scope of protection of the present application.
Claims
1. A single tree extraction method based on multispectral data, characterized in that: The extraction method includes: Construct a radiation correction system to eliminate the atmospheric and topographic effects in the collected multispectral datasets, and extract universal spectral data from the multispectral datasets after eliminating the effects; The radiation correction system adopts an end-to-end architecture based on conditional generative adversarial networks, which includes an atmospheric parameter generator, a terrain shadow discriminator, and a joint discriminator. Among them, the atmospheric parameter generator adopts an atmospheric parameter generator based on the U-Net structure, which includes downsampling layers and upsampling layers. Each layer uses the ReLU activation function and batch normalization. The downsampling layer uses the convolution kernel to extract high-level features, and the upsampling layer restores the spatial resolution through transposed convolution. At the same time, skip connections are set to fuse high- and low-level features. The terrain shadow discriminator adopts the PatchGAN structure, which includes a convolutional layer and uses the LeakyReLU activation function; The joint discriminator consists of a fully connected layer and is used to simultaneously receive the corrected spectrum and the true surface reflectance data; Eliminate atmospheric and topographic effects from the collected multispectral dataset. The specific steps include: The atmospheric parameters and DEM terrain data simulated by MODTRAN are input into the atmospheric parameter generator, and then the DEM terrain data is mapped to the spectral data coordinate system through the spatial transformation layer; The atmospheric parameter generator reconstructs the atmospheric radiation transfer process through the deconvolution layer, and combines the downsampling layer, upsampling layer and skip connection to output the corrected spectral data. The terrain shadow compensation module is then used to compensate for the terrain shadow on the corrected spectral data, preliminarily processing the influence of terrain on multispectral data. The Adam optimizer is used to train the model, and the network parameters are optimized through the generator loss and the discriminator loss; The universal spectral data is fused with the texture features extracted from the grayscale co-occurrence matrix to segment the individual tree crowns in the universal spectral data to form an independent single tree dataset. SuperPoint feature detection is used, combined with the SuperGlue matching algorithm to establish pairs of homonymous points. The registration parameters are adjusted using the RANSAC algorithm. According to the complexity of the terrain, corresponding interpolation is used to correct geometric distortion to form a spatially aligned dataset. The geometric distortion-corrected data is denoised, and the attention network model is used to enhance the edge features of the target. The dataset is used to train the ReliefF-PCA feature selection framework to screen out the optimal combination of spectral, texture, and structural features. A quantitative evaluation index of radiation was constructed, and the error propagation effect was evaluated using error analysis method. Through cross-validation, a single-tree multimodal dataset was extracted from the single-tree dataset.
2. The method for extracting single trees based on multispectral data according to claim 1, characterized in that: When segmenting the single tree crown in the general spectral data, a multi-scale attention fusion network is used to fuse the spectral and texture features. The specific steps include: A dual-branch attention network is constructed based on the channel-level attention mechanism and the spatial-level attention mechanism. The attention weight matrix of spectral features and texture features is calculated through global average pooling and fully connected layers, and the fusion ratio is dynamically adjusted. A multi-layer U-Net architecture is constructed, with each layer consisting of two convolutional blocks and one maximum pooling layer. Upsampling is performed through transposed convolution in the decoding stage, and skip connections are used to fuse the spectral reflectance mean and grayscale co-occurrence matrix features at different scales. pass , and get the combined loss function , where is the focal loss function, Calculate the Dice coefficient for the edge truth value extracted based on the Canny operator. They are and The corresponding weight.
3. The method for extracting single trees based on multispectral data according to claim 2, characterized in that: When forming the independent single tree dataset, a morphological reconstruction algorithm is used to remove hole noise in the segmentation results, and then the crown spatial adjacency relationship is established through Delaunay triangulation. The confidence assessment model is constructed by combining the mean spectral reflectance and texture entropy value to screen out complete single tree samples.
4. The method for extracting single trees based on multispectral data according to claim 3, characterized in that: The specific steps of establishing the same-name point pairs by combining the SuperGlue matching algorithm include: S1. Use the SuperPoint network for end-to-end keypoint detection and descriptor extraction. The network includes a feature pyramid module and a differentiable non-maximum suppression layer to output sparse keypoints and their descriptors. S2, using the SuperGlue algorithm to perform cross-view feature matching, using the attention mechanism to build a matching matrix, combined with the Sinkhorn algorithm for optimal matching allocation; S3. Apply the RANSAC algorithm to purify the initial matching point pairs, set the maximum number of iterations and the distance threshold, and retain the matching pairs with an inlier ratio of more than 85%; S4. Select the interpolation method based on the terrain complexity: bilinear interpolation is used for flat areas, cubic spline interpolation is used for medium areas, and thin plate spline interpolation is used for complex areas; S5. Use the improved TPS algorithm to correct geometric distortion, calculate terrain relief in combination with DEM data, and dynamically adjust the control point density.
5. The method for extracting single trees based on multispectral data according to claim 4, characterized in that: The data denoising adopts a non-local mean denoising algorithm combined with a hybrid denoising method of adaptive median filtering, and retains edge information by setting a spectral similarity threshold and a spatial neighborhood window; The attention network model adopts a dual-branch attention architecture, including a channel attention module and a spatial attention module; Among them, the channel attention module generates spectral feature weights through global average pooling and fully connected layers; the spatial attention module generates position weights through convolution operations and finally outputs an enhanced edge feature map.
6. The method for extracting single trees based on multispectral data according to claim 5, characterized in that: The training process of the ReliefF-PCA feature selection framework includes: Calculate the ReliefF weight of each feature, set the number of iterations and the number of neighbors, and evaluate the correlation between features and categories through mutual information; PCA was used for dimensionality reduction, and the principal components with cumulative variance contribution rate ≥ 95% were retained; Construct a multimodal feature fusion space and standardize the spectral reflectance, grayscale co-occurrence matrix texture and morphological structure features; The feature combination is optimized through cross-validation to screen out the optimal feature subset.
7. The method for extracting single trees based on multispectral data according to claim 6, characterized in that: The evaluation of error propagation effects includes: a. Define a set of radiometric correction quality evaluation indicators, including root mean square error, mean absolute error, structural similarity, and spectral angle matching, and evaluate the radiometric fidelity of the corrected spectral data through multi-indicator fusion; b. Construct an error propagation model. Based on error propagation theory, analyze the error contribution of each processing step and quantify the weight of the error in each processing step on the final tree extraction results. The processing steps include atmospheric correction, terrain compensation, and feature fusion. c. Design a cross-validation experiment, divide the multispectral dataset into training, validation, and test sets, and calculate the confidence interval of the error propagation path through Monte Carlo simulation; d. Establish multimodal data fusion rules, standardize and fuse error-verified spectral data with texture and structural features, construct feature space using principal component analysis, and implement hierarchical extraction of single-tree multimodal datasets through K-means clustering; Among them, the error transfer model derives the covariance matrix of the processing link error through the chain rule, and combines sensitivity analysis to determine the key error sources; the multimodal dataset includes multispectral reflectance after radiation correction, grayscale co-occurrence matrix texture parameters and morphological structure characteristics.
8. A single tree extraction system based on multispectral data, characterized in that: The system includes: Radiation Correction Module: This module builds an end-to-end radiation correction system based on a conditional generative adversarial network. Through the collaborative training of an atmospheric parameter generator, a terrain shadow discriminator, and a joint discriminator, it eliminates atmospheric interference and terrain shadows in multispectral data and outputs universal spectral data. Feature fusion and segmentation module: Design a multi-scale attention fusion network to dynamically fuse general spectral data with grayscale co-occurrence matrix texture features to achieve accurate segmentation of individual tree crowns and generate independent individual tree datasets; Geometric correction module: SuperPoint feature detection combined with SuperGlue matching algorithm is used to establish pairs of points with the same name. The interpolation method is dynamically selected based on the complexity of the terrain to correct geometric distortion and form a spatially aligned dataset. Data enhancement module: Builds an attention-enhanced denoising network, combines non-local mean filtering with adaptive median filtering for noise suppression, and enhances target edge features through channel attention and spatial attention mechanisms; Feature selection module: Establishing the ReliefF-PCA feature selection framework, screening the optimal combination of spectral-textural-structural features through mutual information evaluation and principal component analysis; Error assessment module: Build an error transfer assessment model, quantify the error contribution of each processing link, and generate a single tree multimodal dataset after cross-validation.
Citation Information
Patent Citations
Eucalyptus extraction method and device based on hyperspectral data, equipment and medium
CN118823579A
Unmanned aerial vehicle multi-dimensional space area measurement system
CN118602997A
Rock weathering intelligent detection method based on multispectral imaging technology
CN120014371A