Tree species recognition and single tree segmentation method, system, storage medium and terminal
Patent Information
- Application Number
- CN202611417861.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-09-14
- Publication Date
- 2026-10-16
AI Technical Summary
[0009](2)高光谱树种识别多在像素级或预分割冠区进行,缺少与单木分割的耦合,且对近缘树种之间物理上近不可分(可分性达到物理上界)的情形缺乏诚实判定,强行逐种分类导致精度虚高或失败;
[0054] (1) In view of the actual situation that the tree canopies are densely overlapping and difficult to label one tree at a time, the identification of tree species in the whole area can be completed by using only some reliable labels drawn according to the tree canopy, which significantly reduces the reliance on large-scale manual labeling of each tree.
Smart Images

Figure CN122929409A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the technical field of remote sensing information processing, and relates to a method, system, storage medium and terminal for tree species identification and individual tree segmentation. Background Technology
[0002] Forest ecosystems play an irreplaceable role in maintaining ecological balance, protecting biodiversity, and mitigating global climate change. Individual trees are the most basic building blocks of forests, and their structural parameters and species information are key elements for forest resource surveys, accurate carbon storage measurement, and biodiversity assessment. Traditional manual surveys, while relatively accurate, are costly, inefficient, and time-consuming, especially in complex terrains and densely forested mixed forests where large-scale surveys are difficult. In recent years, remote sensing technology, using drones as platforms equipped with lidar and hyperspectral imaging sensors, has developed rapidly, providing new methods for fine-grained forest parameter extraction and tree species identification. However, in dense mixed forest scenarios, how to efficiently achieve individual tree segmentation and simultaneous tree species identification remains a pressing problem to be solved.
[0003] In the field of single-tree segmentation, methods based on LiDAR point clouds have made progress. Traditional methods typically project the point cloud into a canopy height model (CHM), and then use image processing techniques such as watershed segmentation, seed region growth, or graph theory segmentation for canopy segmentation. However, in complex forest stands with severe canopy overlap, oversegmentation or undersegmentation is common. To address this, some studies have proposed algorithms based on multi-order gradients of digital surface models and self-consistency grouping (SCG) based on spectral-texture-color space. Deep learning methods have also been widely adopted: the end-to-end 3D model ITS-Net, TreeisoNet which decomposes segmentation into trunk classification / base localization / trunk clustering / canopy clustering, TLS single-tree segmentation based on supervoxel optimization and shortest path, BFE-Net with boundary feature enhancement and sector constraints, and Tree-Net, a single-stage detection network for UAV LiDAR multi-band rasterized data, etc. In terms of image processing, FM-SAM combines YOLOv10 with the Segment Anything Model (SAM) to achieve tree canopy segmentation and detection in RGB images, while ZS-TreeSeg proposes a zero-shot instance separation framework. However, most of the above studies only focus on geometric morphology segmentation and do not involve tree species identification.
[0004] In the field of tree species identification, hyperspectral imagery, with its rich spectral information provided by dozens to hundreds of continuous narrow bands, has a significant advantage in fine-grained classification. Traditional machine learning methods such as Support Vector Machine (SVM) and Random Forest (RF) are widely used, but they have limitations when dealing with complex nonlinear relationships. Deep learning methods have achieved remarkable results: 3D-CNN, a three-dimensional convolutional network for mining spatial-spectral joint features; Active Learning Sparse Spectral Clustering (ALSSC), which achieves 94.86% accuracy with only 160 samples; SLA-NET; Texture-Aware Self-Attention Model (TASAM); few-shot frameworks that combine band selection with improved 3D prototype networks; and SDTA-3DCNN for mining areas. However, most of these methods operate at the pixel level or on pre-segmented canopy regions, without addressing the automatic segmentation of individual tree canopies, and cannot directly generate tree species distribution maps at the single-tree level.
[0005] To achieve both tree species identification and individual tree segmentation, some studies have fused multi-source data for mixed forests: combining airborne hyperspectral data with LiDAR-CHM, followed by shadow correction, principal component analysis, and crown feature fusion before inputting into SVM, achieving 82% accuracy for 16 tree species; first using LiDAR-CHM watershed segmentation and then extracting the average spectrum within the crown for SVM classification, achieving 85.33% accuracy for 6 classes; combining UAV hyperspectral data with photogrammetric point clouds for northern coniferous forests; the U-SLIC algorithm combining deep learning semantic segmentation and superpixel clustering; combining LiDAR, hyperspectral data, and ultra-high resolution RGB with normalized cut and watershed analysis; the end-to-end fuzzy boundary perception network FBAN; and MLF-TransUNet fusing multispectral and CHM data. However, these studies that achieved good results mostly had favorable conditions: either large tree spacing and clear crown outlines, or limited crown overlap with sufficient ground reference and distinguishable spectra for annotation, or point clouds that could provide relatively complete 3D structure to assist segmentation.
[0006] However, the dense mixed forest scenario is fundamentally different from the above conditions: (1) From the point cloud perspective, the point cloud of the UAV lidar used is mainly the canopy surface and the downward extension of the canopy edge, lacking the canopy and trunk points, and cannot be segmented from bottom to top using the complete three-dimensional structure; at the same time, the canopy width of different tree species varies greatly, larger canopy protrusions may contain multiple trees, and smaller canopy protrusions are easily merged into adjacent large canopies, making it difficult to distinguish them by geometry alone; (2) From the hyperspectral perspective, the canopy layer is highly densely interwoven, and it is difficult to identify the outline of each tree even in images in many areas, making it impossible to manually label all trees, and supervised learning based on a large number of labels is difficult to apply directly.
[0007] In summary, existing tree species identification and individual tree segmentation algorithms in dense mixed forest scenarios have the following problems:
[0008] (1) Watershed / regional growth methods based on CHM rely on complete crown shape and clear crown boundaries. In stands with only crown surface, no trunk / ground point cloud, and large crown width and high interweaving, over-segmentation and under-segmentation are serious.
[0009] (2) Hyperspectral tree species identification is mostly performed at the pixel level or in pre-segmented crown areas, lacking coupling with single tree segmentation. It also lacks honest judgment on cases where closely related tree species are physically inseparable (separability reaches the physical upper limit), and forced classification of each species leads to falsely high accuracy or failure.
[0010] (3) Supervised learning methods rely on sufficient and reliable labeled samples and clearly labeled crowns and boundaries. They are difficult to deploy robustly when full labeling is not possible and the sample size is small. Summary of the Invention
[0011] The purpose of this invention is to provide a method, system, storage medium, and terminal for tree species identification and individual tree segmentation, which accurately achieves tree species identification and individual tree segmentation in dense mixed forests based on hyperspectral imagery and lidar point clouds.
[0012] In a first aspect, the present invention provides a method for tree species identification and individual tree segmentation, the method comprising the following steps: acquiring hyperspectral images and lidar point clouds of mixed forests; constructing canopy masks and canopy superpixels based on the hyperspectral images; performing pixel-by-pixel deillumination processing within the canopy superpixels to construct reflectance base spectrum, shape / derivative base spectrum, and spectral features corresponding to each canopy superpixel; calculating a tree-level Jeffries–Matusita separability matrix based on the spectral features, with the canopy superpixels as units, and obtaining groups composed of physically nearly inseparable tree species; obtaining tree species labels for the canopy superpixels based on the spectral features and the groups; and outputting a spatial distribution map of individual tree species based on the tree species labels, the reflectance base spectrum, the shape / derivative base spectrum, the canopy mask, and the lidar point cloud.
[0013] In one implementation of the first aspect, constructing a canopy mask and canopy superpixels based on the hyperspectral image includes the following steps:
[0014] Based on the principle that five criteria are met simultaneously, a canopy mask is extracted from the hyperspectral image. The five criteria are: normalized vegetation index is greater than a first threshold, normalized red edge index is greater than a second threshold, green / red band ratio is greater than a third threshold, near-infrared / red band ratio is greater than a fourth threshold, and the brightness of the entire band is within a set quantile interval.
[0015] Each pixel of the hyperspectral image is de-luminance normalized, and the luminance spectrum after de-luminance normalization is dimensionality reduced.
[0016] Based on the dimensionality-reduced hyperspectral image, linear iterative clustering superpixel segmentation is performed only within the canopy mask to obtain the canopy superpixels.
[0017] In one implementation of the first aspect, performing pixel-by-pixel deillumination within the canopy superpixel to construct the reflectance basis spectrum, shape / derivative basis spectrum, and spectral features corresponding to each canopy superpixel includes the following steps:
[0018] Select the light-receiving pixel from the canopy superpixels;
[0019] Based on the mean spectrum of the light-receiving pixel, multivariate scattering correction is performed on the light-receiving pixel;
[0020] The reflectance basis spectrum and shape / derivative basis spectrum are obtained from the light-receiving pixels after multivariate scattering correction.
[0021] Spectral features are constructed based on the mean spectrum of the reflectance base spectrum and the shape / derivative base spectrum. The spectral features include two or more of the following: spectral morphology, Savitzky-Golay first / second derivative, vegetation index, piecewise slope, gray-level co-occurrence matrix texture, statistical moments, red edge / absorption scalar, continuum removal of absorption depth / area, advanced red edge features, and piecewise slope ratio.
[0022] In one implementation of the first aspect, calculating the tree-level Jeffries–Matusita separability matrix based on the spectral features, using the canopy superpixels as units, and obtaining the group composed of physically nearly inseparable tree species includes the following steps:
[0023] Grouped by tree and spatial block, the canopy superpixels are subjected to leak-free grouped cross-validation based on the spectral features to obtain the out-of-fold prediction score of the canopy superpixels;
[0024] The median spectrum of each tree is selected as an independent sampling unit. The Jeffries–Matusita distance between any two tree species is calculated, and the corresponding tree-level Jeffries–Matusita separability matrix is used as the upper bound of tree species separability.
[0025] Based on the tree-level Jeffries–Matusita separability matrix and the out-of-place prediction scores, one-to-one and one-to-many permutation tests are performed on the tree species, and test errors are corrected. Based on the connected components of the non-significant edges of the one-to-one permutation test and the edges whose distance from the Jeffries–Matusita is less than a threshold, groups of physically nearly inseparable tree species are obtained.
[0026] In one implementation of the first aspect, obtaining the tree species label of the canopy superpixel based on the spectral features and the group includes the following steps:
[0027] Based on the spectral features, the known tree species spectral envelopes of the canopy superpixels and the minimum Mahalanobis distance to the class mean of all known tree species are obtained. Canopy superpixels whose minimum Mahalanobis distance exceeds a preset quantile threshold are determined to be unknown tree species.
[0028] For canopy superpixels that are not identified as unknown tree species, closely related tree species are merged into macroclasses. Canopy superpixels whose order-preserving calibration probability of the macroclass is not less than the corresponding macroclass threshold are formed into a qualified set. The macroclass with the highest posterior probability in the qualified set is taken as the tree species label corresponding to the canopy superpixel. Macroclasses that do not belong to the qualified set are identified as unknown tree species.
[0029] In one implementation of the first aspect, outputting a spatial distribution map of a single tree species based on the tree species label, the reflectance base spectrum, the shape / derivative base spectrum, the canopy mask, and the lidar point cloud includes the following steps:
[0030] A crown height model is constructed based on the lidar point cloud;
[0031] The crown height model is cross-correlation registered based on the canopy mask;
[0032] Variable-window local maxima seeds are generated based on the crown height model after cross-correlation registration. The crown height model after cross-correlation registration is smoothed proportionally to the crown radius, and maxima regions with a prominence not less than a preset threshold are selected. Peak merging is performed on these maxima regions: two peaks with a peak spacing less than a first proportional threshold are unconditionally merged; two peaks with a peak spacing between the first and second proportional thresholds, belonging to the same spectral cluster, and with a peak saddle depth less than a preset saddle depth threshold are conditionally merged to obtain the effective peak seeds corresponding to the merged regions. For spectral clusters without geometric peaks, seeds are only planted within connected blocks with an area not less than a set multiple of the crown area, and the total number of seeds within the connected blocks is constrained to not exceed a preset multiple of the ratio of the connected block area to the crown area to obtain the variable-window local maxima seeds.
[0033] The spectral angle is calculated based on the reflectance base spectrum and the shape / derivative base spectrum. A heterogeneous wall is constructed based on the spectral angle, and the superpixel adjacency edge weight is calculated.
[0034] A fusion cost surface is constructed based on the spectral angle and the heterogeneous wall, and a controlled watershed is segmented on the fusion cost surface to obtain canopy segmentation objects;
[0035] The canopy segmentation region is corrected based on the pixel adjacency edge weights. Fragments with an area smaller than a set multiple of the canopy area are merged into the adjacent region with the lowest average cost of the shared boundary. For regions that meet the conditions of low average cost of the shared boundary, merged region not exceeding the upper limit of the canopy scale, and shallow saddle between regions, weak boundary merging is performed. For multi-tree regions where there are neither topographic saddles nor spectral dividing walls between adjacent trees, no forced segmentation is performed. Instead, multi-tree regions are marked and the estimated number of trees in the region is output.
[0036] Assign a corresponding tree species label to each corrected canopy segmentation region and output the spatial distribution map of the individual tree species.
[0037] In one implementation of the first aspect, constructing a crown height model based on the lidar point cloud includes the following steps:
[0038] The lidar point cloud is projected onto the same grid coordinate system as the hyperspectral image, and the elevation of each grid is taken to complete the point cloud rasterization.
[0039] Within the canopy mask area only, the grid holes inside the canopy mask formed by the lack of point cloud are sequentially processed by nearest neighbor filling and closing operations to complete the annular hollow canopy structure into a solid mound structure and obtain the initial canopy height model.
[0040] Perform a non-depression grayscale closing operation on the initial crown height model, and then perform pixel-by-pixel processing on the closing operation result and the initial crown height model to fill the pits inside the crown and obtain a non-depression crown height model.
[0041] The non-concave crown height model is subjected to dual-scale Gaussian smoothing to generate a sharp crown height model and a smooth crown height model; wherein, the sharp crown height model is obtained by minimal-scale smoothing, and the smooth crown height model is obtained by Gaussian smoothing according to a scale proportional to the crown radius of the tree species.
[0042] Secondly, the present invention provides a tree species identification and single tree segmentation system, the system comprising a first acquisition module, a construction module, a processing module, a calculation module, a second acquisition module, and a generation module;
[0043] The first acquisition module is used to acquire hyperspectral images and lidar point clouds of mixed forests;
[0044] The construction module is used to construct a canopy mask and canopy superpixels based on the hyperspectral image;
[0045] The processing module is used to perform pixel-by-pixel illumination removal processing within the canopy superpixel, and to construct the reflectance basis spectrum, shape / derivative basis spectrum and spectral features corresponding to each canopy superpixel;
[0046] The calculation module is used to calculate the tree-level Jeffries–Matusita separability matrix based on the spectral features, using the canopy superpixels as units, and to obtain the group composed of physically nearly inseparable tree species;
[0047] The second acquisition module is used to acquire the tree species label of the canopy superpixel based on the spectral features and the group;
[0048] The generation module is used to output a spatial distribution map of a single tree species based on the tree species label, the reflectance base spectrum, the shape / derivative base spectrum, the canopy mask, and the lidar point cloud.
[0049] Thirdly, the present invention provides a terminal, the terminal comprising: a processor and a memory;
[0050] The memory is used to store computer programs;
[0051] The processor is used to execute the computer program stored in the memory, so that the terminal performs the above-described tree species identification and single-tree segmentation methods.
[0052] Fourthly, the present invention provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a terminal, implements the above-described tree species identification and single-tree segmentation methods.
[0053] As described above, the tree species identification and individual tree segmentation method, system, storage medium, and terminal of the present invention have the following beneficial effects:
[0054] (1) In view of the actual situation that the tree canopies are densely overlapping and difficult to label one tree at a time, the identification of tree species in the whole area can be completed by using only some reliable labels drawn according to the tree canopy, which significantly reduces the reliance on large-scale manual labeling of each tree.
[0055] (2) Under the condition that the point cloud only contains the canopy surface and lacks trunk points, the single tree segmentation of the continuous interwoven canopy is realized, and the resistance to over-segmentation and under-segmentation is taken into account for adjacent tree canopies with large size differences.
[0056] (3) Suppress heterospectrism caused by differences in light intensity between the shaded and sunny sides of the canopy, and improve the separability and identification stability of closely related tree species;
[0057] (4) Eliminate spatial autocorrelation leakage of adjacent trees of the same species in model evaluation and threshold calibration, so that the identification accuracy conclusion is true and reliable, and has the ability to reject unknown (unseen) tree species. Attached Figure Description
[0058] Figure 1 The flowchart shown is an embodiment of the tree species identification and single tree segmentation method of the present invention;
[0059] Figure 2 The diagram shown is a structural schematic of the tree species identification and single-tree segmentation system of the present invention in one embodiment.
[0060] Figure 3 The diagram shown is a structural schematic of the terminal of the present invention in one embodiment. Detailed Implementation
[0061] The following specific examples illustrate the implementation of the present invention. Those skilled in the art can easily understand other advantages and effects of the present invention from the content disclosed in this specification. The present invention can also be implemented or applied through other different specific embodiments, and various details in this specification can also be modified or changed based on different viewpoints and applications without departing from the spirit of the present invention. It should be noted that, unless otherwise specified, the following embodiments and features described therein can be combined with each other.
[0062] It should be noted that the illustrations provided in the following embodiments are only schematic representations of the basic concept of the present invention. Therefore, the drawings only show the components related to the present invention and are not drawn according to the actual number, shape and size of the components in the actual implementation. In the actual implementation, the form, quantity and proportion of each component can be arbitrarily changed, and the layout of the components may also be more complex.
[0063] Furthermore, in this invention, descriptions involving "first," "second," etc., are for descriptive purposes only and should not be construed as indicating or implying their relative importance or implicitly specifying the number of technical features indicated. Therefore, a feature defined with "first" or "second" may explicitly or implicitly include at least one of that feature. Additionally, the technical solutions of the various embodiments can be combined with each other, but only on the basis of being achievable by those skilled in the art. When the combination of technical solutions is contradictory or impossible to implement, such a combination of technical solutions should be considered non-existent and not within the scope of protection claimed by this invention.
[0064] The tree species identification and individual tree segmentation method, system, storage medium, and terminal of this invention characterize and objectively define the separability boundaries of tree species in dense canopies using "canopy superpixels + pixel-by-pixel illumination removal + multiple features + leak-free separability analysis"; ② achieve countable deployment of tree species identification under weak labeling and unknown species conditions using "hierarchical multi-classification + open set rejection + species-by-species path selection + count-level base rate correction"; ③ achieve individual tree segmentation by coordinating geometry and spectroscopy on the same cost surface using "CHM reconstruction under incomplete point cloud conditions + variable window local maximum seed + spectral angle heterogeneous wall + fusion cost surface controlled watershed", enabling separable segmentation of heterogeneous species of the same height and restraining oversegmentation of adjacent canopies of the same species.
[0065] like Figure 1 As shown, in one embodiment, the tree species identification and single tree segmentation method of the present invention includes steps S1-S6.
[0066] Step S1: Acquire hyperspectral images and lidar point clouds of the mixed forest.
[0067] Specifically, the system uses a drone to simultaneously collect hyperspectral images and lidar point clouds of mixed forests, and inputs these images and point clouds into the tree species identification and individual tree segmentation terminal of this invention. The hyperspectral images and lidar point clouds are hyperspectral images and lidar point clouds from the same region and coordinate system (same grid and affine transformation) that have had their ground points removed and elevation normalized.
[0068] Step S2: Construct a canopy mask and canopy superpixels based on the hyperspectral image.
[0069] Specifically, constructing a canopy mask and canopy superpixels based on the hyperspectral image includes the following steps:
[0070] 21) Based on the principle that five criteria are met simultaneously, a canopy mask is extracted from the hyperspectral image, wherein the five criteria are: normalized vegetation index greater than the first threshold, normalized red edge index greater than the second threshold, green / red band ratio greater than the third threshold, near-infrared / red band ratio greater than the fourth threshold, and full-band brightness located in the set quantile interval.
[0071] Specifically, a canopy mask is extracted from the hyperspectral image when the following five criteria are met simultaneously: Normalized Difference Vegetation Index (NDVI) > 0.55, Normalized Difference Red Edge Index (NDRE) > 0.15, Green / Red Band Ratio > 1.05, Near-Infrared / Red Band Ratio > 1.5, and the brightness across all bands is between the 3rd and 98th percentiles. ; In the formula, ρ_NIR, ρ_R, and ρ_RE represent the reflectance in the near-infrared (approximately 800 nm), red (approximately 670 nm), and red-edge (approximately 705 nm) bands, respectively. The function of the canopy mask is to exclude non-canopy pixels such as ground, grass, waterways, and strong shadows from the canopy edge, ensuring that subsequent processing only occurs on the effective canopy.
[0072] Preferably, fragments with an area of less than 30 pixels are removed (the area threshold in pixels is determined based on the spatial resolution of the hyperspectral image; in this embodiment, the spatial resolution is approximately 0.08m).
[0073] 22) Perform brightness normalization on each pixel of the hyperspectral image, and reduce the dimensionality of the brightness spectrum after brightness normalization.
[0074] First, brightness normalization is performed on each pixel, i.e., each pixel is divided by its full-band mean ρ′(λ) = ρ(λ) / mean_λ[ρ(λ)], to suppress multiplicative illumination differences caused by eccentricity. Then, the brightness spectrum after brightness normalization is subjected to dimensionality reduction. In this invention, principal component analysis (PCA) is used for dimensionality reduction. The 2nd to 5th principal components (PC2 to PC5, skipping PC1 which is approximately brightness) are selected, and each channel is linearly stretched to [0,1] according to the 1st to 99th quantiles. This serves to preserve the shape information required for interspecies discrimination while suppressing illumination and reducing dimensionality. Alternatively, minimum noise separation can be used to replace the principal component analysis for dimensionality reduction.
[0075] 23) Based on the dimensionality-reduced hyperspectral image, linear iterative clustering superpixel segmentation is performed only within the canopy mask to obtain the canopy superpixels.
[0076] For the dimensionality-reduced hyperspectral image, Simple Linear Iterative Clustering (SLIC) superpixel segmentation is performed only within the canopy mask. The target superpixel count is set to 20,000, the compactness to 10, the smoothness coefficient σ to 1.0, forced connectivity, and the minimum size factor to 0.25. It should be noted that the target superpixel count is determined based on the total number of pixels and spatial resolution of the hyperspectral image. In this embodiment, the complete image contains approximately 1.49 million original pixels with a resolution of 0.08m. After removing the ground, grass, river channels, and edge shadows, segmentation is performed within the remaining canopy area, ultimately extracting approximately 20,000 superpixels. The scale of each superpixel is matched to the canopy size (the higher the spatial resolution and the more pixels per unit area, the greater the target superpixel count is proportionally increased). This step divides the dense canopy into approximately 20,000 homogeneous patches that are "uniform in size, internally homogeneous, and have closely aligned boundaries," serving as the basic unit for subsequent feature analysis, tree species identification, and individual tree segmentation. Replacing individual pixels with superpixels can suppress pixel-by-pixel noise and provide natural spatial regularization.
[0077] Step S3: Perform pixel-by-pixel deillumination within the canopy superpixel to construct the reflectance basis spectrum, shape / derivative basis spectrum, and spectral features corresponding to each canopy superpixel.
[0078] Specifically, performing pixel-by-pixel illumination removal within the canopy superpixel to construct the reflectance basis spectrum, shape / derivative basis spectrum, and spectral features corresponding to each canopy superpixel includes the following steps:
[0079] 31) Select the light-receiving pixel in the canopy superpixel.
[0080] Among them, the yin and yang sides within the coronal layer are local effects at the pixel level, so pixel-by-pixel processing is required before aggregation into superpixel averages. For each coronal superpixel, the brightest pre-defined ratio of pixels in the near-infrared band (approximately 800nm) is first selected, for example, 50% of the pixels; if a superpixel's pixel value is lower than the set value, all pixels are selected to eliminate yin side pixels.
[0081] For example, the hyperspectral image is set to have B bands (B=206 in this embodiment), and the set of pixels covered by the s-th canopy superpixel is... The original surface reflectance spectrum of pixel i is λ=1,…,B. Take the superpixels of the canopy. The reflectance of all pixels in the near-infrared band (approximately 800 nm) is the [missing information]. quantiles are thresholds f is the light-receiving ratio (in this embodiment, f=0.5, i.e., the brightest 50% of pixels within the superpixel), and the set of light-receiving pixels is... When the number of pixels in the canopy superpixel is less than a set value (8 in this embodiment), then... = That is, all pixels are involved to avoid unstable quantile estimation due to too few samples.
[0082] 32) Using the mean spectrum of the light-receiving pixel as a reference, perform multivariate scattering correction on the light-receiving pixel.
[0083] Among these, multiplicative scattering correction (MSC) is performed on the light-receiving pixels, that is, the mean spectrum of the light-receiving pixels is used as the reference spectrum. For each pixel spectrum Linear fitting Corrected pixel spectrum .
[0084] For example, the mean spectrum of all illuminated pixels within the canopy superpixel. As a reference spectrum .in This is the union of all illuminated pixels in the canopy superpixels. The mean spectrum of the global illuminated pixels, rather than the mean spectrum of each individual superpixel, is used as the benchmark. This is to ensure that the correction results of different canopy superpixels fall on the same reflectance scale and can be directly compared. If each canopy superpixel uses its own benchmark, the brightness differences between species will also be erased.
[0085] For each illuminated pixel i, its spectrum For the reference spectrum Perform least squares linear fitting Its closed-form solution is: In the formula These are the mean values of the spectrum of this pixel and the reference spectrum along the band direction, respectively. It is a multiplicative factor (corresponding to the overall brightness scaling caused by the sun-shaded side, slope aspect, and scattering). This is an additive bias (corresponding to skylight and path radiation). The corrected pixel spectrum is: Since the additive term is subtracted first and then the multiplicative term is divided, the correction can remove both multiplicative and additive illumination effects at the same time, and the correction result is still a positive reflectance scale.
[0086] 33) Obtain the reflectance spectrum and shape / derivative spectrum based on the received image after multivariate scattering correction.
[0087] Specifically, the MSC simultaneously removes both multiplicative and additive (skylight) illumination while maintaining a positive reflectance scale. This generates two mean spectra for each superpixel: a reflectance basis spectrum ms_refl (used by reflectance / ratio / position features A, C, D, G, H, I, J) and a shape / derivative basis spectrum ms_shape (used by derivative family B; since the derivative amplitude scales with brightness, brightness normalization is required before illumination resistance). Through this design of "light selection + MSC + feature family-based distribution," the local effect of the shaded / lit surfaces is eliminated before averaging, and each feature family remains physically effective after illumination removal. This is one of the key inventive points that distinguishes this invention from directly averaging the spectrum of the canopy region.
[0088] For the s-th canopy superpixel, take the average of the correction spectra of all its illuminated pixels: This fundamental spectrum maintains a positive reflectance scale, which can be used by reflectance / ratio / location-based feature families (in this embodiment, families A, C, D, G and the supplementary families H, I, J).
[0089] In this invention, ms_shape is defined as the result of first normalizing the shape of the illuminated pixel and then taking the superpixel mean, i.e. ,in This represents the pixel spectrum after shape normalization. In this embodiment, the shape normalization operator is the multivariate scattering correction itself, i.e. ,thus This is because multivariate scattering correction normalizes the spectral shape while removing multiplicative and additive illumination, allowing the derivative family to be calculated directly. As an alternative implementation, shape normalization can also be achieved using the Standard Normal Variation (SNV): ,in This is the standard deviation of the pixel's spectrum along the band direction; at this time It is a spectrum with zero mean, unit variance, and can contain negative values, which is numerically different from ms_refl.
[0090] In this invention, the two types of features have different physical requirements for the fundamental spectrum: features such as reflectance, band ratio, absorption depth, vegetation index, and red edge position must be based on a spectrum that maintains a positive reflectance scale to have physical meaning, hence ms_refl is used; while the amplitude of the derivative family scales linearly with brightness and must be normalized to brightness to have anti-illuminance capability, hence ms_shape is used. If the two types of features share a fundamental spectrum, one of them will inevitably lose its physical validity or anti-illuminance capability, which is the design reason for the "feature family splitting" step in this invention. In addition to the two fundamental spectra mentioned above, each canopy superpixel also retains a full-pixel original mean spectrum without any anti-illuminance processing. This spectrum does not participate in the construction of any spectral features; it is only used for brightness and deep shadow determination. Because the brightness information has been erased after illumination removal, it is no longer possible to determine whether a superpixel is generally too dark. Based on this, extremely dark superpixels with substandard signal-to-noise ratios can be eliminated (in this embodiment, the darkest approximately 1% of near-infrared superpixels are eliminated).
[0091] 34) Construct spectral features based on the mean spectrum of the reflectance base spectrum and the shape / derivative base spectrum. The spectral features include two or more of the following: spectral morphology, Savitzky-Golay first / second derivative, vegetation index, piecewise slope, gray-level co-occurrence matrix texture, statistical moments, red edge / absorption scalar, continuum removal of absorption depth / area, advanced red edge features, and piecewise slope ratio.
[0092] Specifically, a variety of redundant features (approximately 148) are constructed on the superpixel mean spectrum, including: spectral morphology (reflectance, continuum CR removal, NDVI residual), Savitzky-Golay first / second derivative, vegetation index, piecewise slope, gray-level co-occurrence matrix (GLCM) texture, statistical moments, red-edge / absorption scalars (such as red-edge inflection point position REIP), continuum absorption depth / area removal, advanced red-edge features (second-order zero-crossing wavelength, red-edge area, symmetry), and piecewise slope ratio (bounded angle ratio immune to multiplicative bias). These spectral features characterize subtle spectral differences among tree species from multiple perspectives, providing a feature space for subsequent separability analysis and classification.
[0093] Specifically, the feature families constructed on the reflectance base spectrum ms_refl are: A (spectral morphology: continuum excluding CR, etc.), C (vegetation index), D (piecewise slope, absorption depth, band ratio, band area, curvature), G (red edge / absorption scalar, such as red edge inflection point REIP), H (continuum excluding absorption depth / area), I (higher-order red edge features: second derivative zero-crossing wavelength, red edge area, symmetry), and J (piecewise slope ratio). These features all depend on a positive reflectance scale or inter-band ratio, and therefore must be built on ms_refl that maintains a positive reflectance scale.
[0094] A family of features, B (Savitzky–Golay first derivative B1 and second derivative B2), is constructed on the shape / derivative base spectrum ms_shape. The magnitude of the derivatives scales linearly with brightness and must be calculated on a shape base spectrum that has been normalized to brightness to achieve anti-illuminance capability.
[0095] The optional feature families of the two fundamental spectra mentioned above are not used: gray-level co-occurrence matrix texture (E) and statistical moments (F). Texture and statistical moments are essentially spatial statistics between pixels and cannot be defined on a one-dimensional mean spectrum. Therefore, if enabled, they are calculated spatially on the original image pixels covered by the superpixel. In this embodiment, these two families are not enabled (see the dimension caliber below).
[0096] The spectrum that does not participate in feature construction: the raw mean spectrum ms_raw. It is only used for brightness and deep shadow determination and does not enter any feature set.
[0097] It should be noted that the 148 features used in this embodiment refer to the number of effective independent features after redundancy removal. The formation process involves three steps: First, the original features are constructed from the two basis spectra mentioned above, with the following dimensions for each family: A3 (continuum removal) 52 dimensions, B1 (first derivative) 52 dimensions, B2 (second derivative) 52 dimensions, C (vegetation index) 34 dimensions, D (piecewise slope and absorption) 18 dimensions, G (red-edge scalar) 5 dimensions, H (continuum removal absorption) 6 dimensions, I (higher-order red-edge) 7 dimensions, and J (piecewise slope ratio) 10 dimensions. The first step involves removing the A1 (original reflectance, 52-dimensional) cluster, which carries absolute brightness, and the A2 (L2 normalized, 52-dimensional) cluster, which is redundant after pixel-by-pixel normalization, to avoid introducing brightness / illuminance differences as inter-species differences (the E and F clusters are not enabled in this embodiment and are 0-dimensional), thus retaining the aforementioned 236 dimensions. The second step involves performing simple connected clustering on these 236 dimensions to remove redundancy based on the absolute value of the Pearson correlation coefficient being greater than 0.95. Only one representative feature is taken from each redundant cluster, resulting in 148 effective independent features. The subsequent discrimination and separability analysis in step S4, and the one-to-many discrimination and open set spectral envelope construction in step S5 of the macroclass layer, all use these 148 effective independent features as input (in this embodiment, all 148 independent features are used in the macroclass layer for each multi-member macroclass, instead of the sparse first k features, so as not to underestimate its separability; only for a single macroclass with extremely sparse samples, such as *Bischofia javanica*, its dedicated sparse feature subset is used, which is 10 in this embodiment).
[0098] Step S4: Based on the spectral features, calculate the tree-level Jeffries–Matusita separability matrix using the canopy superpixels as units, and obtain the group composed of physically nearly inseparable tree species.
[0099] Specifically, before formally identifying tree species, this step objectively defines the separability boundaries of tree species under data conditions, honestly classifying the tree species involved in the analysis into three categories: "identifiable species-by-species," "identifiable only by group (must be geometrically segmented by point cloud in S6)," and "physically inseparable." This provides a reliable classification system for the subsequent process and avoids the possibility of artificially high accuracy or classification failure caused by forcibly classifying closely related tree species species one by one.
[0100] In one embodiment, the process of calculating the tree-level Jeffries–Matusita separability matrix based on the spectral features, using the canopy superpixels as units, and obtaining the group of physically nearly inseparable tree species includes the following steps:
[0101] 41) Grouping the canopy superpixels by tree and spatial block, perform leak-free grouped cross-validation on the canopy superpixels based on the spectral features to obtain the out-of-fold prediction score of the canopy superpixels.
[0102] In this process, the canopy superpixels are used as the analysis unit, and trees (labeled crown polygons) and spatial blocks (minimum side length of about 15m) are grouped to ensure that all superpixels of the same tree must enter the same fold. Feature selection, standardization and classifier are fitted only within the training fold, and each superpixel is predicted only once (out-of-fold prediction, OOF). The evaluation index is statistically analyzed at the tree level (the median score of each tree's superpixels is taken), and the lower bound of the tree-level self-help confidence interval (CI) is used as the decision gate. Its function is to eliminate the optimistic bias caused by the false repetition of superpixels in the same tree.
[0103] 42) Select the median spectrum of each tree as an independent sampling unit, calculate the Jeffries–Matusita distance between any two tree species, and use the corresponding tree-level Jeffries–Matusita separability matrix as the upper bound of tree species separability.
[0104] In this approach, the median spectrum of each tree is taken as an independent sampling unit. The Ledoit-Wolf shrinkage covariance estimation is used to calculate the JM distance between each pair of tree species as an upper bound for separability independent of the model. , 0≤JM≤2. Where B is the Bhattacharyya distance between the two tree species in the feature space; the closer JM is to 2, the more separable they are, and JM≤1 indicates that they are physically nearly inseparable. The JM matrix is used to verify whether the classifier's conclusion is consistent with physical separability.
[0105] The Jeffries–Matusita tree-level separability matrix is a K×K symmetric matrix M formed by arranging the tree-level distances JM between each pair of all K tree species, where the elements M(i,j) = JM(i,j) and the diagonal elements M(i,i) = 0.
[0106] For each tree, the median of all canopy superpixel spectral features is taken as the unique independent sampling unit for that tree (the median is used to resist the influence of canopy edge pixels and residual shadow pixels); after standardizing all sampling units, principal component analysis is used to reduce the dimension to d (d is the smaller of 10 and "the number of trees of the minimum tree species minus 1" to ensure that the covariance can still be stably estimated when the number of tree-level samples is small); the mean of each tree species is estimated using Ledoit-Wolf shrinkage. With covariance ;make ,but , .
[0107] JM > 1.90 is defined as highly separable; 1.70 < JM ≤ 1.90 is separable; and 1.00 < JM ≤ 1.70 is partially confusing. When constructing groups, edges with JM < 1.70 are all considered difficult to separate and connected; JM ≤ 1.00 is physically nearly inseparable. In this embodiment, the tree-level JM of pond cypress and slash pine is less than 1.00 (the pairwise tree-level AUC is only 0.751), which is physically nearly inseparable and must be separated within the group by point cloud geometry; the tree-level JM of closely related pairs such as goldenrain tree and oak, soapberry and camphor tree fall in the partially confusing range of 1.00 to 1.70, and are therefore conservatively merged into a multi-member macroclass, but their members can still be reliably separated species by species under the discriminator (the pairwise tree-level AUCs are 0.963 and 0.983, respectively), so they are ultimately identified as single species.
[0108] It should be noted that all determinations in this invention use the tree-level JM distance, meaning that the median spectrum of each tree is taken as an independent sampling unit. This is because dozens of superpixels of the same tree are pseudo-repetitions; if superpixels are used as independent sampling units, the separability will be systematically overestimated. In this embodiment, the average JM distance at the superpixel level is 1.661, while the average JM distance at the tree level is only 1.201, a difference of 0.460. Furthermore, the conclusion at the superpixel level contradicts the conclusion of the leak-free one-to-one permutation test. Therefore, the superpixel-level JM matrix is only used for visual comparison and does not participate in any determination; unless otherwise specified in the claims and specification, the JM distance and JM separability matrix refer to the tree-level range.
[0109] 43) Based on the tree-level Jeffries–Matusita separability matrix and the out-of-place prediction score, perform one-to-one and one-to-many permutation tests on the tree species respectively, and correct the test errors; based on the connected components of the non-significant edges of the one-to-one permutation test and the edges whose distance from Jeffries–Matusita is less than the threshold, obtain the group composed of physically nearly inseparable tree species.
[0110] Specifically, 500 permutation tests were performed on both one-to-many (OvR) and one-to-one (OvO) discriminations to provide accurate one-sided p-values, which were then corrected for false discovery rate (FDR) using the Benjamini-Hochberg (BH) method. Based on the connected components of non-significant edges in OvO and edges with a distance below a threshold from the JM (Joint Model), "groups" (inseparable individually, but the group as a whole can be separated from the others) were automatically constructed. A mixed lighting test was performed to ensure that the stable features used for discrimination were not encoding lighting. This step honestly distinguishes between three cases: "identifiable individually," "identifiable only by group (intersection geometry)," and "physically inseparable," which is crucial to avoiding inflated accuracy.
[0111] Step S5: Obtain the tree species label of the canopy superpixel based on the spectral features and the group.
[0112] The unknown tree species defined in this invention include two scenarios: the first is a new tree species that has never appeared in the training set, which is identified through open set anomaly rejection; the second is canopy superpixels that are discarded due to insufficient model confidence, which are obtained through joint decision-making. The identification mechanisms and physical meanings of the two types of unknown tree species are different, but the final output results are uniformly labeled as unknown tree species.
[0113] Specifically, the hierarchical multi-class tree species identification based on the group includes the following steps:
[0114] 51) Based on the spectral features, obtain the known tree species spectral envelope of the canopy superpixel and the minimum Mahalanobis distance to the class mean of all known tree species, and determine the canopy superpixel with the minimum Mahalanobis distance exceeding the preset quantile threshold as an unknown tree species.
[0115] First, the spectral envelopes of known tree species are constructed. This involves acquiring the spectral features corresponding to all labeled canopy superpixels, standardizing them based on training set statistics, and then performing principal component analysis for dimensionality reduction. This embodiment selects the first 25 principal components. Within the principal component subspace, the class mean for each known tree species k is calculated. Then, the Ledoit-Wolf shrinkage estimation is used to solve for the population covariance matrix for all labeled samples, and the inverse of this covariance matrix is obtained. As a distance metric matrix. Consists of the class mean set. With the inverse covariance matrix Together they form the spectral envelope of known tree species.
[0116] For any canopy superpixel This includes all unlabeled candidate superpixels, and their feature vectors are normalized and subjected to principal component transformation identical to that of the training set to obtain the feature vectors. Calculate the Mahalanobis distance from this feature to the mean of each known tree species, and take the minimum value. The calculation formula is as follows:
[0117] .
[0118] The technical meaning of taking the minimum distance is: as long as the current superpixel is sufficiently close to the features of any known tree species, it will not be judged as an unknown tree species.
[0119] The outlier 'd' of all labeled canopy superpixels is calculated, and its 99th quantile (P99) is set as the open set rejection threshold. In this embodiment, the measured threshold is approximately 9.56. The design consideration for selecting the 99th quantile is to allow approximately 1% of known species superpixels to falsely reject the detection, thereby ensuring the detection capability for new tree species outside the training set. This quantile can be flexibly adjusted according to the tolerance for missed detections and false rejections in the business scenario. The lower the selected quantile value, the stricter the open set rejection judgment condition.
[0120] When superpixels satisfy If the superpixel is identified as a truly unknown tree species and rejected, it will no longer participate in any subsequent identification process for known tree species or macroclasses. In this embodiment, among the 14,619 candidate canopy superpixels, a total of 187 superpixels were identified as truly unknown tree species by this rule.
[0121] 52) For canopy superpixels that are not identified as unknown tree species, merge closely related tree species into macroclasses, form a qualified set of canopy superpixels whose order-preserving calibration probability of macroclasses is not less than the corresponding macroclass threshold, take the macroclass with the largest posterior probability in the qualified set as the tree species label corresponding to the canopy superpixel, and identify macroclasses that do not belong to the qualified set as unknown tree species.
[0122] In this process, based on the groups obtained in step 43), closely related and inseparable tree species are merged into "macroclasses," resulting in several single-species macroclasses, multi-member macroclasses, and a "rare / unknown (all-purpose) macroclass." An OvR discriminator is trained for each macroclass (by default, a linear classifier with all redundant independent features removed and L2 regularization is used; when the discrimination signal is distributed, full features are used instead of sparse top-k to avoid underestimating separability; sparse top-k can also be used). After obtaining the outlier score through leak-free cross-validation, isotonic (order-preserving) regression is used to calibrate the probability, and a threshold τ_k is calibrated for each macroclass according to a tree-level accuracy target (e.g., 0.80). Finally, a joint decision is made: the eligible set eligible = {macroclasses satisfying P_k ≥ τ_k}, and the macroclass with the highest posterior probability (argmax) is taken as the macroclass label for that superpixel. If there is no eligible macroclass or it is rejected by OOD, it is judged as an unknown tree species. This "single joint decision" does not depend on the stripping order, avoiding instability caused by order arbitration.
[0123] It should be noted that the aforementioned 148 effective independent features are a "feature pool to be selected," not that every discriminator must use all of them. The macroclass layer uses all 148 features to avoid underestimating the separability of closely related macroclasses; however, in the finalization stage for each tree species, a separate feature budget k (hereinafter referred to as top-k) is set for each target tree species, and only the top k features with the strongest discrimination signals for that tree species are used for discrimination. The determination method is as follows: ① Candidate budget grid—For each target tree species, in k∈{5, 8, 10, 20, 30, 40, 50, 60, 80, 100, 127, ① Trial calculations were performed on a grid of 148; ② Leakage-free intra-feature selection—for each k value, the ranking of feature importance and the selection of the top k features were only completed within the training interval. The verification interval did not participate in the ranking, so no feature selection leakage was introduced; at the same time, a quota limit was imposed on each feature family to avoid a certain family (such as the derivative family) monopolizing the entire budget; ③ Optimization criterion—under the premise of ensuring that the whole plot tree-level accuracy target of 0.80 is achieved, the minimum k corresponding to the inflection point after the recall rate increases with k and enters the platform is taken as the deployment budget k* for that tree species. If the recall of the platform is more than 0.1 lower than that of the full features (k=148), it will fall back to the full features; ④ For tree species with extremely sparse samples (in this embodiment, it is *Bischofia javanica*), they are not involved in the above k scan, but their dedicated sparse feature subset is used directly. The budget k* selected for the eight tree species that can be identified individually in this embodiment, the number of features actually used after deduplication of the intra-feature selection union, and the extra-feature tree-level AUC under this budget are shown in Table 1. It should be noted that k* is the "budget" rather than the "final number of features". The selection within each fold is not exactly the same, so the actual number of features used after deduplication of the union is slightly more than k*.
[0124] Table 1. Species-specific characteristic budgets and out-of-class AUCs for eight tree species
[0125] The technical significance of setting feature budgets for each tree species in this invention is as follows:
[0126] First, the distribution patterns of the discrimination signals of different tree species in the feature space are different: the discrimination signal of *Bischofia javanica* is highly concentrated in a few features such as curvature and first / second derivatives, anthocyanin reflectance index and green / red slope ratio near the green peak. A sparse subset is sufficient, and adding more features will only introduce noise; while the discrimination signal of *Koelreuteria bipinnata* is distributed. The budget must be expanded to 127 before its out-of-fold tree-level AUC increases from about 0.87 to 0.979. Forcibly compressing the budget will underestimate its separability.
[0127] Secondly, given the limited number of labeled trees (10-80 labeled trees for the eight target species in this embodiment), reducing the budget to the size that the tree species truly needs can significantly reduce the risk of overfitting under small sample sizes. In this embodiment, only 20, 30, 50, and 80 budgets were used for Quercus acutissima, Ligustrum lucidum, Sapindus mukorossi, and Cornus officinalis, respectively, and their out-of-budget tree-level AUC has reached or even slightly exceeded the results under full feature (148).
[0128] Third, the tree species feature budget, tree species-specific routing (direct / chained), and typicality gate are jointly determined within the same leak-free evaluation chain. Therefore, the accuracy and recall reported by each tree species are honest results "under its deployment budget," rather than optimistic values under all features. It should be noted that the tree species-specific top-k is only a preferred method of using the feature pool in this embodiment and does not change the feature construction and discrimination process defined in the claims.
[0129] In addition, for superpixels falling into multi-member macroclasses, the score_<tree species> within the group is calculated again, and the pairwise tree-level AUC within the group is reported (honestly showing that closely related species are nearly inseparable spectrally, JM<1), as a priori for subsequent point cloud geometric segmentation. For each tree species, accessibility recall is selected between the direct and cascaded paths. For tree species limited by abundance, a typicality gate is applied, and the baseline of the whole plot is used for count-level precision correction.
[0130] In this process, two paths are compared for each target tree species—direct OvR and chained (pre-filtering before discrimination). The optimal path is selected based on the recall achievable under the overall plot accuracy target (direct is suitable for tree species whose confusion objects are outside the macro group and are not rare, while chained is suitable for rare species or tree species confused within the group). A feature budget top-k is set for each target tree species, and only the top k features with the strongest discrimination signal of the tree species are selected for discrimination. k is selected on the candidate grid according to the "inflection point of the recall platform under the premise of achieving the accuracy target". The sorting and selection of the top k features are completed only within the training cycle (in this embodiment, the special sparse feature subset of Chinese tallow tree is used, and the values of camphor tree, glossy bark oak, oak, Chinese tallow tree, soapberry, privet, and goldenrain tree are 80, 80, 20, 30, 50, 30, and 127 respectively). For sparse tree species or those limited by abundance base rate, a "typicality gate" is added. This gate identifies high-resolution points outside the training positive class spectral envelope (Gaussian + Mahalanobis distance) as false positives and removes them, thus eliminating false positives with minimal loss of true positives. Macroclasses that can be determined individually directly output individual tree species labels, while macroclasses that are spectrally inseparable carry intra-group priors for geometric segmentation.
[0131] To convert "labeled subset precision" to "whole-plot deployment precision," the true abundance base rate from a whole-plot manual survey is used for bias correction. Let P_X be the true proportion of a certain species in the whole plot, P_total be the total proportion of trees in the whole plot, TPR be the true positive rate at the tree level, and FPR_tree be the false positive rate at the tree level. Then the corrected deployment precision is: Based on this, a threshold scan is performed, reporting the threshold required to achieve a given deployment accuracy (e.g., 0.80 / 0.90) and the corresponding recall. The open-set self-contamination rate (used for background correction of unknown species) is estimated using a survey-driven formula. .
[0132] Step S6: Based on the tree species label, the reflectance base spectrum, the shape / derivative base spectrum, the canopy mask, and the lidar point cloud, output a spatial distribution map of a single tree species.
[0133] Specifically, based on the tree species label, the reflectance base spectrum, the shape / derivative base spectrum, the canopy mask, and the lidar point cloud, outputting a spatial distribution map of a single tree species includes the following steps:
[0134] 61) Construct a crown height model based on the lidar point cloud.
[0135] The process involves projecting the lidar point cloud onto the same grid coordinate system as the hyperspectral image, and performing elevation maximization (taking the 97th percentile elevation) on each grid cell to rasterize the point cloud. Within the canopy mask area only, nearest neighbor filling and closing operations are sequentially performed on the grid holes formed by missing point clouds within the canopy mask to complete the annular hollow canopy structure into a solid mound structure, obtaining an initial canopy height model. A non-depression grayscale closing operation is performed on the initial canopy height model, and the result of the closing operation is compared with the initial canopy height model pixel-by-pixel to fill in the internal canopy depressions, obtaining a depression-free canopy height model. A dual-scale Gaussian smoothing process is performed on the depression-free canopy height model to generate a sharp canopy height model and a smooth canopy height model; the sharp canopy height model is obtained through minimal-scale smoothing, and the smooth canopy height model is obtained through Gaussian smoothing at a scale proportional to the canopy radius of the tree species.
[0136] 62) Perform cross-correlation registration on the crown height model based on the canopy mask.
[0137] In this process, cross-correlation is used to translate and align the entire pixels of the crown margin of the crown height model to the hyperspectral crown mask. This step reconstructs a usable crown mound under the condition of only having crown surface point clouds and no complete crown height model, which is the premise for the present invention to still be segmentable under the condition of incomplete point clouds.
[0138] 63) Generate variable-window local maxima seeds based on the crown height model after cross-correlation registration; wherein the crown height model after cross-correlation registration is smoothed proportionally to the crown radius, and maxima regions with salience not less than a preset threshold are selected; peak merging is performed on the maxima regions, two peaks with a peak spacing less than a first proportional threshold are unconditionally merged, and two peaks with a peak spacing between the first and second proportional thresholds, belonging to the same spectral cluster, and with a peak saddle depth less than a preset saddle depth threshold are conditionally merged to obtain the effective peak seeds corresponding to the merged regions; for spectral clusters without geometric peaks, seeds are supplemented only in connected blocks with an area not less than a set multiple of the crown area, and the ratio of the area of the connected block to the crown area is constrained to a preset multiple of the total number of seeds in the connected block to obtain the variable-window local maxima seeds.
[0139] Before peak finding, CHM was smoothed with σ = 0.3R (R being the prior crown radius). h-maxima was used to select the maximum region (plateaus counted as one) with a prominence not less than the threshold Δh, suppressing false peaks caused by small undulations in branches and leaves. Then, variable window merging was performed: peaks with a distance less than 0.7R were unconditionally merged (same crown); peaks between 0.7R and 1.3R, belonging to the same spectral cluster, and with a saddle depth less than the threshold were merged (same crown, double protrusion). Only within connected blocks with an area not less than 1.6 crowns, one seed was added to spectral clusters with an area not less than 0.6 crowns and no geometric peaks. A physical density upper limit was also applied. Where A is the area of the connected component, and the number of seeds is also constrained by the wild count share. This "variable window merging + spectral replanting + density cap" mechanism can significantly restrain oversegmentation and suppress artificially high plant numbers.
[0140] 64) Calculate the spectral angle based on the reflectance base spectrum and the shape / derivative base spectrum, construct heterogeneous walls based on the spectral angle, and calculate the superpixel adjacency edge weights.
[0141] Specifically, pairwise spectral angles are calculated on the MSC spectrum of the superpixel. The SAM remains unchanged under multiplicative lighting (shading and shading). When the SAM is no greater than 0.12 radians (approximately 7°), it is judged as being in the same crown and its adjacency is preserved; when it is greater than 0.12 radians, it is judged as being in a different species wall. The superpixel adjacency edge weight is calculated by combining the spectral angle, mask gap, and geometric saddle depth E(i, j) = z(SAM_{ij}) + w_gap·gap_{ij} + w_geom·z(saddle_{ij}), where z(·) is normalized. Edges with excessively small SAM (inner crown branches / shading and shading) are not cut. This step explicitly transforms "different species adjacency" into a cuttable spectral wall, solving the problem of different species at the same height that cannot be distinguished by pure geometry. This is one of the key inventive points of this invention.
[0142] 65) Construct a fusion cost surface based on the spectral angle and the heterogeneous wall, and segment a controlled watershed on the fusion cost surface to obtain a canopy segmentation object.
[0143] Among them, constructing the cost surface of integration ,in Normalized topographic valley (i.e.) (normalization) λ is the spectral gradient (obtained by instantaneous PCA reduction of the superpixel spectrum within the region to 3D, drawing a raster, performing Sobel gradient, and normalizing), and λ is the weight. The generation method is as follows: The basis spectrum of each superpixel within the connected component is taken and subjected to instantaneous principal component transformation (reduced to 3D in this embodiment). The principal component values are then backfilled into a raster image according to the superpixel number. A Sobel gradient is then applied to the raster and normalized. Since the values within the same superpixel are constant, the gradient can only appear at the superpixel boundary, and the difference in principal components between adjacent superpixels is monotonically correlated with their spectral angle. The larger the spectral angle between adjacent superpixels (i.e., the heterogeneous wall determined in the previous step), the stronger the difference at that point. The higher.
[0144] The controlled watershed is marked with the variable window local maxima seed, flooded with water on C(p), and its compactness is set to 0 so that the boundary follows the cost completely. Thus, the boundary is simultaneously absorbed to two types of high-cost locations: one is the "terrain saddle" (…). High, meaning the elevation valley between the two crowns), and secondly, the "heterogeneous wall" ( The high point (i.e., the spectral abrupt change) is significant because: adjacent canopies of different species at the same height, even without a topographic saddle and impossible to cut using purely geometric methods, will still be cut due to the increased cost caused by the spectral wall; while within the same canopy, the undulations of branches and leaves and the spectral angle difference between the sun-shaded and shaded sides are very small, and the spectral angle between adjacent canopies of the same species is also small. The cost surface at this point is a low-cost flat area, so it will not be overcut. This is precisely the focus of this invention's "cooperative delimitation of geometry and spectroscopy on the same cost surface".
[0145] 66) The canopy segmentation region is corrected based on the pixel adjacency edge weights. Fragments with an area smaller than a set multiple of the canopy area are merged into the adjacent region with the lowest average cost of the shared boundary. Weak boundary merging is performed on regions that meet the conditions of low average cost of the shared boundary, the merged region does not exceed the upper limit of the canopy scale, and the saddle between regions is shallow. For multi-tree regions where there is neither a topographic saddle nor a spectral dividing wall between adjacent trees, no forced segmentation is performed. Instead, multi-tree marking is performed on the multi-tree regions and the estimated number of trees in the region is output.
[0146] Among them, pixel adjacent edge weight Integrating spectral angles Mask gap With geometric saddle depth Three types of evidence, z(·) represents standardization. and These are adjustable parameters. For each pair of adjacent marked regions output by the watershed, geometric saddle depth evidence and spectral angle evidence are first extracted from their shared boundary band (if necessary, evidence such as point density valleys and intercanopy gaps can also be incorporated), and then the evidence strength of this boundary is synthesized. If the evidence strength is not lower than the threshold, the segmentation is retained; if it is lower than the threshold, it is judged as a "no evidence segmentation" and the two regions are merged. As a preferred implementation, various types of evidence can also be synthesized into boundary probabilities using a noisy-OR method. ,by Whether the threshold is reached is used as the criterion for retaining the segmentation; at the same time, it is stipulated that "edges with too small a spectral angle (due to the undulation of branches and leaves within the crown or the difference between the yin and yang sides) shall not be cut" to prevent over-segmentation within the crown.
[0147] For example, fragments with an area less than 0.4 crowns are merged into the neighbor with the lowest average cost of shared boundaries; weak boundary merging is performed on adjacent areas with low average cost of shared boundaries, no over-scale after merging, and shallow saddles; "multi-tree areas" with neither topographic saddles nor spectral walls between adjacent trees are not forcibly segmented, but only marked as multi-tree areas and given an estimated number of trees (honest counting). Finally, the crown_id is obtained by renumbering each crown.
[0148] 67) Assign corresponding tree species labels to each corrected canopy segmentation region and output the spatial distribution map of the single tree species.
[0149] The following example, a dense mixed forest plot in Shanghai Haiwan National Forest Park, will be used to illustrate the method of the present invention in detail.
[0150] 1. Study Area and Data
[0151] The study area is located in Shanghai Haiwan National Forest Park, Haiwan Town, Fengxian District, Shanghai (approximately 121°42′E, 30°51′N), covering a total area of approximately 1065 hectares. Situated in the northern subtropical monsoon climate zone, it has an average annual temperature of approximately 15.7℃, an average annual precipitation of approximately 1200 mm, and an altitude of approximately 3–5 m. It is a near-natural mixed forest artificially created on the coastal mudflats. The main tree species include privet, Chinese tallow tree, pond cypress, camphor tree, soapberry, glossy bark cornelian cherry, goldenrain tree, slash pine, Chinese tallow tree, and Quercus acutissima. The forest has high stand density and significant differences in crown width and crown shape, making it a typical scenario for the identification and segmentation of individual trees in dense mixed forests.
[0152] The hyperspectral imagery was acquired on June 18, 2024, using an unmanned aerial vehicle (UAV) platform equipped with a Specim FX10 pushbroom hyperspectral imager. It includes 224 bands, a spectral range of 398–1004 nm, a spectral resolution of approximately 2.6 nm, and a spatial resolution of 0.08 m, acquiring a total of 7 flight strips. The raw images were radiometrically and geometrically corrected using CaliGeoPRO software, then stitched and cropped. The images were then converted to surface reflectance using ENVI Quick Atmospheric Correction (QUAC). Viewpoint correction was performed using non-rigid registration based on adaptive weighted bootstrap, with tree locations as control points (RMSE of 0.63 m). The actual analysis used 206 bands (429.11–986.90 nm). The complete image area used for analysis covered approximately 1 hectare at a spatial resolution of 0.08 m. LiDAR data and hyperspectral data were acquired simultaneously, with a point cloud density of 138 points / m². After noise reduction and removal of ground points, the point cloud mainly includes the crown surface and the downward extension of the crown edge, lacking information on the internal structure of the crown, the trunk, and the complete ground.
[0153] Annotation and reference data: 415 manually drawn tree canopy polygons from 16 tree canopy outline vectors (.shp, including 15 main tree species and "others") were used as annotations. After a majority vote rule of "the proportion of superpixel dominant polygons is not less than 0.66", they were converted into 5200 labeled superpixels, with 14619 candidate superpixels and 187 rejected in the open set. In addition, 498 trees with known GPS coordinates (covering 28 tree species) were used for external validation, and 955 trees / 32 tree species were manually counted from the entire plot as abundance priors and count-level deployment corrections.
[0154] 2. Implementation of steps S2 to S4
[0155] Following step S2, the 206-band reflectance image was subjected to a five-criteria canopy mask, brightness removal PCA (PC2-PC5), and SLIC (target number 20000, compactness 10, σ=1.0), resulting in 20020 canopy superpixels (of which 5231 fall within the labeled canopy). Then, following step S3, 201 deep shadow superpixels with substandard signal-to-noise ratios were removed, leaving 19819 canopy superpixels for subsequent analysis (5200 labeled, 14619 candidate). Following step S3, the brightest 50% of the near-infrared pixels of each superpixel were selected and subjected to MSC illumination removal, generating the reflectance base spectrum and derivative base spectrum, constructing approximately 148 redundancy-free features (A-J). Following step S4, perform leak-free cross-validation by grouping the data into "spatial blocks (approximately 15m, 0.08m pixels) + tree polygons". Calculate the tree-level JM separability matrix and perform 500 permutation tests on OvR / OvO. The group and separability conclusions are obtained: the pairwise tree-level AUC of closely related pairs such as pond cypress and slash pine is only about 0.75 (JM < 1, physically nearly inseparable). Based on this, construct the corresponding macroclass.
[0156] 3. Implementation of Step S5: Tree Species Identification
[0157] First, perform open set anomaly rejection using step S5 (PCA + Ledoit-Wolf Mahalanobis distance, P99 threshold approximately 9.56). Then, merge closely related indivisible species into seven macroclasses (three single-species macroclasses: *Bischofia javanica*, *Cornus sclerophylla*, and *Ligustrum lucidum*; three multi-member macroclasses: *Taxus chinensis* / *Pinus serrata* / *Sapium sebiferum*, *Koelreuteria bipinnata* / *Quercus acutissima*, and *Sapindus mukorossi* / *Cinnamomum camphora*; and one rare / unknown macroclass). For each macroclass, perform OvR using Ledoit-Wolf contracted LDA, isotonic calibration to probability, and calibrate the threshold to a precision target of 0.80. Argmax joint decision-making is employed; subsequently, direct and chained paths are compared for each species, and the best path is selected based on reachable recall under the overall accuracy target. For each tree species, a top-k feature budget is determined (a dedicated sparse subset is used for *Bischofia javanica*, 80 for *Cinnamomum camphora*, 80 for *Cornus sclerophylla*, 20 for *Quercus acutissima*, 30 for *Sapium sebiferum*, 50 for *Sapindus mukorossi*, 30 for *Ligustrum lucidum*, and 127 for *Koelreuteria bipinnata*). For sparse species such as *Bischofia javanica*, a typicality gate is added (e.g., using the 100% quantile envelope). Finally, the baseline of the entire site survey is used for count-level correction and threshold scanning. During the deployment phase, a K-fold model ensemble is used to score the entire map to avoid training / deployment scale drift.
[0158] 4. Implementation of step S6: Single-log splitting
[0159] In step S6, a crown mask (CHM) is constructed from the lidar point cloud (each cell is taken at the 97th quartile elevation, filled with holes in the crown, pit-free grayscale closure, and dual-scale Gaussian smoothing). The crown edge of the CHM is aligned to the hyperspectral crown mask using cross-correlation. The crown radius R for each tree species is data-driven (in this example, the measured values for the eight tree species are approximately 0.70–1.92 m). The prominence Δh and spectral angle threshold SAM are self-tuned by LOTO (in this example, Δh for the eight tree species is approximately 0.20–0.59 m, and SAM is approximately 0.05–0.12 radians). For each tree species, a seed is generated using variable window local maxima (σ = 0.3R smoothing, h-maxima, variable window merging, spectral seeding, density upper limit 1.30•area / πR²). A controlled watershed is created on the fusion cost surface of “normalized topographic valley + λ•spectral gradient (λ is 1)”, marked by the seed. Fragmentation incorporation, weak boundary merging, and multi-tree labeling are performed to obtain crown_id. Finally, tree species labels are assigned according to the S4 results, and the spatial distribution map of individual tree species is output.
[0160] 5. Comparison with existing technologies
[0161] Compared to watershed / regional growth based solely on CHM (which in this scenario suffers from severe over-segmentation / under-segmentation due to the point cloud containing only the crown surface and significant crown width variations), and species-by-species identification based solely on hyperspectral data (which fails or yields falsely high accuracy for closely related species due to their near physical indivisibility), this embodiment achieves robust tree species identification under weak annotation and incomplete point cloud conditions. It also achieves optimal single-tree segmentation accuracy under these data conditions, honestly segmenting physically indivisible species and rejecting truly unknown species. The results are interpretable and verifiable.
[0162] 6. Technical Effects
[0163] (1) The quality of the superpixels meets the design goals. The coefficient of variation of the constructed canopy superpixels in terms of pixel number and size consistency is 0.17 (<0.5), the proportion of superpixels with a spectral angle greater than 6° is 0.0%, and the proportion of superpixels with a boundary fit of less than 0.7 within a single canopy is only 3.5%, indicating that the constructed superpixels are "consistent in size, homogeneous internally, and have well-fitting boundaries", providing a reliable basic unit for subsequent analysis and identification.
[0164] (2) High tree species identification accuracy and honest classification. The tree-level AUC and confidence lower bound of the hierarchical multi-class classification (Ledoit-Wolf shrinkage LDA, accuracy target 0.80) on each macroclass are shown in Table 2. All seven macroclasses passed the decision gate, with a macroclass accuracy of 0.769 and a true macroclass detection rate of 0.878.
[0165] Table 2. Tree-level AUC and confidence lower bounds for each macroclass
[0166] After finalization through species-by-species route selection, eight tree species, including *Bischofia javanica*, *Cinnamomum camphora*, *Cornus sclerophylla*, *Quercus acutissima*, *Sapium sebiferum*, *Sapindus mukorossi*, *Ligustrum lucidum*, and *Koelreuteria bipinnata*, were reliably identified individually. Their out-of-fold tree-level AUCs under their respective deployment feature budgets were 1.000, 0.992, 0.973, 0.988, 0.981, 0.996, 0.954, and 0.979 (CI lower bound 0.92–1.00). After base rate correction at the count level (S4.5), all species achieved the overall deployment accuracy target of 0.80, with correction accuracy peaks ranging from 0.85 to 1.00. Finally, approximately 14,262 superpixels were identified for each species. For the physically nearly inseparable *Taxus chinensis* and *Pinus slashii* in the *Taxus chinensis* / *Pinus slashii* / *Sapium sebiferum* group (the pairwise tree-level AUC is only 0.751, JM < 1), this invention does not forcibly classify them species by species, but instead uses the point cloud geometry of S6 to segment them within the group, carrying the prior knowledge within the group. Members of the *Koelreuteria bipinnata* / *Quercus acutissima* group and the *Sapindus mukorossi* / *Cinnamomum camphora* group can be separated species by species by the discriminator and have been finally classified into single species. For truly new species not seen outside the training subset (such as 6 trees including *Ilex cornuta*, *Pittosporum tobira*, *Osmanthus fragrans*, and *Celtis sinensis*), the open set module successfully rejected them. This strategy of "separating if it can be separated, and honestly separating if it cannot be separated" significantly improves the reliability of the results.
[0167] (3) Single tree segmentation is robust under incomplete point cloud conditions. Under the conditions of evaluation using only labeled crowns, point cloud for geometry only, and LOTO self-tuning for each species, the single tree segmentation results for the eight tree species are shown in Table 3: detection rate 0.500-1.000, median IoU 0.581-0.674, mask coverage 0.170-0.963. To objectively measure the gain brought by accessing point cloud geometry, each connected component of the identification result using only spectrum (without accessing point cloud geometry) is considered as a prediction instance and compared with the segmentation result of this invention by following the same evaluation path (same IoU matrix, same Hungarian one-to-one assignment, same hit criterion of IoU≥0.5): the single tree one-to-one hit rate of all eight tree species is not lower than the baseline, and seven tree species show significant improvement (improvement range 0.091~0.364), only Sapindus mukorossi is on par with the baseline - the reason is that the median coverage of the label crown by the upstream tree species mask is only 0.170, which is limited by the upper limit of IoU itself, and the bottleneck is in the mask rather than the segmentation.
[0168] Table 3. Individual tree segmentation results for eight tree species
[0169] (4) Overall Effects. In dense mixed forests lacking complete point cloud structures, clear canopy boundaries, and sufficient labeled samples, this invention achieves weakly labeled, interpretable, and countable deployment of individual tree species identification and segmentation. On the one hand, through non-leaking analysis and open set rejection, it avoids artificially high accuracy and can identify truly unknown species. On the other hand, through the synergy of geometry and spectroscopy on the same cost plane, under the same evaluation caliber as the baseline, the one-to-one hit rate of all eight tree species at the individual tree segmentation scale is no less than the identification results using only spectroscopy, with seven tree species showing significant improvement. All of the above effects are directly brought about by the technical solution of this invention.
[0170] 7. Hardware and Implementation
[0171] This embodiment is implemented on a 64-core CPU and dual GPU (V100S) platform: intensive computations such as principal component transformation, feature-wise AUC, full-image linear scoring, and pixel-wise illumination removal are accelerated using GPUs; cross-validation, bootstrap confidence intervals, and watershed / post-processing are performed in multi-core parallelism. Those skilled in the art can implement this invention on a general-purpose computing platform based on this.
[0172] The protection scope of the tree species identification and single tree segmentation method described in this embodiment is not limited to the execution order of the steps listed in this embodiment. Any solution implemented by adding, subtracting, or replacing steps in the prior art based on the principle of this invention is included within the protection scope of this invention.
[0173] This invention also provides a tree species identification and single-tree segmentation system, which can implement the tree species identification and single-tree segmentation method described in this invention. However, the implementation device of the tree species identification and single-tree segmentation system described in this invention includes, but is not limited to, the structure of the tree species identification and single-tree segmentation system listed in this embodiment. All structural modifications and substitutions of the prior art made according to the principles of this invention are included within the protection scope of this invention.
[0174] like Figure 2 As shown, in one embodiment, the tree species identification and single tree segmentation system of the present invention includes a first acquisition module 21, a construction module 22, a processing module 23, a calculation module 24, a second acquisition module 25, and a generation module 26 connected in sequence.
[0175] The first acquisition module 21 is used to acquire hyperspectral images and lidar point clouds of mixed forests.
[0176] The construction module 22 is used to construct a canopy mask and a canopy superpixel based on the hyperspectral image.
[0177] The processing module 23 is used to perform pixel-by-pixel illumination removal processing within the canopy superpixel to construct the reflectance basis spectrum, shape / derivative basis spectrum, and spectral features corresponding to each canopy superpixel.
[0178] The calculation module 24 is used to calculate the tree-level Jeffries–Matusita separability matrix based on the spectral features, using the canopy superpixels as units, and to obtain the group composed of physically nearly inseparable tree species.
[0179] The second acquisition module 25 is used to acquire the tree species label of the canopy superpixel based on the spectral features and the group.
[0180] The generation module 26 is used to output a spatial distribution map of a single tree species based on the tree species label, the reflectance base spectrum, the shape / derivative base spectrum, the canopy mask, and the lidar point cloud.
[0181] The structure and principle of the first acquisition module 21, the construction module 22, the processing module 23, the calculation module 24, the second acquisition module 25, and the generation module 26 correspond one-to-one with the steps in the above-mentioned tree species identification and single tree segmentation method, so they will not be described again here.
[0182] In the embodiments provided by this invention, it should be understood that the disclosed systems, apparatuses, or methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative. For instance, the division of modules / units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple modules or units may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection of apparatuses or modules or units may be electrical, mechanical, or other forms.
[0183] The modules / units described as separate components may or may not be physically separate. The components shown as modules / units may or may not be physical modules; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules / units can be selected to achieve the objectives of the embodiments of the present invention, depending on actual needs. For example, the functional modules / units in the various embodiments of the present invention may be integrated into one processing module, or each module / unit may exist physically separately, or two or more modules / units may be integrated into one module / unit.
[0184] Those skilled in the art will further recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, computer software, or a combination of both. To clearly illustrate the interchangeability of hardware and software, the components and steps of the various examples have been generally described in terms of functionality in the foregoing description. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementations should not be considered beyond the scope of this invention.
[0185] This invention also provides a computer-readable storage medium. Those skilled in the art will understand that all or part of the steps in the methods of the above embodiments can be implemented by a program instructing a processor. The program can be stored in a computer-readable storage medium, which is a non-transitory medium, such as random access memory, read-only memory, flash memory, hard disk, solid-state drive, magnetic tape, floppy disk, optical disk, and any combination thereof. The storage medium can be any available medium accessible to a computer or a data storage device such as a server or data center that integrates one or more available media. The available medium can be a magnetic medium (e.g., floppy disk, hard disk, magnetic tape), an optical medium (e.g., digital video disc (DVD)), or a semiconductor medium (e.g., solid-state drive (SSD)).
[0186] This invention also provides a terminal. The terminal includes a processor and a memory.
[0187] The memory is used to store computer programs.
[0188] The memory includes various media capable of storing program code, such as ROM, RAM, magnetic disk, USB flash drive, memory card, or optical disk.
[0189] The processor is connected to the memory and is used to execute the computer program stored in the memory so that the terminal performs the above-described tree species identification and single tree segmentation methods.
[0190] Preferably, the processor can be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it can also be a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components.
[0191] like Figure 3 As shown, the terminal of the present invention is presented in the form of a general-purpose computing device. The components of the terminal may include, but are not limited to: one or more processors or processing units 31, a memory 32, and a bus 33 connecting different system components (including the memory 32 and the processing unit 31).
[0192] Bus 33 represents one or more of several bus architectures, including a memory bus or memory controller, a peripheral bus, a graphics acceleration port, a processor, or a local bus using any of the various bus architectures. For example, these architectures include, but are not limited to, the Industry Standard Architecture (ISA) bus, the Micro Channel Architecture (MAC) bus, the Enhanced ISA bus, the Video Electronics Standards Association (VESA) local bus, and the Peripheral Component Interconnect (PCI) bus.
[0193] Terminals typically include various computer system-readable media. These media can be any available media that can be accessed by the terminal, including volatile and non-volatile media, and removable and non-removable media.
[0194] Memory 32 may include computer system readable media in the form of volatile memory, such as random access memory (RAM) 321 and / or cache memory 322. The terminal may further include other removable / non-removable, volatile / non-volatile computer system storage media. By way of example only, storage system 323 may be used to read and write non-removable, non-volatile magnetic media (…). Figure 3 Not shown; usually referred to as a "hard drive"). Although Figure 3Not shown, a disk drive for reading and writing to a removable non-volatile disk (e.g., a "floppy disk") and an optical disc drive for reading and writing to a removable non-volatile optical disc (e.g., a CD-ROM, DVD-ROM, or other optical media) may be provided. In these cases, each drive may be connected to bus 33 via one or more data media interfaces. Memory 32 may include at least one program product having a set (e.g., at least one) of program modules configured to perform the functions of the embodiments of the present invention.
[0195] A program / utility 324 having a set (at least one) of program modules 3241 may be stored, for example, in memory 32. Such program modules 3241 include, but are not limited to, an operating system, one or more application programs, other program modules, and program data. Each or some combination of these examples may include an implementation of a network environment. Program modules 3241 typically perform the functions and / or methods described in the embodiments of the present invention.
[0196] The terminal can also communicate with one or more external devices (e.g., keyboard, pointing device, display, etc.), one or more devices that enable user interaction with the terminal, and / or any device that enables the terminal to communicate with one or more other computing devices (e.g., network interface card, modem, etc.). This communication can be performed through input / output (I / O) interface 34. Furthermore, the terminal can also communicate with one or more networks (e.g., local area network (LAN), wide area network (WAN), and / or public networks, such as the Internet) through network adapter 35. Figure 3 As shown, network adapter 35 communicates with other modules of the terminal via bus 33. It should be understood that, although not shown in the figure, other hardware and / or software modules can be used in conjunction with the terminal, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage systems.
[0197] The above embodiments are merely illustrative of the principles and effects of the present invention and are not intended to limit the invention. Any person skilled in the art can modify or alter the above embodiments without departing from the spirit and scope of the present invention. Therefore, all equivalent modifications or alterations made by those skilled in the art without departing from the spirit and technical concept disclosed in the present invention should still be covered by the claims of the present invention.
Claims
1. A method for tree species identification and individual tree segmentation, characterized in that, The method includes the following steps: Acquire hyperspectral images and lidar point clouds of mixed forests; Construct a canopy mask and canopy superpixels based on the hyperspectral images; Within the canopy superpixels, pixel-by-pixel illumination removal is performed to construct the reflectance basis spectrum, shape / derivative basis spectrum, and spectral features corresponding to each canopy superpixel; Based on the spectral features, the tree-level Jeffries–Matusita separability matrix is calculated using the canopy superpixels as units, and groups composed of physically nearly inseparable tree species are obtained. Tree species labels for the canopy superpixels are obtained based on the spectral features and the group. Based on the tree species label, the reflectance base spectrum, the shape / derivative base spectrum, the canopy mask, and the lidar point cloud, a spatial distribution map of a single tree species is output.
2. The tree species identification and single-tree segmentation method according to claim 1, characterized in that, Constructing a canopy mask and canopy superpixels based on the hyperspectral imagery includes the following steps: Based on the principle that five criteria are met simultaneously, a canopy mask is extracted from the hyperspectral image. The five criteria are: normalized vegetation index is greater than a first threshold, normalized red edge index is greater than a second threshold, green / red band ratio is greater than a third threshold, near-infrared / red band ratio is greater than a fourth threshold, and the brightness of the entire band is within a set quantile interval. Each pixel of the hyperspectral image is de-luminance normalized, and the luminance spectrum after de-luminance normalization is dimensionality reduced. Based on the dimensionality-reduced hyperspectral image, linear iterative clustering superpixel segmentation is performed only within the canopy mask to obtain the canopy superpixels.
3. The tree species identification and single-tree segmentation method according to claim 1, characterized in that, Performing pixel-by-pixel illumination removal within the canopy superpixel and constructing the reflectance basis spectrum, shape / derivative basis spectrum, and spectral features corresponding to each canopy superpixel includes the following steps: Select the light-receiving pixel from the canopy superpixels; Based on the mean spectrum of the light-receiving pixel, multivariate scattering correction is performed on the light-receiving pixel; The reflectance basis spectrum and shape / derivative basis spectrum are obtained from the light-receiving pixels after multivariate scattering correction. Spectral features are constructed based on the mean spectrum of the reflectance base spectrum and the shape / derivative base spectrum. The spectral features include two or more of the following: spectral morphology, Savitzky-Golay first / second derivative, vegetation index, piecewise slope, gray-level co-occurrence matrix texture, statistical moments, red edge / absorption scalar, continuum removal of absorption depth / area, advanced red edge features, and piecewise slope ratio.
4. The tree species identification and single-tree segmentation method according to claim 1, characterized in that, Based on the spectral features, the following steps are taken to calculate the tree-level Jeffries–Matusita separability matrix using the canopy superpixels as units and to obtain the groups composed of physically nearly inseparable tree species: Grouped by tree and spatial block, the canopy superpixels are subjected to leak-free grouped cross-validation based on the spectral features to obtain the out-of-fold prediction score of the canopy superpixels; The median spectrum of each tree is selected as an independent sampling unit. The Jeffries–Matusita distance between any two tree species is calculated, and the corresponding tree-level Jeffries–Matusita separability matrix is used as the upper bound of tree species separability. Based on the tree-level Jeffries–Matusita separability matrix and the out-of-place prediction scores, one-to-one and one-to-many permutation tests are performed on the tree species, and test errors are corrected. Based on the connected components of the non-significant edges of the one-to-one permutation test and the edges whose distance from the Jeffries–Matusita is less than a threshold, groups of physically nearly inseparable tree species are obtained.
5. The tree species identification and single-tree segmentation method according to claim 1, characterized in that, Obtaining the tree species label of the canopy superpixel based on the spectral features and the group includes the following steps: Based on the spectral features, the known tree species spectral envelopes of the canopy superpixels and the minimum Mahalanobis distance to the class mean of all known tree species are obtained. Canopy superpixels whose minimum Mahalanobis distance exceeds a preset quantile threshold are determined to be unknown tree species. For canopy superpixels that are not identified as unknown tree species, closely related tree species are merged into macroclasses. Canopy superpixels whose order-preserving calibration probability of the macroclass is not less than the corresponding macroclass threshold are formed into a qualified set. The macroclass with the highest posterior probability in the qualified set is taken as the tree species label corresponding to the canopy superpixel. Macroclasses that do not belong to the qualified set are identified as unknown tree species.
6. The tree species identification and single-tree segmentation method according to claim 1, characterized in that, Based on the tree species label, the reflectance base spectrum, the shape / derivative base spectrum, the canopy mask, and the lidar point cloud, outputting a spatial distribution map of a single tree species includes the following steps: A crown height model is constructed based on the lidar point cloud; The crown height model is cross-correlation registered based on the canopy mask; Variable-window local maxima seeds are generated based on the crown height model after cross-correlation registration. The crown height model after cross-correlation registration is smoothed proportionally to the crown radius, and maxima regions with a prominence not less than a preset threshold are selected. Peak merging is performed on these maxima regions: two peaks with a peak spacing less than a first proportional threshold are unconditionally merged; two peaks with a peak spacing between the first and second proportional thresholds, belonging to the same spectral cluster, and with a peak saddle depth less than a preset saddle depth threshold are conditionally merged to obtain the effective peak seeds corresponding to the merged regions. For spectral clusters without geometric peaks, seeds are only planted within connected blocks with an area not less than a set multiple of the crown area, and the total number of seeds within the connected blocks is constrained to not exceed a preset multiple of the ratio of the connected block area to the crown area to obtain the variable-window local maxima seeds. The spectral angle is calculated based on the reflectance base spectrum and the shape / derivative base spectrum. A heterogeneous wall is constructed based on the spectral angle, and the superpixel adjacency edge weight is calculated. A fusion cost surface is constructed based on the spectral angle and the heterogeneous wall, and a controlled watershed is segmented on the fusion cost surface to obtain canopy segmentation objects; The canopy segmentation region is corrected based on the pixel adjacency edge weights. Fragments with an area smaller than a set multiple of the canopy area are merged into the adjacent region with the lowest average cost of the shared boundary. For regions that meet the conditions of low average cost of the shared boundary, merged region not exceeding the upper limit of the canopy scale, and shallow saddle between regions, weak boundary merging is performed. For multi-tree regions where there are neither topographic saddles nor spectral dividing walls between adjacent trees, no forced segmentation is performed. Instead, multi-tree regions are marked and the estimated number of trees in the region is output. Assign a corresponding tree species label to each corrected canopy segmentation region and output the spatial distribution map of the individual tree species.
7. The tree species identification and single-tree segmentation method according to claim 6, characterized in that, Constructing a crown height model based on the lidar point cloud includes the following steps: The lidar point cloud is projected onto the same grid coordinate system as the hyperspectral image, and the elevation of each grid is taken to complete the point cloud rasterization. Within the canopy mask area only, the grid holes inside the canopy mask formed by the lack of point cloud are sequentially processed by nearest neighbor filling and closing operations to complete the annular hollow canopy structure into a solid mound structure and obtain the initial canopy height model. Perform a non-depression grayscale closing operation on the initial crown height model, and then perform pixel-by-pixel processing on the closing operation result and the initial crown height model to fill the pits inside the crown and obtain a non-depression crown height model. The non-concave crown height model is subjected to dual-scale Gaussian smoothing to generate a sharp crown height model and a smooth crown height model; wherein, the sharp crown height model is obtained by minimal-scale smoothing, and the smooth crown height model is obtained by Gaussian smoothing according to a scale proportional to the crown radius of the tree species.
8. A tree species identification and single-tree segmentation system, characterized in that, The system includes a first acquisition module, a construction module, a processing module, a calculation module, a second acquisition module, and a generation module; The first acquisition module is used to acquire hyperspectral images and lidar point clouds of mixed forests; The construction module is used to construct a canopy mask and canopy superpixels based on the hyperspectral image; The processing module is used to perform pixel-by-pixel illumination removal processing within the canopy superpixel, and to construct the reflectance basis spectrum, shape / derivative basis spectrum and spectral features corresponding to each canopy superpixel; The calculation module is used to calculate the tree-level Jeffries–Matusita separability matrix based on the spectral features, using the canopy superpixels as units, and to obtain the group composed of physically nearly inseparable tree species; The second acquisition module is used to acquire the tree species label of the canopy superpixel based on the spectral features and the group; The generation module is used to output a spatial distribution map of a single tree species based on the tree species label, the reflectance base spectrum, the shape / derivative base spectrum, the canopy mask, and the lidar point cloud.
9. A terminal, characterized in that, The terminal includes: a processor and a memory; The memory is used to store computer programs; The processor is used to execute the computer program stored in the memory to enable the terminal to perform the tree species identification and single tree segmentation method according to any one of claims 1 to 7.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the program is executed by the terminal, it implements the tree species identification and single-tree segmentation method as described in any one of claims 1 to 7.