Soil organic matter inversion method and system based on unmanned aerial vehicle multispectral

CN122345575BActive Publication Date: 2026-08-28CHINA AGRI UNIV
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202610778838.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2026-06-02
Publication Date
2026-08-28
Estimated Expiration
2046-06-02

AI Technical Summary

Technical Problem

针对现有技术的不足,本发明提供了基于无人机多光谱的土壤有机质反演方法及系统,解决了现有无人机多光谱土壤有机质反演中特征冗余与遥测反射率扰动叠加,导致特征筛选结果不稳定且模型跨地块泛化一致性不足的问题

Benefits of technology

(1)、基于无人机多光谱的土壤有机质反演方法及系统,通过在多光谱遥测数据进入反演计算前引入亮度对齐、影像同步、平滑抑制、异常剔除、插值补全、标准化处理的统一链路,使绿光反射率、红光反射率、红边反射率、近红外反射率在不同采样周期具备可比的数值基准,降低飞行姿态与入射光强波动对反演输入的一致性破坏。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122345575B_ABST
    Figure CN122345575B_ABST
Patent Text Reader

Abstract

The application discloses a soil organic matter inversion method and system based on unmanned aerial vehicle multispectrum, relates to the technical field of soil spectrum detection, and comprises the following steps: S1, collecting multispectrum remote sensing data and soil characteristic data, and performing pretreatment on the collected data; S2, constructing a wave band reflectivity vector and a spectral form offset value, and generating a spectral structure matrix; S3, constructing a spectral feature matrix, performing correlation screening on the spectral feature matrix to obtain an effective feature matrix, performing resampling screening processing on the effective feature matrix, and constructing an inversion input feature matrix; and S4, outputting a soil organic matter inversion sequence based on a random forest regression model, performing spatial interpolation and grid construction on the soil organic matter inversion sequence, and generating a soil organic matter inversion image. The application solves the problems that in the existing unmanned aerial vehicle multispectrum soil organic matter inversion, feature redundancy and remote sensing reflectivity disturbance are superimposed, the feature screening result is unstable, and the model cross-plot generalization consistency is insufficient.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of soil spectral detection technology, specifically to a method and system for soil organic matter inversion based on UAV multispectral analysis. Background Technology

[0002] In recent years, soil organic matter content, as an important indicator of arable land quality and fertility, has seen a continuous increase in demand in applications such as arable land quality monitoring, precision fertilization decision-making, and digital agricultural management. With the development of spectral sensors, miniaturized imaging equipment, and data modeling methods, utilizing spectral reflectance information from the visible to near-infrared bands to invert soil physicochemical indicators has become an important technical route for non-destructive testing and rapid estimation of soil nutrients. Related research and applications typically achieve quantitative estimation of soil organic matter content by collecting the spectral reflectance of soil samples, constructing characteristic indicators, and establishing estimation models.

[0003] For example, the invention with publication number CN113358584B provides a method for estimating soil organic matter content using spectroscopy, belonging to the field of non-destructive testing technology for soil nutrients. The method for estimating soil organic matter content according to this invention includes: collecting soil samples, measuring the organic matter content and spectral reflectance of the soil samples in the range of 400–1000 nm, fitting a soil spectral reflectance curve, constructing an estimation model, and estimating the organic matter content in the soil; the formula for the soil spectral reflectance curve is: y = Slope × x + b; the formula for the estimation model is: OM = c × Ln(Slope) + d.

[0004] For example, publication number CN117929325A specifically relates to a method for estimating soil organic matter content. This includes: collecting soil samples, performing spectral measurements to obtain reflectance spectral data in the 500–2400 nm band; combining the reflectance spectral data pairwise to calculate the soil ratio index, soil difference index, and soil normalization index to obtain a two-band mixed spectrum of soil organic matter; selecting two-band spectral indices with an absolute correlation coefficient greater than 0.85 from the two-band mixed spectrum to form a two-band spectral index matrix; using an external parameter orthogonalization algorithm, processing the two-band spectral index matrix as input to the algorithm; and constructing an estimation model using partial least squares prediction to obtain the estimated soil organic matter content.

[0005] However, the aforementioned existing technical solutions mostly rely on ground soil sample collection and single-point or near-range spectral measurements for curve fitting or exponential modeling. The data acquisition methods and application scenarios are more geared towards offline estimation and small-scale experimental conditions. When the application scenario expands to plot-scale monitoring using UAV multispectral remote sensing, reflectance data is easily affected by changes in flight altitude, fluctuations in incident light intensity, attitude changes, and differences in ground background, making it difficult to maintain consistent reflectance comparability across time phases and plots, thus reducing the stability and applicability of the inversion model. Furthermore, under UAV multispectral time-series data conditions, existing methods are insufficient in suppressing the impact of abnormal sampling cycles, ensuring the stability of feature selection results, and supporting the consistency of plot-scale representation of inversion results, making it difficult to meet the comprehensive requirements of robustness and usability for plot-scale soil organic matter inversion.

[0006] Therefore, in order to address the above problems, there is an urgent need for a soil organic matter inversion method and system based on UAV multispectral analysis. Summary of the Invention

[0007] Technical problems to be solved To address the shortcomings of existing technologies, this invention provides a method and system for soil organic matter inversion based on UAV multispectral data. This method solves the problem that the superposition of feature redundancy and telemetry reflectance disturbance in existing UAV multispectral soil organic matter inversion methods leads to unstable feature selection results and insufficient model generalization consistency across plots.

[0008] Technical solution To achieve the above objectives, this invention provides the following technical solution: a soil organic matter inversion method based on UAV multispectral data, comprising: S1, periodically acquiring multispectral telemetry data and soil characteristic data, and performing brightness alignment, image synchronization, smoothing, anomaly removal, interpolation completion, and standardization on the acquired data; S2, constructing band reflectance vectors and spectral morphology offset values ​​based on the preprocessed multispectral telemetry data, and performing local statistical interval comparison and anomaly replacement processing on the spectral morphology offset values ​​according to the sampling period to generate a spectral structure matrix; S3, based on the spectral structure matrix... The array generates spectral derived feature groups according to the sampling period and constructs a spectral feature matrix. The spectral feature matrix is ​​subjected to correlation screening to obtain an effective feature matrix. The effective feature matrix is ​​subjected to resampling screening to construct an inversion input feature matrix. S4, a training set and a validation set are constructed based on the inversion input feature matrix and the measured soil organic matter values. The random forest regression model is trained using the training set, and the soil organic matter inversion sequence is output based on the random forest regression model. A pixel index is established, and pixel raster reconstruction is performed based on the pixel index and the soil organic matter inversion sequence to generate a soil organic matter inversion image.

[0009] Furthermore, the specific steps for periodically acquiring multispectral telemetry data and soil characteristic data, and performing brightness alignment, image synchronization, smoothing, anomaly removal, interpolation completion, and standardization on the acquired data are as follows: A fixed-width sliding time window is set as one sampling period. Multispectral telemetry data is periodically acquired, including green reflectance, red reflectance, red-edge reflectance, near-infrared reflectance, surface incident light intensity, and sampling timestamps. Soil characteristic data is also acquired through ground sampling operations, including soil organic matter measurements and sampling point coordinates. Multispectral telemetry data and soil characteristics are recorded in chronological order for each sampling period. Data was collected to construct a multispectral soil observation dataset. For the multispectral soil observation data, histogram matching algorithm and affine transformation resampling algorithm were used to perform brightness alignment and image synchronization processing on multi-source time-series records. Adaptive median filtering algorithm was used to perform dynamic smoothing suppression on local noise segments and brightness abrupt segments in the multispectral soil observation data. Anomalous pixels and boundary gradient segments in the multispectral soil observation data were identified and removed using a two-sided Hanning window filtering algorithm, and short-term missing data were continuously filled in using a bicubic convolution interpolation algorithm. The multispectral soil observation data were scaled using a min-max standardization algorithm to unify the numerical scale and eliminate dimensional differences.

[0010] Further, the specific steps for constructing the band reflectance vector and spectral morphology shift value based on the preprocessed multispectral telemetry data are as follows: Based on the preprocessed multispectral telemetry data, green reflectance, red reflectance, red-edge reflectance, and near-infrared reflectance are read according to the sampling period to construct the band reflectance vector within the sampling period; and the spectral morphology shift value is calculated based on the band reflectance vector. The spectral morphology shift value is merged with the corresponding band reflectance vector to obtain the structure vector of the corresponding sampling period; the green reflectance and near-infrared reflectance are added together and halved, and then the red-edge reflectance is subtracted to obtain the spectral mid-range difference; the absolute value of the difference between the red-edge reflectance and the red reflectance is added to the minima to obtain the red-edge gradient; the spectral mid-range difference is divided by the red-edge gradient, and the hyperbolic tangent operation is performed on the obtained ratio to obtain the spectral morphology shift value of the current sampling period.

[0011] Further, the specific steps for generating the spectral structure matrix by performing local statistical interval comparison and anomaly replacement processing on the spectral morphology offset values ​​according to the sampling period are as follows: A sliding window is established for the spectral morphology offset values ​​according to the sampling period. The window contains the set of spectral morphology offset values ​​for the current sampling period and adjacent sampling periods. The local median and the absolute deviation of the local median of the spectral morphology offset values ​​within the window are calculated, and the local statistical interval for the current sampling period is constructed by comparing the local median with the absolute deviation of the local median by a fixed multiple. The spectral morphology offset values ​​are compared with the local statistical interval according to the sampling period: when the spectral morphology offset value falls within the local statistical interval, the current sampling period is marked as a normal spectral period, and the current structure vector is retained; when the spectral morphology offset value exceeds the local statistical interval, the current sampling period is marked as a spectral anomaly period, and the current structure vector is replaced with the average of the structure vectors of two adjacent normal spectral periods; and the final structure vectors of each sampling period are extracted and concatenated into a spectral structure matrix according to the sampling time order.

[0012] Furthermore, the specific steps for generating spectral derived feature groups based on the spectral structure matrix according to the sampling period and constructing the spectral feature matrix are as follows: read the spectral structure matrix, read the green light reflectance, red light reflectance, red edge reflectance and near-infrared reflectance according to the sampling period, perform difference operation, normalized difference operation and ratio operation in pairs, and combine the operation results into spectral derived feature groups in a fixed order; splice the spectral derived feature groups in a fixed column order according to the sampling period to obtain the spectral feature matrix.

[0013] Furthermore, the specific steps for performing correlation screening on the spectral feature matrix to obtain an effective feature matrix are as follows: traverse the spectral feature matrix by feature column, read all sampling period values ​​of each column of features, and pair the current column feature with the subsequent column features one by one. Use the Pearson correlation coefficient algorithm to calculate the correlation coefficient for each pair of features. When the absolute value of the correlation coefficient exceeds the coefficient threshold, retain the current feature column. When the absolute value of the correlation coefficient is less than or equal to the coefficient threshold, remove the current feature column. Concatenate the retained feature columns in the original column order to construct an effective feature matrix.

[0014] Further, the specific steps for performing resampling and filtering on the effective feature matrix and calculating the selection probability of feature columns to construct the inversion input feature matrix are as follows: The effective feature matrix is ​​used as the input feature set of the competitive adaptive resampling algorithm, and the soil organic matter measurement value is used as the target value; the competitive adaptive resampling algorithm is run N times repeatedly, and each run outputs a set of selected feature column indices; the number of times each feature column index is selected is calculated for the N runs, and the selection probability is obtained by dividing the number of selections by N; feature column indices with a selection probability exceeding 50% are extracted, and the effective feature matrix columns corresponding to the extracted feature columns are concatenated in ascending order of column index to construct the inversion input feature matrix.

[0015] Further, the specific steps for constructing training and validation sets based on the inversion input feature matrix and soil organic matter measurement values, training a random forest regression model using the training set, and outputting the soil organic matter inversion sequence based on the random forest regression model are as follows: Read the inversion input feature matrix, extract spectral morphology shift values ​​according to the sampling period, and combine them in a fixed column order to form a training input vector; read historical soil organic matter measurement values ​​from the ground sampling operation records according to the sampling period to form a training output vector; divide the training input vector into a training set and a validation set with a fixed step size, and train the random forest regression model using the training set; after regression training, input the validation set into the random forest regression model to obtain the validation inversion output, and calculate the average inversion error based on the difference between the validation inversion output and the soil organic matter measurement values ​​in the validation set; when the average inversion error is less than the error threshold, the random forest regression model training is considered complete; after the random forest regression model training is complete, input the real-time inversion input feature matrix into the random forest regression model in the order of the sampling period, output the soil organic matter inversion values ​​corresponding to each sampling period, and combine them in the order of the sampling period to obtain the soil organic matter inversion sequence.

[0016] Further, the following specific steps are taken to establish a pixel index and reconstruct the soil organic matter inversion image based on the pixel index and the soil organic matter inversion sequence: A pixel index table is established based on the preprocessed multispectral telemetry data, recording the pixel row number, pixel column number, pixel center coordinates, and pixel spectral data; the soil organic matter inversion sequence is read, and the soil organic matter inversion values ​​corresponding to each pixel are used to construct a soil organic matter inversion raster matrix according to the pixel index table; the soil organic matter inversion raster matrix is ​​converted into an inversion visualization matrix according to a fixed color level mapping table, and then combined in the order of pixel rows and columns to generate a soil organic matter inversion image.

[0017] The second aspect of this invention provides a soil organic matter inversion system based on UAV multispectral data, comprising: a data acquisition and preprocessing module, a spectral structure matrix construction module, a spectral feature screening and generation module, and a soil organic matter inversion module. The data acquisition and preprocessing module is used to periodically acquire multispectral telemetry data and soil feature data, and to perform brightness alignment, image synchronization, smoothing, anomaly removal, interpolation completion, and standardization processing on the acquired data. The spectral structure matrix construction module is used to construct band reflectance vectors and spectral morphology offset values ​​based on the preprocessed multispectral telemetry data, and to perform local statistical interval comparison and anomaly replacement processing on the spectral morphology offset values ​​according to the sampling period to generate a spectral structure matrix. The spectral feature filtering and generation module generates spectral derived feature groups based on the spectral structure matrix according to the sampling period, constructs a spectral feature matrix, performs correlation filtering on the spectral feature matrix to obtain an effective feature matrix, performs resampling filtering on the effective feature matrix and counts the probability of feature columns being selected, and constructs an inversion input feature matrix. The soil organic matter inversion module constructs a training set and a validation set based on the inversion input feature matrix and the measured soil organic matter values, trains a random forest regression model using the training set, and outputs a soil organic matter inversion sequence based on the random forest regression model. It establishes a pixel index and performs pixel raster reconstruction based on the pixel index and the soil organic matter inversion sequence to generate a soil organic matter inversion image.

[0018] Beneficial effects The present invention has the following beneficial effects: (1) Soil organic matter inversion method and system based on UAV multispectral data: By introducing a unified link of brightness alignment, image synchronization, smoothing suppression, anomaly removal, interpolation completion and standardization processing before the multispectral telemetry data enters the inversion calculation, the green light reflectance, red light reflectance, red edge reflectance and near-infrared reflectance have comparable numerical benchmarks in different sampling periods, reducing the impact of flight attitude and incident light intensity fluctuations on the consistency of inversion input.

[0019] (2) Soil organic matter inversion method and system based on UAV multispectral method: by using spectral morphology offset value to determine the local statistical interval of sampling period, and by using the average replacement of adjacent normal period structure vectors for abnormal spectral periods, the spectral structure matrix can maintain continuity and availability even in the event of local mutation, local noise, or short-term missingness, thus avoiding cascading offset of abnormal periods to subsequent feature construction and screening.

[0020] (3) Soil organic matter inversion method and system based on UAV multispectral method: First, the effective feature matrix is ​​obtained by performing correlation screening on the spectral feature matrix formed by the spectral derived feature group. Then, the effective feature matrix is ​​resampled and the probability of the feature column being selected is counted. "Probability stable selection" is used as the retention criterion, so that the final inversion input feature matrix is ​​not sensitive to sample disturbance, and the risk of replacement of the screening results by the high correlation redundancy introduced by the pairwise combination features is reduced.

[0021] (4) Soil organic matter inversion method and system based on UAV multispectral method: By training a random forest regression model based on the inversion input feature matrix and soil organic matter measurement value, and outputting a soil organic matter inversion sequence, and then combining the sampling point coordinates to perform spatial interpolation and raster construction to form a soil organic matter inversion image, the inversion results have both numerical sequence form and spatial expression form, which is convenient for direct comparative analysis and visualization at the plot scale. Attached Figure Description

[0022] Figure 1 This is a flowchart of a method for retrieving soil organic matter based on UAV multispectral analysis. Figure 2 This is a structural diagram of a soil organic matter inversion system based on UAV multispectral imaging. Figure 3 Preserve the decision map for the structure vector based on the spectral morphology offset value; Figure 4 This is a comparison chart showing the accuracy of soil organic matter inversion. Detailed Implementation

[0023] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0024] Please see Figures 1-3This invention provides a technical solution: a soil organic matter inversion method based on UAV multispectral data, comprising: S1, periodically acquiring multispectral telemetry data and soil characteristic data, and performing brightness alignment, image synchronization, smoothing, anomaly removal, interpolation completion, and standardization on the acquired data; S2, constructing band reflectance vectors and spectral morphology offset values ​​based on the preprocessed multispectral telemetry data, and performing local statistical interval comparison and anomaly replacement processing on the spectral morphology offset values ​​according to the sampling period to generate a spectral structure matrix; S3, generating spectral derived characteristics based on the spectral structure matrix according to the sampling period. The spectral feature matrix is ​​constructed by coupling eigenvalues ​​with the spectral features. Correlation and sequence stability screening are performed on the spectral feature matrix to generate an effective feature matrix. Principal component analysis is then performed on the effective feature matrix to generate the inversion input feature matrix. In step S4, a training set and a validation set are constructed based on the inversion input feature matrix and historical soil organic matter measurements. The self-organizing map model is then trained and validated, and the soil organic matter inversion sequence is output based on the training results. A pixel index is established, and pixel raster reconstruction is performed based on the pixel index and the soil organic matter inversion sequence to generate a soil organic matter inversion image.

[0025] Specifically, the steps for periodically acquiring multispectral remote sensing data and soil characteristic data, and performing brightness alignment, image synchronization, smoothing, anomaly removal, interpolation completion, and standardization on the acquired data are as follows: A fixed-width sliding time window is set as one sampling period, with the duration of the fixed-width sliding time window limited to 1 to 10 seconds. Multispectral remote sensing data is periodically acquired, including green reflectance, red reflectance, red-edge reflectance, near-infrared reflectance, surface incident light intensity, and sampling timestamps. Green reflectance is calculated from the green band imaging data of the multispectral camera mounted on the UAV, red reflectance is calculated from the red band imaging data of the multispectral camera mounted on the UAV, and red-edge reflectance... The data were calculated from red-edge band imaging data of a multispectral camera on a UAV, near-infrared reflectance was calculated from near-infrared band imaging data of the same camera, and surface incident light intensity was collected by a downlink irradiance sensor on the UAV. Sampling timestamps were generated from time synchronization information recorded by the UAV's flight control system. During the data acquisition process, a monotonically increasing verification was performed on the sampling timestamps, and start and end boundaries were truncated for timestamps within the same sampling period to ensure that the multispectral telemetry data for each sampling period fell within the corresponding time window. Soil characteristic data, including soil organic matter measurements and sampling point coordinates, were also collected through ground sampling operations. Soil organic matter measurements were obtained from soil samples obtained from ground sampling using a portable... The soil organic matter analyzer completed the measurements, and the sampling point coordinates were obtained by ground-based handheld RTK measurement of the sampling locations. During the data collection process, the sampling point coordinates underwent standardized coordinate format processing, duplicate point verification, and for cases where the same sampling point coordinates appeared multiple times in adjacent sampling periods, the data was sorted chronologically and the latest record was retained. Multispectral telemetry data and soil characteristic data were recorded in chronological order for each sampling period to construct a multispectral soil observation dataset. During the recording process, the sampling timestamp was used as an alignment key to establish the correspondence between multispectral telemetry data and soil characteristic data. Records lacking alignment keys were marked as missing and entered into the subsequent completion process. For multispectral soil observation... For the measured data, histogram matching algorithm and affine transformation resampling algorithm are used to perform brightness alignment and image synchronization processing on multi-source time-series records. In the histogram matching algorithm processing, the image frame corresponding to the stable segment of surface incident light intensity in the same sampling period is used as the reference image. The cumulative histogram of gray-level distribution of the reference image is calculated, and the gray-level distribution of the current image is mapped to the gray-level distribution of the reference image. In the affine transformation resampling algorithm processing, a two-dimensional affine transformation relationship is established based on the heading angle, pitch angle, and roll angle recorded by the UAV flight control. The translation parameter, rotation parameter, and scale parameter are solved for the current image. The transformed pixel positions are resampled and aligned to ensure that the multispectral telemetry data in the same sampling period are consistent in spatial position.An adaptive median filtering algorithm is used to dynamically smooth and suppress local noise segments and brightness abrupt change segments in multispectral soil observation data. During the adaptive median filtering process, a variable window ranging from 3x3 to 7x7 is set for each image frame. The median value of each pixel within the window is calculated and compared with the center pixel for deviation. If the deviation exceeds a deviation threshold, the center pixel is replaced with the median value within the window; otherwise, the center pixel is retained. The window size is adaptively adjusted according to the noise density. A bilateral Hanning window filtering algorithm is used to identify and remove anomalous pixels and boundary gradient segments in the multispectral soil observation data. Short-term missing data is continuously filled in using a bicubic convolution interpolation algorithm. During the bilateral Hanning window filtering process, a windowed sequence is constructed from the temporal reflectance sequence using the sampling period as the unit. The weighted mean of the windowed sequence is calculated and compared with the difference between the windowed sequence and the original sequence. Pixels with differences exceeding the difference threshold are marked as anomalous pixels and removed; segments with continuously changing gradients exceeding the gradient threshold are marked as boundary gradient segments and removed. During the bicubic convolution interpolation algorithm, an interpolation neighborhood is constructed using valid samples before and after the missing location. Bicubic convolution kernel weights are calculated for the interpolation neighborhood to generate the interpolation result, ensuring the reflectance sequence of the missing segment remains continuous. The multispectral soil observation data is scaled using the min-max normalization algorithm to unify the numerical scale and eliminate dimensional differences. During the min-max normalization algorithm, the minimum and maximum values ​​of green reflectance, red reflectance, red-edge reflectance, near-infrared reflectance, and surface incident light intensity are extracted in the current sampling period, and interval mapping is performed by field to map each field value to a range of zero to one.

[0026] In this implementation plan, by limiting the sampling period and clarifying the source and time alignment of the acquisition equipment for green light reflectance, red light reflectance, red edge reflectance, near-infrared reflectance, surface incident light intensity, sampling timestamp, soil organic matter measurement value, and sampling point coordinates, the multispectral soil observation dataset forms a unified data constraint baseline in three dimensions: temporal consistency, spatial consistency, and numerical comparability. This ensures that multispectral telemetry data and soil characteristic data from different sampling periods can stably correspond and remain continuously available, reducing the risk of data structure breakage caused by light fluctuations, attitude disturbances, and local missing data. This provides a reproducible input basis for subsequent calculation of spectral morphology offset values, comparison of local statistical intervals, and construction of the spectral structure matrix.

[0027] Specifically, the steps for constructing band reflectance vectors and spectral morphology offset values ​​based on preprocessed multispectral telemetry data are as follows: Based on the preprocessed multispectral telemetry data, green reflectance, red reflectance, red-edge reflectance, and near-infrared reflectance are read according to the sampling period to construct a band reflectance vector within the sampling period; the band reflectance vector is used to solidify the reflectance morphology input of the current sampling period in a fixed band order, so that subsequent calculations have a consistent sequence benchmark when comparing across sampling periods, and at the same time, the red-edge reflectance participates in morphology determination at a fixed position, ensuring that the "edge transition" feature of the red-edge band in the reflectance curve can be stably referenced; and based on the band reflectance... The spectral morphological shift value is calculated using the reflectance vector. This shift characterizes the degree of shift in red-edge reflectance relative to green and near-infrared reflectance, providing a quantifiable single-value representation of morphological differences between sampling periods. Red-edge reflectance is sensitive to the chlorophyll absorption edge of vegetation and significantly responds to changes in surface soil iron oxide content. When there are fluctuations in land cover or differences in soil mineral composition, the shifts in red-edge reflectance relative to green and near-infrared reflectance will change synchronously, thus providing a transferable morphological constraint for soil organic matter inversion. The spectral morphological shift value is then combined with the corresponding band reflectance vector to obtain the result for the corresponding sampling period. The structure vector is used to encapsulate the single-value morphological determination quantity and the four-band reflectance into a unified input record, facilitating direct splicing according to the sampling period when constructing the spectral structure matrix later. The green reflectance and near-infrared reflectance are added together, halved, and then the red-edge reflectance is subtracted to obtain the mid-spectral difference. The mid-spectral difference characterizes the deviation direction of the mid-spectral equilibrium level of green and near-infrared reflectance relative to the red-edge reflectance, forming the numerator of the offset calculation. The mean of green and near-infrared reflectance provides a brightness reference and offsets the overall reflectance increase caused by fluctuations in the intensity of incident light on the ground surface, making the numerator more concentrated in reflecting the red-edge reflectance. The morphological changes of reflectance; the absolute value of the difference between red-edge reflectance and red light reflectance is added to the minima to obtain the red-edge gradient; the red-edge gradient is used to provide a normalization scale and avoid ratio amplification and instability caused by the absolute value of the difference approaching zero, forming the denominator of the offset calculation. Red-edge reflectance and red light reflectance, under the band adjacency relationship, form a red-edge slope measure, which can remain sensitive to changes in the steepness of the chlorophyll absorption edge and the spectral slope changes caused by soil iron oxides, giving the normalization scale a clear physical motivation; the minima are small but non-zero positive real numbers used to avoid numerical instability caused by division by zero during the calculation, and their value range is... arrive Unless otherwise specified, all subsequent minima will use this definition and value range. The difference in the mid-spectral range is divided by the red-edge gradient, and the resulting ratio is subjected to hyperbolic tangent operation to obtain the spectral morphology shift value for the current sampling period. The resulting ratio is used to make the numerator dimensionless according to the red-edge gradient, so that different sampling periods can still be directly compared under changes in brightness amplitude, while keeping the distribution scale consistent under the difference in reflectance base values ​​of different plots. The hyperbolic tangent operation is used to compress the dimensionless ratio to a bounded interval and weaken the pull of extreme ratios on the judgment boundary, so that the spectral morphology shift value maintains a stable numerical scale when compared in subsequent local statistical intervals, and makes the statistical distribution of the spectral morphology shift value closer to a controllable centralized shape, thereby improving the estimation stability of the local median and the absolute deviation of the local median and enhancing the consistency of the anomaly replacement judgment.

[0028] The specific formula for calculating the spectral morphology shift value is as follows: ; In the formula, Indicates the spectral morphology shift value. Indicates green light reflectance, Indicates near-infrared reflectance, Indicates red-edge reflectivity. Indicates red light reflectance. Indicates a minus term.

[0029] In this embodiment, Table 1 shows the calculated spectral morphology shift values ​​and the corresponding band reflectance input data for five sampling periods. Specifically: Sampling period 1: Green reflectance is 0.180, near-infrared reflectance is 0.340, red-edge reflectance is 0.260, red reflectance is 0.150, and the minimum term is... The corresponding calculated spectral morphology shift value is 0.0000. Sampling period 2: Green reflectance is 0.160, near-infrared reflectance is 0.310, red-edge reflectance is 0.240, red reflectance is 0.140, and the minima are... The corresponding calculated spectral morphology shift value is -0.0499. Sampling period 3: Green reflectance 0.200, near-infrared reflectance 0.380, red-edge reflectance 0.280, red reflectance 0.170, and the minimum term is... The corresponding calculated spectral morphology shift value is 0.0906. Sampling period 4: Green reflectance is 0.140, near-infrared reflectance is 0.290, red-edge reflectance is 0.220, red reflectance is 0.130, and the minima are... The corresponding calculated spectral morphology shift value is -0.0554. Sampling period 5: Green reflectance 0.190, near-infrared reflectance 0.360, red-edge reflectance 0.270, red reflectance 0.160, and the minima are... The calculated spectral morphology shift value is 0.0454. This data is used to quantify and compare the spectral morphology shift values ​​for each sampling period in the multispectral telemetry data, and to provide directly applicable calculation inputs and results for subsequent anomaly period determination and structure vector replacement processing based on local statistical intervals.

[0030] Table 1. Spectral Morphology Offset Data

[0031] like Figure 3 As shown in the figure, the spectral morphology shift values ​​and structure vector retention results for five sampling periods are illustrated. The broken line represents the trajectory of the spectral morphology shift value as the sampling period changes. Different colors are used to distinguish the determination status of the points on the broken line: green points indicate that the spectral morphology shift value falls within the local statistical interval, and the structure vector for the corresponding sampling period is retained; red points indicate that the spectral morphology shift value exceeds the local statistical interval, and the corresponding sampling period is determined to be a spectral anomaly period, triggering structure vector replacement processing. Light green rectangular areas are used to mark the upper and lower boundaries of the local statistical interval for interval comparison of the spectral morphology shift values ​​for each sampling period. The corresponding spectral morphology shift value is labeled next to each sampling point for easy comparison of the shift amplitude across different sampling periods. Specifically, the spectral morphology shift values ​​for sampling periods 1, 2, and 5 are 0.0000, -0.0499, and 0.0454, respectively, all falling within the local statistical interval, corresponding to green points and retaining the current structure vector; the spectral morphology shift values ​​for sampling periods 3 and 4 are 0.0906 and -0.0554, respectively, exceeding the local statistical interval, corresponding to red points and undergoing anomaly replacement processing. Figure 3 The visualization method of "local statistical interval region + line trajectory + color judgment + numerical labeling" presents the interval judgment results of spectral morphology offset value in a structured way, providing a directly referenceable basis for retention / replacement judgment for subsequent splicing to form a spectral structure matrix.

[0032] In this implementation scheme, by forming a structural vector of green light reflectance, red light reflectance, red edge reflectance, and near-infrared reflectance in the sampling period dimension, and compressing the relative morphological differences of the four bands of reflectance into a bounded and comparable discriminant by using spectral morphological offset values, a unified structured expression of multispectral telemetry data is achieved. This enables the morphological differences of reflectance between sampling periods to be stably presented on the same numerical scale, reduces the impact of reflectance amplitude fluctuations on the morphological judgment boundary, and thus improves the consistency and reproducibility of subsequent abnormal period identification based on spectral morphological offset values.

[0033] Specifically, the steps for generating the spectral structure matrix by performing local statistical interval comparison and anomaly replacement processing on the spectral morphology shift values ​​according to the sampling period are as follows: A sliding window is established for the spectral morphology shift values ​​according to the sampling period. The window width is limited to three sampling periods. At the beginning of the sequence, the sliding window only includes the current sampling period and the next sampling period. At the end of the sequence, the sliding window only includes the previous sampling period and the current sampling period. The window contains the set of spectral morphology shift values ​​for the current sampling period and adjacent sampling periods. The local median and the absolute deviation of the local median of the spectral morphology shift values ​​within the window are calculated. The local median is the median of the spectral morphology shift values ​​within the window. The calculation yields the local median absolute deviation, calculated by taking the median of the absolute difference between the spectral morphology shift value and the local median within the window. The local statistical interval for the current sampling period is formed by the local median and the local median absolute deviation at a fixed multiple, with the fixed multiple ranging from two to four. The statistical interval formed by the local median and its absolute deviation uses robust statistics insensitive to extreme values ​​to express the local baseline and local dispersion, ensuring that occasional shifts in a single sampling period do not significantly affect the interval center and width. This maintains the continuity of the anomaly detection boundary for spectral morphology shift values ​​during cross-sampling period updates. The upper and lower boundaries of the local statistical interval are determined by… The local median and the absolute deviation of the local median at a fixed multiple are used to jointly determine the interval width, allowing it to adaptively change with the degree of local dispersion. The fixed multiple is limited to two to four to suppress misjudgments of slight noise fluctuations while maintaining anomaly sensitivity. The spectral morphology shift value is compared with the local statistical interval according to the sampling period: when the spectral morphology shift value falls within the local statistical interval, the current sampling period is marked as a normal spectral period, and the current structure vector is retained. This retention process includes directly outputting the current structure vector as the final structure vector. When the spectral morphology shift value exceeds the local statistical interval, the current sampling period is marked as an abnormal spectral period, and the current structure vector is replaced with the structure vectors of two adjacent normal spectral periods. The average value of the quantity and the replacement process include reading the normal periodic structure vector of the preceding spectrum and the normal periodic structure vector of the subsequent spectrum respectively, performing an arithmetic mean operation on each dimension component of the structure vector to obtain the replacement structure vector, and outputting the replacement structure vector as the final structure vector of the current sampling period. When there is only one adjacent normal periodic structure vector, the adjacent normal periodic structure vector is used as the replacement structure vector. Among them, the anomaly detection result based on the local statistical interval directly drives the structure vector replacement process, so that the anomaly judgment quantity and the multi-dimensional reflectance record form a linkage correction relationship within the same sampling period, avoiding inconsistencies between dimensions within the structure vector caused by only removing a single reflectance dimension.The structural vector replacement employs the arithmetic mean of adjacent spectral normal periodic structural vectors. This ensures the replacement result lies within the numerical envelope of adjacent normal morphologies and maintains consistency with the reflectance variation trend of the neighborhood. This prevents the subsequently constructed spectral derived feature groups and spectral coupled feature values ​​from being affected by isolated outliers during cross-sampling period calculations. An anomaly detection interval, formed by the absolute deviation between the local median and a fixed multiple of the local median, is combined with the replacement structural vector obtained by performing an arithmetic mean on adjacent spectral normal periodic structural vectors. This forms a collaborative processing strategy, providing robust anomaly triggering criteria for spectral morphology shift values ​​and a multi-dimensional consistent replacement carrier for structural vectors. Together, they reduce the damage to the inter-column correlation structure and sequence stability structure of the spectral structural matrix caused by abnormal sampling periods, making the feature statistics relied upon for subsequent correlation and sequence stability screening more stable, thus forming collaborative feature robustness. Finally, the final structural vectors from each sampling period are extracted and concatenated into a spectral structural matrix according to the sampling time order. The concatenation process uses the sampling period order as the row order and the order of the components within the structural vector as the column order to form a two-dimensional matrix representation.

[0034] In this implementation, by establishing a sliding window for the spectral morphology offset value in the sampling period dimension and generating a local statistical interval, and then performing retention processing and anomaly replacement processing on the structure vector based on the local statistical interval, the spectral structure matrix forms a stable continuous input structure in the time series, so that the occasional spectral anomaly period is consistent and corrected before entering the subsequent feature construction, reducing the risk of the propagation of abnormal fluctuations between sampling periods, thereby improving the stability and consistency of the spectral structure matrix when used for feature extraction across sampling periods.

[0035] Specifically, the steps for generating spectral derived feature groups from the spectral structure matrix according to the sampling period and constructing the spectral feature matrix are as follows: Read the spectral structure matrix, and read the green reflectance, red reflectance, red-edge reflectance, and near-infrared reflectance according to the sampling period. During reading, the starting timestamp of the sampling period is used as the index key to locate the current row record. The band input sequence of the current sampling period is fixed in the band order of "green reflectance, red reflectance, red-edge reflectance, near-infrared reflectance" to avoid feature column misalignment caused by differences in band arrangement across sampling periods. Perform difference operations, normalized difference operations, and ratio operations on pairwise combinations. Combine the operation results into spectral derived feature groups in a fixed order. The fixed pairing order is limited to "green reflectance and red reflectance, green reflectance and red-edge reflectance, green reflectance and near-infrared reflectance, red reflectance and red-edge reflectance, red-edge reflectance and near-infrared reflectance," and the difference operation is performed as "A minus B." The process generates differential features. Normalized difference operations are performed by dividing the result of A minus B by the sum of A plus B and the minus term. Ratio operations are performed by dividing A by the sum of B and the minus term. The minus term is a small but non-zero positive real number used to avoid numerical instability caused by the denominator approaching zero; its value range is limited to 10 to the power of -8 to 10 to the power of -5. A fixed order is established: within each band pairing, differential features are output first, followed by normalized difference features, and finally ratio features. These six pairings are then appended sequentially to generate complete spectral derived feature groups. The spectral derived feature groups are then concatenated in a fixed column order according to the sampling period to obtain a spectral feature matrix. This fixed column order follows a "pairing order first, operation type second" rule, writing all spectral derived features within the same sampling period as column vectors, while maintaining the sampling period order as the row order. This results in a two-dimensional matrix representation where rows correspond to sampling periods and columns correspond to spectral derived features.

[0036] In this implementation plan, the generation process of spectral derived feature groups is fully standardized and defined within the sampling period scale. This ensures that green reflectance, red reflectance, red-edge reflectance, and near-infrared reflectance have unified pairing relationships, column position mapping relationships, and numerical stability boundaries during feature construction. This guarantees that the spectral feature matrix maintains reproducible column semantic consistency and comparability under the conditions of cross-sampling period and cross-plot data incorporation, reduces the risk of feature drift caused by abnormal amplification due to feature column misalignment and denominator approaching zero, and provides a stable feature input benchmark for subsequent correlation screening and resampling screening based on soil organic matter measurements. This improves the engineering controllability and result consistency of the inversion input feature matrix construction stage.

[0037] Specifically, the steps for obtaining an effective feature matrix by performing correlation screening on the spectral feature matrix are as follows: Traverse the spectral feature matrix by feature column, read all sampling period values ​​for each column, and perform missing value verification on the column in sampling period order. Use linear interpolation to complete the missing sampling period values ​​to ensure that the correlation coefficient calculation is based on the same-dimensional sample sequence. Perform mean decentering on the completed column features to eliminate the influence of column mean shift on the covariance term. Mean decentering is performed by using the arithmetic mean of the column feature over all sampling periods as the center value and performing subtraction on the values ​​of each sampling period to obtain the centered sequence. Pair the current column feature with subsequent column features one by one. The pairing process is limited to ordered pairings where the current column index is less than the subsequent column index to avoid threshold determination conflicts caused by repeated pairings. Use the Pearson correlation coefficient algorithm to calculate the correlation coefficient for each pair of features. The correlation coefficient calculation process uses the covariance of the centered sequences of the two features divided by the product of the standard deviations of the centered sequences of the two features. Before calculating the correlation coefficient, perform zero variance verification on each column feature. When any column feature is within the same sampling period... When the variance within the period is zero, the column feature is marked as a constant feature column and removed to avoid undefined values ​​due to a zero standard deviation. The coefficient threshold is limited to 0.8 to 0.95, and the absolute value of the correlation coefficient for each pair of features is taken to uniformly handle redundant relationships of positive and negative correlation. When the absolute value of the correlation coefficient exceeds the coefficient threshold, it is determined that the current column feature has a high correlation with the subsequent column feature. The current feature column is retained, and the subsequent column feature is marked as a redundant candidate column for direct skipping in subsequent pairing decisions. The redundant candidate columns are recorded in the form of column indexes and the index uniqueness is maintained. When the absolute value of the correlation coefficient is less than or equal to the coefficient threshold, it is determined that the current column feature does not have a high correlation with the subsequent column feature. The current feature column is retained and continues to participate in subsequent pairing calculations. After completing all ordered pairing traversals, the column indexes marked as redundant candidate columns are uniformly removed. The retained feature columns are concatenated in the original column order to construct an effective feature matrix. The effective feature matrix maintains the row order of the sampling period and keeps the column index monotonically increasing to ensure consistency with the feature column index mapping relationship of subsequent resampling and filtering processes.

[0038] In this implementation scheme, detailed correlation screening and resampling of the spectral feature matrix effectively eliminates the impact of highly correlated redundant features on subsequent data processing, improving the stability and accuracy of the feature matrix. This method ensures the independence and data consistency of each feature column by introducing steps such as missing data validation, mean decentering, and zero-variance validation. Furthermore, using Pearson correlation coefficients for feature column pairing effectively removes redundant feature columns, retaining features highly correlated with the soil organic matter inversion results, further enhancing the predictive ability of the inversion model. This process provides a more concise and high-quality feature set for subsequent feature input and model training, improving the model's stability and cross-temporal adaptability.

[0039] Specifically, the steps for resampling and screening the effective feature matrix and calculating the probability of feature columns being selected to construct the inverted input feature matrix are as follows: Using the effective feature matrix as the input feature set for the competitive adaptive resampling algorithm, and soil organic matter measurements as the target values, the effective feature matrix is ​​checked for column order according to the feature column index before input, and the consistency of the column index numbers is fixed to ensure that the feature column indices of each resampling run correspond one-to-one; the competitive adaptive resampling algorithm is run N times, where N ranges from 300 to 800. Each run performs random resampling of the feature columns of the effective feature matrix based on the same set of soil organic matter measurements and outputs a set of selected feature column indices. The set of selected feature column indices is in ascending order. The indexes are arranged and deduplicated to maintain their uniqueness. For N runs, the number of times each feature column index is selected is counted. This process iterates through all runs by feature column index and accumulates the counts. The selection probability is obtained by dividing the number of selections by N, and this probability quantifies the stability of feature columns during the resampling process. Feature column indices with a selection probability exceeding 50% are extracted. The extraction process outputs the results in ascending order of feature column index and performs threshold consistency checks to avoid inconsistencies in the probability statistics for the same feature column across different runs. The effective feature matrix columns corresponding to the extracted feature columns are then concatenated in ascending order of column index, maintaining the row order of the sampling period, to construct the inverted input feature matrix.

[0040] In this implementation scheme, by introducing the selection probability as a stability measure on the basis of the effective feature matrix, and using a unified feature column index caliber throughout the resampling and screening process, the feature composition of the inversion input feature matrix has repeatable screening criteria and traceable selection records. Thus, even under the condition of sample perturbation, the consistency of the feature set of the inversion input feature matrix can still be maintained, reducing the risk of inversion result drift caused by fluctuations in the feature set with the running batch, and providing a stable input space for the training stage of the random forest regression model.

[0041] Specifically, the specific steps for constructing training and validation sets based on the inversion input feature matrix and soil organic matter measurement values, training a random forest regression model using the training set, and outputting the soil organic matter inversion sequence based on the random forest regression model are as follows: Read the inversion input feature matrix; read the values ​​of each feature column of the inversion input feature matrix according to the sampling period and perform a dimensionality consistency check. The dimensionality consistency check includes verifying that the number of sampling periods and the number of feature columns meet the preset matrix size constraint and verifying that there are no empty rows in the row vectors of each sampling period; extract the spectral morphology shift value according to the sampling period, and write the spectral morphology shift value as a fixed column feature in the training input vector. The fixed column order is defined as following the column index. The inversion input feature matrix is ​​arranged in ascending order, with all feature columns fixed to ensure that the training set, validation set, and real-time inversion input can directly reuse the same random forest regression model under the condition of consistent column semantics. Numerical validity verification is performed on the training input vector, including identifying non-numerical labels and infinity labels, marking the corresponding sampling period row vectors as invalid row vectors, removing invalid row vectors based on the invalid labels, and simultaneously removing the corresponding elements from the training output vector. Historical soil organic matter measurements are read from ground sampling operation records according to the sampling period. Historical soil organic matter measurements are measured in grams per kilogram and linked to the sampling timestamp within the same period. The relationship between the training input vector and the validation input vector is used to provide supervision for each training input vector. The training input vector is divided into a training set and a validation set with a fixed step size of two to ten. The sampling period sequence is then sampled at equal intervals according to the fixed step size to form the validation set index set. The sampling period index sets that are not sampled form the training set index set. The index partitioning process maintains the temporal order of the sampling periods and avoids adjacent sampling periods from simultaneously entering the validation set to reduce the underestimation of validation error by temporally adjacent samples. Based on the training set index set, the training input vector and training output vector are extracted. A random forest regression model is then trained using the training set. The number of trees in the regression model ranges from 100 to 500, the maximum depth of a single tree ranges from 5 to 20, and the minimum number of samples per node ranges from 2 to 10. The feature subset extraction rule adopts a fixed proportion extraction, which is limited to 30% to 70%. The sampling rule adopts sampling with replacement to form an out-of-bag sample set, which is used to monitor synchronous errors during the training process. During regression training, regression trees are generated sequentially according to tree number, and the mean squared error reduction is used as the splitting criterion in the splitting calculation of each regression tree. The splitting calculation is only performed when the number of samples per node is not less than the minimum number of samples per node. The splitting termination conditions include reaching the maximum depth constraint and reaching the lower limit constraint of the number of samples per node.After regression training, the validation set is input into the random forest regression model to obtain the validation inversion output. The validation inversion output is obtained by taking the arithmetic mean of the tree outputs. The inversion error sequence is calculated based on the absolute value of the difference between the validation inversion output and the soil organic matter measurement values ​​of the validation set, and the arithmetic mean of the inversion error sequence is obtained. At the same time, the out-of-bag error average is calculated for the out-of-bag sample set to form a training error control. When the inversion error average is less than the error threshold and the out-of-bag error average is less than the out-of-bag threshold, the random forest regression model is considered to have completed training. The error threshold and the out-of-bag threshold are both between five and fifteen. After the random forest regression model training is completed, real-time data is read. The input feature matrix is ​​inverted and subjected to a fixed column order verification consistent with the training phase. After successful verification, the real-time inverted input feature matrix is ​​input into the random forest regression model in the order of sampling periods, outputting the soil organic matter inversion values ​​corresponding to each sampling period. A range constraint verification is performed on the output soil organic matter inversion value sequence. This includes correcting inversion values ​​less than zero to zero while retaining the correction marker, associating the inversion values ​​with the sampling period identifier and sampling timestamp, and writing them into the inversion result record. The soil organic matter inversion sequence is then combined according to the sampling period order to obtain the soil organic matter inversion sequence. This sequence provides continuous temporal inversion input for subsequent spatial interpolation and raster construction based on sampling point coordinates.

[0042] In this implementation scheme, by introducing fixed column order verification, numerical validity verification, stratified sampling, and error monitoring mechanisms during the soil organic matter inversion process, the present invention improves the stability and accuracy of the inversion model. Specifically, by rationally dividing the sampling period and independently extracting the training and validation sets, the consistency of the model over time is ensured, avoiding the risk of overfitting. Simultaneously, the training process of the random forest regression model, through strict tree structure settings and error monitoring, ensures the high reliability of the inversion output. Furthermore, the processing of the real-time inversion input feature matrix and the consistency verification of the training set enhance the applicability of the inversion results, making the soil organic matter inversion sequence more accurate and widely applicable.

[0043] Specifically, the steps for establishing a pixel index and generating a soil organic matter inversion image based on the pixel index and soil organic matter inversion sequence are as follows: A pixel index table is established based on preprocessed multispectral telemetry data. The pixel index table includes pixel row number, pixel column number, pixel center coordinates, pixel spectral data, and valid pixel markers. The pixel center coordinates are determined by the georegistration parameters, pixel row number, and pixel column number of the preprocessed multispectral telemetry data. The pixel spectral data includes the green reflectance, red reflectance, red-edge reflectance, and near-infrared reflectance corresponding to the same pixel. Row and column continuation is performed on the pixel index table. The process includes verification of pixel validity, coordinate validity, and pixel spectral data integrity. If a pixel spectral data contains null values ​​or a valid pixel marker is invalid, the corresponding pixel is removed from the raster reconstruction process. The soil organic matter inversion sequence is read, which includes the soil organic matter inversion value corresponding to each pixel. A correspondence is established between the soil organic matter inversion value corresponding to each pixel and the pixel row number and pixel column number in the pixel index table. Raster reconstruction is performed on the soil organic matter inversion value corresponding to each pixel according to the pixel row number and pixel column number to construct a soil organic matter inversion raster matrix. Each matrix element in the soil organic matter inversion raster matrix is ​​associated with a unique pixel. The metacenter coordinates are bound; the soil organic matter inversion raster matrix is ​​converted into an inversion visualization matrix according to a fixed color-level mapping table; the fixed color-level mapping table consists of the lower limit of soil organic matter inversion values, the upper limit of soil organic matter inversion values, the number of segments, the segment boundary values, the color-level number, and the display color value. The lower limit and upper limit of soil organic matter inversion values ​​are determined based on the range of soil organic matter measurement values ​​in the training set. The segment boundary values ​​are generated between the lower limit and the upper limit of soil organic matter inversion values ​​in an equidistant segmentation manner. Each segment boundary value interval corresponds to a color-level number and a display color value; before conversion, the soil organic matter... The soil organic matter inversion values ​​in the quality inversion raster matrix are truncated at both the upper and lower limits. Inversion values ​​below the lower limit of soil organic matter inversion values ​​are mapped according to the lower limit, while inversion values ​​above the upper limit of soil organic matter inversion values ​​are mapped according to the upper limit. The corresponding color level number and display color value are determined according to the segment boundary value interval to which the truncated soil organic matter inversion values ​​belong, generating an inversion visualization matrix. Based on the inversion visualization matrix, a soil organic matter inversion image is generated. The soil organic matter inversion image retains the correspondence between the pixel row and column index and the pixel center coordinates, and includes a color level mapping table number for result reproduction.

[0044] In this embodiment, by performing spatial interpolation and raster construction on the soil organic matter inversion sequence, the present invention can smoothly map the discrete sampling point inversion results onto a continuous spatial grid, thereby achieving a high-precision image of soil organic matter distribution. This method effectively solves the problem of discontinuity in inversion results caused by sparse sampling points or uneven spatial distribution in traditional methods, ensuring the consistency and visualization effect of the inverted image at the plot scale. Furthermore, the use of an inverse distance weighted algorithm for spatial interpolation effectively avoids the influence of extreme values ​​on the interpolation results, improving the stability and reliability of the inversion results. By maintaining the correspondence between sampling point coordinates and inversion values ​​and finely controlling the color level mapping, the spatial distribution accuracy of soil organic matter is improved.

[0045] like Figure 2 As shown, the second aspect of this invention provides a soil organic matter inversion system based on UAV multispectral data, comprising: a data acquisition and preprocessing module, a spectral structure matrix construction module, a spectral feature screening and generation module, and a soil organic matter inversion module. The data acquisition and preprocessing module is used to periodically acquire multispectral telemetry data and soil feature data, and to perform brightness alignment, image synchronization, smoothing, anomaly removal, interpolation completion, and standardization processing on the acquired data. The spectral structure matrix construction module is used to construct band reflectance vectors and spectral morphology offset values ​​based on the preprocessed multispectral telemetry data, and to perform local statistical interval comparison and anomaly replacement processing on the spectral morphology offset values ​​according to the sampling period to generate the spectral structure. The system comprises several modules: a spectral feature filtering and generation module, which generates spectral derived feature groups based on the spectral structure matrix according to the sampling period, constructs a spectral feature matrix, performs correlation filtering on the spectral feature matrix to obtain an effective feature matrix, performs resampling filtering on the effective feature matrix and counts the probability of feature columns being selected, and constructs an inversion input feature matrix; a soil organic matter inversion module, which constructs training and validation sets based on the inversion input feature matrix and soil organic matter measurements, trains a random forest regression model using the training set, and outputs a soil organic matter inversion sequence based on the random forest regression model; and establishes a pixel index and performs pixel raster reconstruction based on the pixel index and the soil organic matter inversion sequence to generate a soil organic matter inversion image.

[0046] like Figure 4As shown in the figure, the inversion accuracy of the self-organizing map model for soil organic matter is compared. The horizontal axis represents the measured soil organic matter values ​​obtained from ground sampling, and the vertical axis represents the inverted soil organic matter values ​​output by the self-organizing map model after inputting the inversion input feature matrix. Scatter dots represent the sample comparison results corresponding to the coordinates of each sampling point. Different colored scatter dots correspond to training set samples and validation set samples, respectively. The color labels are determined based on the training set partitioning marker and the validation set partitioning marker. The solid lines of the same color represent the linear fitting relationship of the corresponding sample sets, used to characterize the overall consistency trend of soil organic matter inversion values ​​with changes in soil organic matter measured values. The orange dashed line is the ideal consistency line, representing the reference relationship when the soil organic matter inversion values ​​and soil organic matter measured values ​​are completely consistent. The evaluation metrics marked in the figure are used to quantify the model's inversion performance: the coefficient of determination for the training set fitting results is 0.88, the root mean square error is 10.18 (26.7%), and the mean absolute error is 8.13; the coefficient of determination for the validation set fitting results is 0.87, the root mean square error is 10.66 (28.0%), and the mean absolute error is 8.70; the percentages in parentheses represent the relative error of the root mean square error to the mean soil organic matter measurement values ​​of the corresponding sample sets. By comparing the fitting line positions, scatter point distribution dispersion, and various error metrics between the training and validation sets, the consistency of the self-organizing map model's fit to the soil organic matter measurement values ​​driven by the current inversion input feature matrix can be intuitively reflected. This provides a quantifiable accuracy basis for subsequently constructing inversion images by performing spatial interpolation of the soil organic matter inversion sequence according to the sampling point coordinates.

[0047] In this implementation plan, the comprehensive acquisition and preprocessing of multispectral telemetry data and soil characteristic data ensured high data quality and consistency. The further constructed spectral structure matrix and spectral feature matrix, through precise correlation screening and resampling, effectively eliminated redundant features, improving feature robustness and the accuracy of the inversion model. During training, the random forest regression model, through repeated validation on training and validation sets, ensured the reliability and stability of the inversion results. Finally, spatial interpolation and raster construction techniques transformed the inversion results from discrete data into continuous spatial imagery, providing a visualized soil organic matter distribution map. This further promoted the application of precision agricultural management and soil quality monitoring, providing a scientific basis for farmland management and decision-making.

[0048] It should be noted that, in this document, relational terms such as "first" and "second" are used only to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such process, method, article, or apparatus.

[0049] The preferred embodiments of the present invention disclosed above are merely illustrative of the invention. These preferred embodiments do not exhaustively describe all details, nor do they limit the invention to the specific implementations described. Clearly, many modifications and variations can be made based on the content of this specification. This specification selects and specifically describes these embodiments to better explain the principles and practical applications of the invention, thereby enabling those skilled in the art to better understand and utilize the invention. The invention is limited only by the claims and their full scope and equivalents.

Claims

1. A method for soil organic matter inversion based on UAV multispectral imaging, characterized in that, Includes the following steps: S1 periodically collects multispectral telemetry data and soil characteristic data, and performs brightness alignment, image synchronization, smoothing, anomaly removal, interpolation completion and standardization on the collected data; S2, construct the band reflectance vector and spectral shape offset value based on the preprocessed multispectral telemetry data, perform local statistical interval comparison and anomaly replacement processing on the spectral shape offset value according to the sampling period, and generate the spectral structure matrix; The specific steps for performing local statistical interval comparison and anomaly replacement processing on the spectral morphology offset values ​​according to the sampling period to generate the spectral structure matrix are as follows: A sliding window is established for the spectral morphology shift values ​​according to the sampling period. The window contains the set of spectral morphology shift values ​​of the current sampling period and the adjacent sampling periods. The local median and the absolute deviation of the local median of the spectral morphology shift values ​​within the window are calculated, and the local statistical interval of the current sampling period is formed by the local median and the absolute deviation of the local median by a fixed multiple. The spectral morphology shift value is compared with the local statistical interval according to the sampling period: when the spectral morphology shift value falls into the local statistical interval, the current sampling period is marked as a normal spectral period and the current structure vector is retained; when the spectral morphology shift value exceeds the local statistical interval, the current sampling period is marked as an abnormal spectral period and the current structure vector is replaced with the average of the structure vectors of the two adjacent normal spectral periods; and the final structure vectors of each sampling period are extracted and concatenated into a spectral structure matrix in the order of sampling time. S3. Generate spectral derived feature groups based on the spectral structure matrix according to the sampling period, construct a spectral feature matrix, perform correlation screening on the spectral feature matrix to obtain an effective feature matrix, perform resampling screening on the effective feature matrix, and construct an inversion input feature matrix. S4. Based on the inversion input feature matrix and soil organic matter measurement values, a training set and a validation set are constructed. The training set is used to train a random forest regression model, and the soil organic matter inversion sequence is output based on the random forest regression model. A pixel index is established, and pixel raster reconstruction is performed based on the pixel index and the soil organic matter inversion sequence to generate soil organic matter inversion image.

2. The method for soil organic matter inversion based on UAV multispectral imaging according to claim 1, characterized in that: The specific steps for periodically acquiring multispectral telemetry data and soil characteristic data, and performing brightness alignment, image synchronization, smoothing, anomaly removal, interpolation completion, and standardization on the acquired data are as follows: A fixed-width sliding time window is set as one sampling period to periodically collect multispectral telemetry data, including green reflectance, red reflectance, red-edge reflectance, near-infrared reflectance, surface incident light intensity, and sampling timestamps. Soil characteristic data are also collected through ground sampling operations, including soil organic matter measurements and sampling point coordinates. Multispectral telemetry data and soil characteristic data within each sampling period are recorded in chronological order to construct a multispectral soil observation dataset. For multispectral soil observation data, histogram matching algorithm and affine transformation resampling algorithm are used to perform brightness alignment and image synchronization processing on multi-source time-series records; adaptive median filtering algorithm is used to perform dynamic smoothing suppression on local noise segments and brightness abrupt segments in multispectral soil observation data; bilateral Hanning window filtering algorithm is used to identify and remove abnormal pixels and boundary gradient segments in multispectral soil observation data, and bicubic convolution interpolation algorithm is used to continuously complete short-term missing data; min-max normalization algorithm is used to perform scale normalization processing on multispectral soil observation data to unify numerical scale and eliminate dimensional differences.

3. The method for soil organic matter inversion based on UAV multispectral imaging according to claim 1, characterized in that: The specific steps for constructing the band reflectance vector and spectral morphology shift value based on the preprocessed multispectral telemetry data are as follows: Based on the preprocessed multispectral telemetry data, green light reflectance, red light reflectance, red edge reflectance and near-infrared reflectance are read according to the sampling period to construct the band reflectance vector within the sampling period; and the spectral morphology shift value is calculated based on the band reflectance vector. The spectral morphology shift value is merged with the corresponding band reflectance vector to obtain the structure vector of the corresponding sampling period. Add the green reflectance and near-infrared reflectance, take half of the result, and then subtract the red edge reflectance to obtain the mid-spectral difference. Add the absolute value of the difference between the red edge reflectance and the red light reflectance to the minimum term to obtain the red edge gradient. Divide the mid-spectral difference by the red edge gradient and perform hyperbolic tangent operation on the resulting ratio to obtain the spectral morphology shift value for the current sampling period.

4. The method for soil organic matter inversion based on UAV multispectral imaging according to claim 1, characterized in that: The specific steps for generating spectral derived feature groups based on the spectral structure matrix according to the sampling period and constructing the spectral feature matrix are as follows: Read the spectral structure matrix, and read the green light reflectance, red light reflectance, red edge reflectance and near-infrared reflectance according to the sampling period. Perform difference operation, normalized difference operation and ratio operation in pairs, and combine the operation results into spectral derived feature groups in a fixed order. Then, splice the spectral derived feature groups in a fixed column order according to the sampling period to obtain the spectral feature matrix.

5. The method for soil organic matter inversion based on UAV multispectral imaging according to claim 1, characterized in that: The specific steps for performing correlation screening on the spectral feature matrix to obtain an effective feature matrix are as follows: Traverse the spectral feature matrix by feature column, read all sampling period values ​​of each feature column, and pair the current feature column with the subsequent feature columns one by one. Use the Pearson correlation coefficient algorithm to calculate the correlation coefficient for each pair of features. When the absolute value of the correlation coefficient exceeds the coefficient threshold, retain the current feature column. When the absolute value of the correlation coefficient is less than or equal to the coefficient threshold, remove the current feature column. Concatenate the retained feature columns in the original column order to construct the effective feature matrix.

6. The method for soil organic matter inversion based on UAV multispectral imaging according to claim 1, characterized in that: The specific steps for performing resampling and filtering on the effective feature matrix and calculating the probability of feature columns being selected to construct the inverted input feature matrix are as follows: The effective feature matrix is ​​used as the input feature set of the competitive adaptive resampling algorithm, and the soil organic matter measurement value is used as the target value. The competitive adaptive resampling algorithm is run N times repeatedly, and each run outputs a set of selected feature column indices. The number of times each feature column index is selected is counted for the N runs, and the selection probability is obtained by dividing the number of selections by N. Feature column indices with a selection probability of more than 50% are extracted, and the effective feature matrix columns corresponding to the extracted feature columns are concatenated in ascending order of column index to construct the inversion input feature matrix.

7. The method for soil organic matter inversion based on UAV multispectral imaging according to claim 1, characterized in that: The specific steps for constructing training and validation sets based on the inverted input feature matrix and soil organic matter measurement values, training a random forest regression model using the training set, and outputting the soil organic matter inversion sequence based on the random forest regression model are as follows: Read the inverted input feature matrix, extract the spectral morphology shift values ​​according to the sampling period, and combine them in a fixed column order to form the training input vector; read the historical soil organic matter measurement values ​​from the ground sampling operation records according to the sampling period to form the training output vector; The training input vector is divided into a training set and a validation set with a fixed step size, and the random forest regression model is trained using the training set. After regression training, the validation set is input into the random forest regression model to obtain the validation inversion output. The average inversion error is calculated based on the difference between the validation inversion output and the measured soil organic matter value in the validation set. When the average inversion error is less than the error threshold, the random forest regression model is considered to have completed training. After the random forest regression model is trained, the real-time inversion input feature matrix is ​​input into the random forest regression model in the order of sampling period, and the soil organic matter inversion value corresponding to each sampling period is output. The soil organic matter inversion sequence is obtained by combining the values ​​in the order of sampling period.

8. The method for soil organic matter inversion based on UAV multispectral imaging according to claim 1, characterized in that: The specific steps for establishing a pixel index and performing pixel raster reconstruction based on the pixel index and the soil organic matter inversion sequence to generate a soil organic matter inversion image are as follows: A pixel index table is established based on the preprocessed multispectral telemetry data. The pixel index table records the pixel row number, pixel column number, pixel center coordinates, and pixel spectral data. The soil organic matter inversion sequence is read, and the soil organic matter inversion values ​​corresponding to each pixel are used to construct a soil organic matter inversion raster matrix according to the pixel index table. The soil organic matter inversion raster matrix is ​​converted into an inversion visualization matrix according to a fixed color level mapping table, and the soil organic matter inversion image is generated by combining the pixels in row and column order.

9. A soil organic matter inversion system based on UAV multispectral imaging, employing the soil organic matter inversion method based on UAV multispectral imaging as described in any one of claims 1-8, characterized in that, include: The module includes a data acquisition and preprocessing module, a spectral structure matrix construction module, a spectral feature screening and generation module, and a soil organic matter inversion module, among which: The data acquisition and preprocessing module is used to periodically acquire multispectral telemetry data and soil characteristic data, and to perform brightness alignment, image synchronization, smoothing, anomaly removal, interpolation completion and standardization on the acquired data. The spectral structure matrix construction module is used to construct band reflectance vectors and spectral shape offset values ​​based on preprocessed multispectral telemetry data, and to perform local statistical interval comparison and anomaly replacement processing on the spectral shape offset values ​​according to the sampling period to generate a spectral structure matrix. The spectral feature filtering and generation module is used to generate spectral derived feature groups based on the spectral structure matrix according to the sampling period, construct a spectral feature matrix, perform correlation filtering on the spectral feature matrix to obtain an effective feature matrix, perform resampling filtering on the effective feature matrix and count the probability of feature columns being selected, and construct an inversion input feature matrix. The soil organic matter inversion module is used to construct training and validation sets based on the inversion input feature matrix and soil organic matter measurement values, train a random forest regression model using the training set, and output a soil organic matter inversion sequence based on the random forest regression model; establish a pixel index, and perform pixel raster reconstruction based on the pixel index and the soil organic matter inversion sequence to generate a soil organic matter inversion image.

Citation Information

Patent Citations

  • A method for estimating soil organic matter content using spectrum

    CN113358584B

  • Estimation method of soil organic matter content

    CN117929325A