Wheat nitrogen content detection method based on SG-CWT coupled SPA characteristic dynamic dimension reduction

By employing the SG-CWT and SPA feature dynamic dimensionality reduction methods, the problems of feature redundancy and model generalization in wheat leaf nitrogen content detection were solved, enabling efficient and real-time nitrogen content monitoring that meets the detection needs of different growth stages and varieties.

CN121521765APending Publication Date: 2026-02-13EAST CHINA AGRI-TECH CENTER OF CHINESE ACADEMY OF AGRICULTURAL SCIENCES +1
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202511504241.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-10-21
Publication Date
2026-02-13

AI Technical Summary

Technical Problem

Existing methods for detecting nitrogen content in wheat leaves suffer from problems such as crude feature construction, insufficient model generalization ability, and low deployment efficiency, resulting in low detection accuracy and difficulty in real-time application.

Method used

A feature dynamic dimensionality reduction method based on SG-CWT coupled with SPA is adopted. Through efficient feature compression, dynamic modeling and robust optimization, a lightweight modeling framework is constructed to achieve signal enhancement, feature purification and intelligent optimization, which can adapt to different growth stages and variety differences.

Benefits of technology

It significantly improves detection accuracy, reduces model computational overhead and runtime latency, and enables efficient nitrogen content monitoring, making it suitable for real-time field applications.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121521765A_ABST
    Figure CN121521765A_ABST
Patent Text Reader

Abstract

The invention relates to a wheat nitrogen content detection method based on SG-CWT coupled SPA feature dynamic dimension reduction, which comprises the following steps: constructing a dynamic feature purification mechanism, and carrying out efficient feature compression and significant variable screening; a dynamic modeling and robust optimization mechanism is introduced to enhance the adaptability to the time sequence and variety difference; a lightweight modeling framework is provided to reduce model calculation overhead and operation delay. According to the method, a signal enhancement-feature purification-intelligent modeling cascade optimization system is constructed, multi-scale feature deep mining is achieved, compared with a traditional method, the number of feature wavebands is increased by 83%, a dynamic dimension reduction mechanism under the precision loss constraint is provided, the RMSE amplification smaller than 5% is used as a threshold value to screen the optimal waveband combination, 97.2% of model performance is reserved only through 24 wavebands, and the method has the advantages of being high in robustness, high in accuracy and high in accuracy. According to the provided swarm intelligence-driven heterogeneous model collaborative optimization architecture, prediction errors are compressed to an agronomy applicable standard, and a technical case giving consideration to mechanism interpretability and landing feasibility is established for hyperspectral agricultural condition monitoring.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of hyperspectral data processing, and particularly relates to a hyperspectral data feature dimension reduction method for wheat nitrogen content detection. BACKGROUND

[0002] Nitrogen is the core element for the synthesis of chlorophyll, protein and enzyme in wheat leaves, and directly affects photosynthetic efficiency, dry matter accumulation and grain yield. Traditional nitrogen content detection relies on laboratory chemical analysis, which has defects such as destructive sampling, poor timeliness and high cost, and is difficult to meet the real-time monitoring needs of precision agriculture. In recent years, the integration of hyperspectral remote sensing, unmanned aerial imaging and machine learning technology has provided a new way for non-destructive monitoring of wheat leaf nitrogen content, but the existing methods still have significant limitations.

[0003] Firstly, the feature construction is extensive. For example, the precision is improved by constructing a new type of vegetation index (NAVI), but the model relies on the combination of original spectral bands, and does not solve the problem of noise interference of high-dimensional data, with RMSE of 0.398 mg / g, and the error increases to 0.52 mg / g when applied across ecological zones (reference Monitoring of nitrogen accumulation in wheat plants based on hyperspectral data); Guo et al. constructed a hyperspectral prediction model for wheat leaf nitrogen accumulation based on continuum removal method, but the model stability is insufficient due to the neglect of multiple collinearity between features, with root mean square error of 0.89 g / m 2 (reference Hyperspectral assessment of leaf nitrogen accumulation for winter wheat using different regression modeling).

[0004] Secondly, the model generalization ability is insufficient. Although some researches have tried to introduce continuous wavelet transform (CWT) to enhance the spectral feature extraction capability (such as patent CN106323466A), most of them have not designed a dynamic modeling strategy that adapts to different growth periods and varieties. Specifically, the spectral response difference between the green-up period and the flowering period is more than 60%, and the phenotype difference between spring wheat and winter wheat is also significant, and the current model lacks robustness in dealing with these temporal and variety variability. In addition, the model training relies on full-band information, and lacks effective feature selection and dynamic adaptation mechanism, resulting in a significant decrease in precision when applied across regions or years, which seriously restricts its popularization and application.

[0005] Finally, the existing methods are generally characterized by serious feature redundancy and insufficient model lightweight. Although the existing scheme represented by CN106323466A uses CWT to enhance signal features, it does not integrate an automatic dimension reduction mechanism, resulting in high feature dimension and large parameter quantity of the model. Taking a random forest (RF) as an example, the model usually needs to build hundreds of decision trees, which has high computational complexity and large resource occupation, and is difficult to deploy on a handheld or unmanned aerial vehicle platform in the field. At the same time, the variance inflation factor of some high-dimensional features is greater than 10, which has serious multicollinearity, making the model more inclined to become a “mathematical black box” and having poor interpretability. Most schemes use more than 100 feature bands, which significantly increases the model reasoning delay and device load, and is difficult to meet the demand of real-time diagnosis in the field. Therefore, it is urgent to build an efficient modeling strategy that integrates signal enhancement, dynamic dimension reduction and intelligent optimization to break through the three bottlenecks of feature redundancy, poor model generalization and insufficient lightweight.

[0006] In order to improve the cross-growth-period adaptability and field deployment efficiency of wheat leaf nitrogen content detection, the present application breaks through the limitations of traditional continuous wavelet transform (CWT) application and proposes a wheat leaf nitrogen content lightweight detection method that integrates two-stage signal enhancement, dynamic feature purification and swarm intelligence optimization. The method builds a “signal enhancement-feature purification-intelligent modeling” joint optimization system to address the three technical bottlenecks of extensive feature construction, weak model generalization and low deployment efficiency in current research. SUMMARY

[0007] The present application aims to overcome the problems existing in the prior art and provide a wheat nitrogen content detection method based on SG-CWT coupled with SPA feature dynamic dimension reduction.

[0008] To achieve the above technical purposes and effects, the present application realizes the following technical solutions:

[0009] A wheat nitrogen content detection method based on SG-CWT coupled with SPA feature dynamic dimension reduction, the method comprising: building a dynamic feature purification mechanism for efficient feature compression and significant variable selection; introducing a dynamic modeling and robust optimization mechanism to enhance the adaptability to time series and variety differences; and providing a lightweight modeling framework to reduce model computation overhead and running delay.

[0010] Further, the method specifically comprises the following steps:

[0011] First, to address the problems of serious feature redundancy and high-dimensional collinearity, the present application builds a dynamic feature purification mechanism to achieve efficient feature compression and significant variable selection, as follows:

[0012] Step S1: Obtain hyperspectral data of wheat canopy leaves in the range of 350 nm-2500 nm;

[0013] Step S2: Collect the wheat leaf sample within the spectral acquisition point 5m range according to the five-point sampling method, and after fixation and drying, determine the leaf nitrogen content as the true value label for model training;

[0014] Step S3: The original hyperspectral data in step S1 is preprocessed to suppress noise and improve signal-to-noise ratio (SNR>40dB);

[0015] Step S4: Select the Gaussian eight-order derivative wavelet basis function gaus8, and perform continuous wavelet transform decomposition on the preprocessed spectrum at the Scale_64 core scale (compared with Scale_2 to Scale_1024, a total of 10 scales) to generate a wavelet reflectivity matrix (scale x waveband), realizing multi-scale feature mining (the number of feature wavebands is increased by 83% compared with traditional methods);

[0016] Step S5: Based on the successive projection algorithm SPA (Successive Projections Algorithm, SPA), the optimal waveband combination is selected with the constraint threshold of RMSE increase amplitude ≤5%, which compresses the original waveband number by more than 80%, significantly reduces the variance inflation factor, and effectively alleviates the multicollinearity problem between features;

[0017] Secondly, in view of the problems of weak model generalization ability and decreased accuracy across growth periods, the application introduces a dynamic modeling and robust optimization mechanism to enhance the adaptability to time series and variety differences, as follows:

[0018] Step S6: Combine the sample time series characteristics to design a cross-growth period training set structure, which covers representative samples from the green-up period to the flowering period, solving the problem of lack of adaptation to spectral response differences (>60%) of existing models;

[0019] Step S7: Taking the significant variable of wheat leaf nitrogen content as the independent variable of the model input, and taking the wheat nitrogen content as the dependent variable, XGBoost (Extreme Gradient Boosting) model and extreme learning machine model ELM (Extreme Learning Machine, ELM) are established respectively, and the differences between different models are compared;

[0020] Step S8: The sparrow search algorithm SSA (Sparrow Search Algorithm, SSA) is used to optimize the XGBoost model hyperparameters (iteration number=100, population size=30); the artificial hummingbird algorithm AHA (Artificial Hummingbird Algorithm, AHA) is used to optimize the extreme learning machine model ELM hyperparameters (honey source number=20, maximum iteration=100);

[0021] Finally, in view of the problems of low deployment efficiency and difficulty in real-time application in the field, the application proposes a lightweight modeling framework, which effectively reduces model calculation overhead and running delay, as follows:

[0022] Step S9: Through the feature compression + parameter optimization double mechanism, the final input variable number is controlled within a certain number, so as to greatly reduce the model complexity;

[0023] Step S10: Taking the numerical value of the selected agronomic applicability standard MAPE as the agricultural applicability threshold, a lightweight high-precision prediction model of wheat leaf nitrogen content is established, so as to significantly improve the deployment convenience and field popularization value.

[0024] Further, in the step S4, the continuous wavelet transform decomposes the wheat leaf canopy spectral data at different scales, and the calculation formula is as follows:

[0025]

[0026] Wherein, f(lambda) is the spectral reflectivity, lambda is the spectral band number in the range of 350nm-2500nm, psi a,b is the wavelet base function, a is the scale factor, b is the translation factor, the wavelet coefficient W f (a,b) contains two-dimensional data, respectively, the band and the scale; the generation behavior scale number, column as the band number matrix; in Python, the CWT transform is performed on the wheat canopy spectrum, and the decomposition scale is set to 10 scales; the Gaussian function derivative form gaus8 is selected as the wavelet base function, and finally the wavelet reflectivity data set after wavelet decomposition is obtained, which is used for subsequent analysis and modeling.

[0027] Further, in the step S5, the continuous projection algorithm SPA is adopted, and its iteration process is approximately represented as:

[0028]

[0029] Wherein, represents the submatrix corresponding to the selected band, is X j The residual on the orthogonal complement of the selected subspace.

[0030] Further, in the step S3, the fixation temperature is 120 DEG C, the drying temperature is 65 DEG C, and the Kjeldahl method is used to determine the leaf nitrogen content (unit: mg / g).

[0031] Further, in the step S3, the Savitzky-Golay filter is used to suppress noise, and the window width is 11 and the polynomial order is 3.

[0032] Further, in the step S10, the agricultural applicability threshold is set as the agronomic applicability standard MAPE < 9.5%.

[0033] The beneficial effects of the present application are:

[0034] Compared with the existing wheat leaf nitrogen content detection technology, the present application constructs a "signal enhancement-feature purification-intelligent modeling" cascade optimization system. First, the SG-CWT two-stage preprocessing framework realizes multi-scale feature deep mining at Scale_64 scale, and the number of feature wavebands is increased by 83% compared with the traditional method; second, a dynamic dimension reduction mechanism under the precision loss constraint is proposed, and the optimal waveband combination is selected with an RMSE increase threshold of less than 5%, and only 24 wavebands are used to retain 97.2% of the model performance; finally, a heterogeneous model collaborative optimization architecture driven by swarm intelligence (SSA / XGBoost+AHA / ELM) is designed, and the prediction error is compressed to the agronomic applicability standard (Mean absolute percentage error, MAPE < 9.5%), which establishes a technical case for hyperspectral agricultural monitoring that takes into account mechanism interpretability and landing feasibility. BRIEF DESCRIPTION OF DRAWINGS

[0035] Figure 1 The technical roadmap of the present application;

[0036] Figure 2 The sample plot design schematic of the present application;

[0037] Figure 3 The reflectivity curve diagram of the present application based on continuous wavelet transform processed wheat hyperspectral data;

[0038] Figure 4 The feature waveband position diagram of the present application based on continuous projection algorithm iteration;

[0039] Figure 5 The wheat leaf nitrogen content inversion result diagram based on different models of the present application. DETAILED DESCRIPTION

[0040] The present application will be described in detail below with reference to the accompanying drawings and embodiments.

[0041] A wheat nitrogen content detection method based on SG-CWT coupling SPA feature dynamic dimension reduction, the present embodiment is as follows:

[0042] The selected study area is located in the Lujia Smart Unmanned Farm in Suzhou City, Jiangsu Province (120.976625E, 32.386912N). The field experiment is a two-year consecutive experiment in 2024 and 2025. The experiment is set up with one wheat variety, Yangmai No.23, with a total of 100 plots. Five nitrogen fertilizer levels (N0, N1, N2, N3, N4) are set, which are 0, 100 kg / ha, 200 kg / ha, 300 kg / ha, and 400 kg / ha, respectively. Fertilization is carried out in three stages: basal fertilizer, jointing fertilizer, and booting fertilizer. Figure 2 As shown.

[0043] The hyperspectral data measurement in this embodiment was performed using a device manufactured by ASD Corporation, USA. A Hi-Res spectrometer (350-2500nm) was used, with sampling intervals of 1.3nm (350-1000nm range) and 2nm (1000-2500nm range). Spectra were measured in clear, windless, or low-wind conditions from 10:30 to 14:00 Beijing time. The spectrometer had a full field of view of 25°, with the probe positioned vertically downwards at a distance of 0.3m from the top of the plant canopy. Measurements were repeated 10 times within the field of view, and the average was taken as the reflectance spectrum at that point. Reference plate calibration was performed before and after each treatment (random locations within the plot were selected for each measurement). Spectral data were collected at four key growth stages of wheat: the greening stage, jointing stage, booting stage, and flowering stage.

[0044] When collecting hyperspectral data, a five-point sampling method was used to destructively sample the entire plot at each sampling point. After bringing the samples back to the laboratory, fresh leaves were cut and placed in an oven at 120℃ for 60 minutes to kill the green, and then dried at 65℃ to constant weight. The leaves were weighed and pulverized, and the nitrogen content (mg / g) of the powder was determined by the Kjeldahl method.

[0045] The acquired raw data was converted into reflectance data using ViewSpecPro software and exported. Because the hyperspectral data contained significant noise in the 350nm-2500nm range, the `savgol_filter` function in Python was used to smooth the raw canopy spectrum. Finally, continuous wavelet transform was used to decompose the wheat leaf canopy spectral data at different scales; the calculation formula is as follows:

[0046]

[0047] Where f(λ) is the spectral reflectance, λ is the number of spectral bands in the range of 350nm-2500nm, and ψ a,b Here, is the wavelet basis function, a is the scaling factor, b is the translation factor, and W is the wavelet coefficient. f(a, b) contain two-dimensional data, respectively, waveband and scale; generate behavior scale number, list as the matrix of waveband number; CWT transform is carried out on the wheat canopy spectrum in Python, and the decomposition scale is set to 10 scales; the Gaussian function derivative form gaus8 is selected as the wavelet base function, and finally the wavelet reflectivity data set after wavelet decomposition is obtained, which is used for subsequent analysis and modeling, as shown in Figure 3 .

[0048] The successive projection algorithm SPA (Successive Projections Algorithm, SPA) is a forward selection method commonly used for spectral variable selection or pure pixel extraction, and its iterative process is roughly represented as:

[0049]

[0050] wherein, represents the sub-matrix corresponding to the selected waveband, is the X j Residual on the orthogonal complement of the selected subspace. The wavelet reflectivity data set is screened by the successive projection algorithm SPA, and the maximum waveband number is set to 100, and the screening result is shown in Table 1:

[0051] Table 1: Screening result of the successive projection algorithm SPA

[0052]

[0053] After SPA feature screening, the variable data is significantly reduced, because the variables with zero variance, near zero variance and high autocorrelation are removed in the screening process, and the variables that have a significant impact on the nitrogen content of wheat leaves are retained.

[0054] The indicators used to test the model are the coefficient of determination (R 2 ), root mean square error (RMSE) and mean absolute percentage error (MAPE):

[0055]

[0056]

[0057] wherein, n is the number of sample set, is the average value of LNC, x i is the measured value of LNC, is the monitoring value of the model.

[0058] R 2The higher the value, the higher the fitting degree of the corresponding model. RMSE and MAPE are two evaluation indexes of regression model reflecting the accuracy of monitoring value. The smaller the value of RMSE and MAPE, the more accurate the monitoring effect of the model.

[0059] Figure 4 The RMSE under the continuous wavelet transform (Scale_64) changes with the number of wave bands. Unlike Scale_32, the RMSE of the test set generally shows a downward trend at this scale. The RMSE decreases rapidly in the interval of 0-25, and the decrease rate slows down significantly in the interval of 25-100, indicating that the risk of overfitting is weaker than Scale_32. The RMSE of the test set reaches the minimum (0.2048) at 97 wave bands, which is theoretically the optimal solution. However, the RMSE of the test set only increases to 0.2112 at 24 wave bands, sacrificing about 3% accuracy. The number of wave bands is reduced from 97 to 24, reducing about 77%.

[0060] Significant variables of wheat leaf nitrogen content were obtained through SPA feature screening as independent variables of the model input, and wheat leaf nitrogen content as the dependent variable. XGBoost regression and ELM regression models were established respectively to compare the differences between different algorithms to determine the best model. Meanwhile, SSA and AHA were used to optimize XGBoost regression and ELM regression models. The modeling results are shown in Figure 5 The performance of the wheat leaf nitrogen content prediction model based on XGBoost and ELM optimized by swarm intelligence algorithm (SSA / AHA) is significantly improved. SSA optimization makes the R 2 of XGBoost model increase by 25.4% to 0.79, RMSE decrease by 26.3% to 0.14mg / g, and MAPE decrease by 17.76% to 9.31%; AHA optimization makes the R2 of ELM model increase by 58.0% to 0.79, RMSE decrease by 41.7% to 0.14mg / g, and MAPE decrease by 36.61% to 9.54%. The research shows that intelligent optimization algorithm can effectively bridge the structural differences of different base models and realize the synchronous transition of prediction performance, providing a universal technical solution for crop nutrition diagnosis.

[0061] The above only describes the preferred embodiments of the present application and is not intended to limit the present application. For those skilled in the art, the present application can have various modifications and changes. Any modification, equivalent replacement, improvement, etc. made within the spirit and principles of the present application shall be included in the protection scope of the present application.

Claims

1. A wheat nitrogen content detection method based on SG-CWT coupled SPA feature dynamic dimension reduction, characterized by, The method comprises: constructing a dynamic feature purification mechanism, performing efficient feature compression and significant variable screening; introducing a dynamic modeling and robust optimization mechanism to enhance the adaptability to time series and variety differences; and providing a lightweight modeling framework to reduce model calculation overhead and running delay.

2. The method for detecting the nitrogen content of wheat based on the dynamic dimension reduction of the SG-CWT coupled SPA characteristic according to claim 1, characterized in that, The method specifically comprises the following steps: Step S1: Obtain hyperspectral data of wheat canopy leaves in the range of 350-2500 nm; Step S2: In the range of the spectrum collection point, collect wheat leaf samples according to the five-point sampling method, and after fixation and drying, measure the nitrogen content of the leaves as the true value label for model training; Step S3: The original hyperspectral data in step S1 is preprocessed to filter noise and improve the signal-to-noise ratio; Step S4: Select the Gaussian eight-order derivative wavelet basis function gaus8 to perform continuous wavelet transform decomposition on the preprocessed spectrum at the Scale_64 core scale to generate a wavelet reflectivity matrix and realize multi-scale feature mining; Step S5: Based on the successive projection algorithm SPA, the optimal waveband combination is screened with the constraint threshold of RMSE increase amplitude ≤5%, the original waveband number is compressed by more than 80%, the variance inflation factor is significantly reduced, and the multicollinearity problem between features is effectively alleviated; Step S6: Design a cross-growth period training set structure combining the sample time series characteristics, which covers representative samples from the green-up period to the flowering period; Step S7: The XGBoost model and the extreme learning machine model ELM are respectively established by taking the significant variables of the nitrogen content of the wheat leaves as the independent variables and the nitrogen content of the wheat as the dependent variable, and the differences between different models are compared; Step S8: The sparrow search algorithm SSA is used to optimize the XGBoost model hyperparameters, and the artificial bee colony algorithm AHA is used to optimize the extreme learning machine model ELM hyperparameters; Step S9: Through the feature compression + parameter optimization double mechanism, the number of final input variables is controlled within a certain number, so as to greatly reduce the model complexity; Step S10: The numerical value of the selected agricultural applicability standard MAPE is taken as the agricultural applicability threshold to establish a lightweight high-precision prediction model of the nitrogen content of the wheat leaves, so as to significantly improve the deployment convenience and field promotion value.

3. The method according to claim 2, wherein the method is characterized by, In step S4, the continuous wavelet transform decomposes the wheat leaf canopy spectrum data at different scales, and the calculation formula is as follows: where f(λ) is the spectral reflectance, λ is the spectral band number in the range of 350-2500 nm, ψ a,b is the wavelet basis function, a is the scale factor, b is the translation factor, and the wavelet coefficients W f (a, b) contains two-dimensional data, respectively, band and scale; generate behavior scale number, column as the band number matrix; CWT transform is carried out on the wheat canopy spectrum in Python, and the decomposition scale is set to 10 scales; the derivative form of the Gaussian function gaus8 is selected as the wavelet basis function, and finally the wavelet reflectance data set after wavelet decomposition is obtained, which is used for subsequent analysis and modeling.

4. The method for detecting the nitrogen content of wheat based on the dynamic dimension reduction of the SG-CWT coupled SPA characteristic according to claim 3, characterized in that, In step S5, the continuous projection algorithm SPA is used, and its iteration process is approximately represented as: wherein, denotes the sub-matrix corresponding to the selected band, is X j residual on the orthogonal complement of the selected subspace.

5. The method of claim 2, wherein the method is based on the SG-CWT coupled SPA feature dynamic dimension reduction for detecting the nitrogen content of wheat. In step S3, the fixation temperature is 120℃, the drying temperature is 65℃, and the Kjeldahl method is used to determine the nitrogen content of the leaves.

6. The method for detecting the nitrogen content of wheat based on the dynamic dimension reduction of the SG-CWT coupled SPA characteristic according to claim 2, characterized in that, In step S3, the Savitzky-Golay filter is used to suppress noise, and the window width is 11 and the polynomial order is 3.

7. The method of claim 2, wherein the method is based on the SG-CWT coupled SPA feature dynamic dimension reduction for detecting the nitrogen content of wheat. In step S10, the agricultural applicability threshold is that the agricultural applicability standard MAPE is less than 9.5%.

Citation Information

Patent Citations

  • Leaf nitrogen content high spectral evaluation method for continuous wavelet transformation analysis

    CN106323466A