Method for estimating flour protein and wet gluten content based on multi-source data

By combining multi-source data methods with ground-based hyperspectral imaging and RGB cameras, and utilizing CWT and machine learning algorithms, a predictive model for the protein and wet gluten content of wheat flour was constructed. This solved the problem of insufficient detection accuracy in existing technologies and achieved high-precision, low-cost detection results.

CN117741071BActive Publication Date: 2026-11-24HENAN AGRICULTURAL UNIVERSITY
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311740129.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-12-18
Publication Date
2026-11-24
Estimated Expiration
2043-12-18

AI Technical Summary

Technical Problem

Existing technologies lack accuracy in detecting protein and wet gluten content in wheat flour, and the models require regular updates and validation, making it difficult to achieve rapid and accurate detection.

Method used

Using a multi-source data approach, combining data collected by a ground-based hyperspectral imager and an RGB camera, and employing continuous wavelet transform (CWT) and machine learning algorithms, a predictive model for the protein and wet gluten content of wheat flour was constructed. Sensitive features were selected through feature selection methods, and multiple linear regression (MLR), partial least squares (PLS), and support vector machine (SVM) models were constructed.

Benefits of technology

This method improves the detection accuracy of protein and wet gluten content in wheat flour, enables multi-scale analysis and low-cost operation, simplifies the detection process, reduces feature redundancy, and enhances the stability and accuracy of the model.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117741071B_ABST
    Figure CN117741071B_ABST
Patent Text Reader

Abstract

This invention relates to the field of flour detection technology and discloses a method for estimating the protein and wet gluten content of flour based on multi-source data. This invention constructs predictive models for the protein and wet gluten content of different wheat varieties by setting up a research dataset, measuring quality indicators, acquiring hyperspectral and RGB data, preprocessing data, selecting features, and employing three machine learning methods (Multiple Linear Regression (MLR), Partial Least Squares (PLS), and Support Vector Machine (SVM)). This method, based on multi-source data and utilizing hyperspectral data acquisition, enhances the ability to identify and quantify sample components, providing multi-scale analysis of flour samples. The use of an RGB camera facilitates the capture of crop flour color, making the method simple to operate and cost-effective, thus possessing a competitive advantage and further improving the remote sensing accuracy of wheat flour protein and wet gluten content.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of flour testing technology, specifically to a method for estimating the protein and wet gluten content of flour based on multi-source data. Background Technology

[0002] Wheat is one of the world's three major staple grains, holding an important position in human diets and animal feed industries due to its rich nutritional value and stable yield. Wheat flour is widely used in the production of various foods, such as noodles, bread, and cakes. Carbohydrates, protein, dietary fiber, and trace elements are the core components of wheat, especially protein content, which not only affects the baking performance of wheat flour but is also a key factor determining wheat prices. Wet gluten content is also considered a key indicator of wheat quality. Changes in gluten protein during wheat storage directly impact the usable quality of wheat flour. Therefore, finding a rapid and accurate method for detecting wheat protein and wet gluten content is particularly urgent.

[0003] With the rapid development of computer science and sensor vision technology, the application of spectroscopic methods in indoor powder quality monitoring has brought significant advantages to the determination of protein content and wet gluten content. Compared with traditional chemical methods, spectroscopic technology is more environmentally friendly, reducing the use of chemical reagents and waste emissions. Traditional quality parameter estimation mainly relies on near-infrared (NIR) spectroscopy, a commonly used method for food and agricultural product analysis. NIR spectroscopy is non-destructive, allowing for continuous or multiple detections without damaging the sample. However, the accuracy of NIR spectroscopy is highly dependent on the quality of the calibration model, which requires regular updates and validation. Compared to NIR spectroscopy, hyperspectral technology provides continuous, wider-bandwidth spectral information, enhancing the identification and quantitative analysis capabilities of sample components. Hyperspectral data can be transformed in many ways, such as derivative transform, Fourier transform, and continuous wavelet transform. Among these, continuous wavelet transform (CWT), as a transformation feature of hyperspectral reflectance, can provide multi-scale analysis of powder samples and has high sensitivity for detecting different quality attributes such as texture and particle size distribution. CWT (Continuous Wound Tolerance) effectively handles non-stationary signals, making it particularly sensitive to anomalies or impurities in the flour. RGB cameras demonstrate unique advantages in monitoring crop quality. They conveniently capture the color of crop flour, crucial for assessing color uniformity and whether it has yellowed due to oxidation. Furthermore, their ease of operation and relatively low cost give them a competitive edge in real-time monitoring and rapid screening. Combined with appropriate image processing algorithms, RGB cameras can provide preliminary and intuitive information for flour quality assessment.

[0004] Machine learning, as an efficient computational method, can handle large amounts of heterogeneous data, such as spectral, image, and physicochemical information. The adaptability of machine learning algorithms allows them to continuously learn and improve models, making them sensitive to the spatial variability of crop quality parameters. When dealing with complex multi-source data, machine learning algorithms provide an efficient, accurate, and automated solution for estimating crop quality. However, a large number of input features can lead to collinearity and feature redundancy, hindering model construction. Feature selection methods for filtering spectral bands can effectively address feature redundancy. To further improve the remote sensing accuracy of wheat flour protein and wet gluten content, this study used an Aspheric Spectroradiometer (ASD) and an RGB camera to collect multi-source remote sensing data. Combined with Continuous Wavelet Transform (CWT), sensitive features were extracted using the Relative Function Estimation (RFE) algorithm. Furthermore, multiple linear regression (MLR), partial least squares (PLS), and support vector machine (SVM) were used to construct predictive models for wheat flour protein and wet gluten content. Summary of the Invention

[0005] (a) Technical problems to be solved

[0006] To address the shortcomings of existing technologies, this invention provides a method for estimating the protein and wet gluten content of flour based on multi-source data. This method enhances the ability to identify and quantify sample components, enables multi-scale analysis, and offers advantages such as simple operation and low cost, thus solving the problems mentioned in the background technology.

[0007] (II) Technical Solution

[0008] To achieve the objectives outlined in the background section, the present invention provides the following technical solution:

[0009] Another technical problem to be solved by this invention is to provide a method for estimating the protein and wet gluten content of flour based on multi-source data, comprising the following steps:

[0010] 1) Data sets were collected and quality indicators were determined. Wheat was harvested after maturity, threshed, hulled, and ground into flour. The quality indicators of the wheat flour were then determined. Protein content was determined using GB / T5511-2008 "Determination of Nitrogen Content and Calculation of Crude Protein Content in Cereals and Legumes - Kjeldahl Method". 0.2g of flour was weighed into a digestion tube using an electronic balance, followed by the addition of 2.0g of catalyst and 5mL of concentrated sulfuric acid. The mixture was digested at 420℃ for 1 hour in a digestion furnace. After cooling for 1 hour, the nitrogen content was determined using a fully automated Kjeldahl nitrogen analyzer.

[0011] Protein content of flour = Total nitrogen content of flour × 5.7

[0012] The wet gluten content was determined according to GB / T5506.2-2008 using a gluten analyzer. The formula for calculating the wet gluten content is as follows:

[0013] G wet =m1×10%

[0014] In the formula: m1 is the mass of wet gluten, in grams; G wet This refers to the wet gluten content;

[0015] 2) Darkroom spectral measurement of the collected flour: A FieldSpec4 portable ground object spectrometer was used to perform spectral measurements of the flour in a darkroom. During measurement, the sensor probe was vertically downward, the spectrometer's field of view was 25°, the vertical distance from the flour was approximately 30 cm, and the diameter of the field of view was 13.2 cm. Five spectra were used as one sampling spectrum, and two replicates were set up for each flour variety. The average value was used as the spectral reflectance value for that variety. Calibration was performed using a standard white board during the measurement process. The formula for the field of view is as follows:

[0016] GFOV = 2(h*TANθ / 2)

[0017] In the formula: GFOV is the field of view; h is the height; θ is the field of view angle of the spectrometer;

[0018] 3) RGB data acquisition: RGB data is acquired by shooting with a camera on a platform in a dark room at a fixed shooting height of 30cm. A zoom lens with optical image stabilization is used when acquiring images, and the images are recorded in true color JPEG format.

[0019] 4) Data Preprocessing: CWT is used to preprocess the spectral data. CWT uses the mother wavelet basis function to convert the original reflectance spectrum into a set of coefficients with different wavelengths and scales.

[0020]

[0021]

[0022] Where a is the scale factor, representing the width of the wavelet, b is the displacement factor, representing the position, l1 and l2 are the start and end band numbers of the input reflectance spectrum, respectively, ψ(λ) is the wave function, ψa,b(λ) is the mother wavelet function after translation and scaling, and WFa,b is the wavelet coefficient, which can be regarded as the similarity between the mother wavelet function and the reflectance when the scale is a and the translation factor is b, and can also be called wavelet features; the transformed wavelet features are denoted as WF.

[0023] This experiment utilizes the RGB color space, converting the colors in tiny rows and columns into numerical values ​​of the three primary colors (RGB) for memorization. The arrangement of colors into numerical data is called a pixel. The RGB values ​​of the true-color mask image are directly extracted using an RGB extraction algorithm. The captured image is opened using ENVI 5.3, and after reflectivity correction, a rectangular region of interest is identified and selected. The pixel spectrum of each region is then extracted and averaged. Finally, the normalized r, g, and b values ​​are calculated using the following formula:

[0024] r = R / (R + G + B)

[0025] g = G / (R + G + B)

[0026] b = B / (R + G + B)

[0027] Based on literature retrieval, a total of 8 visible light color indices were selected as color feature values ​​for estimating protein content and wet gluten content in this experiment.

[0028] Table 1 Color Index (CI)

[0029]

[0030]

[0031] 5) Feature selection: First, for spectral reflectance, only the most sensitive features with the top 5% of the coefficient of determination are retained as the initial spectral feature set; for wavelet features, a visual scale map is generated to visualize the distribution of extracted spectral features, and only the most sensitive features with the top 5% of the maximum coefficient of determination are retained as the initial wavelet feature set; correlation analysis is performed on color index with measured protein content and wet gluten content respectively to select color features, and the original reflectance and wavelet features are selected again using the Feature Elimination Algorithm (RFE), and 5x cross-validation is used. The optimal variable subset is determined by the highest cross-validation accuracy.

[0032] Feature selection includes color feature selection, hyperspectral initial feature selection, and sensitive feature selection based on the RFE algorithm.

[0033] Color feature selection: Correlation analysis was performed on the eight color indices with the measured protein content and wet gluten content. The color indices EXG and EXGR were significantly correlated with protein content, with correlation coefficients of -0.547 and -0.603, respectively; EXG and RGBVI were significantly correlated with wet gluten content, with correlation coefficients of -0.504 and -0.582, respectively. The significantly correlated color indices were recorded as color features (CI) and used as input variables for RGB.

[0034] Initial screening of the hyperspectral feature set, including preliminary screening of raw reflectance features: Pearson correlation analysis was performed on the raw reflectance of the protein content and wet gluten content datasets, retaining only the most sensitive features with the top 5% coefficients of determination as the initial spectral feature set; the sensitive regions of the raw reflectance of the protein content dataset are mainly concentrated in the visible light region (380–700 nm) and the short-wave infrared region (1300–2500 nm), with significantly higher correlation coefficients (R0.05) in the three intervals of 392–422 nm, 1970–001 nm, and 2178–2222 nm. 2 =0.664~0.701), with the highest correlation coefficient (R) at 407nm. 2 =0.701), the raw reflectance sensitive region of the wet gluten content dataset is mainly concentrated in the short-wave infrared region (1300-2500 nm), and the correlation coefficient is significantly improved in the two intervals of 1913-2012 nm and 2494-2500 nm (R = 0.701). 2 =0.471~0.516), with the highest correlation coefficient (R) at 1979nm. 2 =0.516); Initial screening of wavelet features: Only the most sensitive features with the highest coefficient of determination in the top 5% are retained as the initial wavelet feature set; The wavelet sensitive features of the protein content and wet gluten content datasets are generally scattered, mainly distributed in the visible light region (380-700nm) and the short-wave infrared region (1300-2500nm). The most sensitive wavelet feature of the wet gluten content dataset appears in the 2083 band at the 8th scale.

[0035] Sensitive feature selection based on the RFE algorithm includes the following steps: Sensitive feature selection based on original reflectance: RFE is used to select variables for different input features. For the initial spectral feature set, protein content and wet gluten content are selected. The protein content dataset yields 5 sensitive bands: 408nm, 410nm, 411nm, 1981nm, and 2192nm. The wet gluten content dataset yields 3 sensitive features: 1981nm, 1989nm, and 2012nm. Wavelet sensitive feature selection: Sensitive feature selection is performed again based on the RFE algorithm. The protein content dataset yields 114 wavelet sensitive features, accounting for 0.9% of the initial wavelet feature set; the wet gluten content dataset yields 98 wavelet sensitive features, accounting for 0.7% of the initial wavelet feature set.

[0036] 6) Modeling and Validation: Three machine learning methods—multiple linear regression (MLR), partial least squares regression (PLSR), and support vector machine (SVM)—were used to construct predictive models for the protein and wet gluten content of different wheat varieties. Then, a 5-fold cross-validation method was used to perform 100 iterations of model validation to evaluate the stability and accuracy of all models in estimating protein and wet gluten content. Finally, the coefficient of determination (R²) was used to... 2 The goodness of fit between predicted and measured values ​​is evaluated using two metrics: root mean square error (RMSE). The calculation formula is as follows:

[0037]

[0038]

[0039] Where, x i Represents the measured value, y i Indicates the predicted value. For x i The average value, For y i The average value, where n represents the number of samples.

[0040] Model construction based on single-modal data combined with feature selection: In order to evaluate the estimation ability of single-modal data, models were established based on spectral sensitive bands, wavelet sensitive features and color features, and protein content and wet gluten content, respectively. Three machine learning methods, MLR, PLS and SVM, were selected for modeling.

[0041] Model construction based on multimodal data and feature selection: The spectral sensitive band (OR), wavelet sensitive feature (WF) and color feature (CI) are fused, and multimodal data modeling is performed using three machine learning methods to estimate the protein and wet gluten content respectively.

[0042] Preferably, in step 2, the flour spectrum measurement is preheated for 15 minutes before testing, and the spectrometer has a spectral range of 350–2500 nm, wherein the sampling interval for the 350–1000 nm spectrum is 1.4 nm and the spectral resolution is 3.0 nm; the sampling interval for the 1000–2500 nm spectrum is 1.1 nm and the spectral resolution is 6.0 nm.

[0043] Preferably, in step 3, the zoom lens has a focal length range of 18-135mm, a filter size of 67mm, a lens structure of 16 elements in 12 groups, a maximum aperture of F3.5-F5.6, a minimum aperture of F22-F36, and 6 aperture blades. The resolution of the flour image acquired by the camera is 5184×3456 pixels.

[0044] Preferably, in step 4, the color feature processing uses the RGB color space. This involves converting the colors in tiny rows and columns into numerical values ​​of the three primary colors (RGB) for memorization. The way colors are arranged as numerical data is called a pixel. The RGB values ​​of the true-color mask image are directly extracted using an RGB extraction algorithm. The captured image is opened using ENVI 5.3, and after reflectivity correction, a rectangular region of interest is identified and selected in the image. Then, the pixel spectrum of each region is extracted and its average value is taken. Finally, the normalized r, g, and b values ​​are calculated according to the following formula:

[0045] r = R / (R + G + B)

[0046] g = G / (R + G + B)

[0047] b = B / (R + G + B)

[0048] Based on literature retrieval, a total of 8 visible light color indices were selected as color feature values ​​for estimating protein content and wet gluten content in this experiment.

[0049] Table 1 Color Index (CI)

[0050]

[0051]

[0052] Preferably, in step 5, the Feature Elimination Algorithm (RFE) searches for a subset of features from all features in the training dataset and successfully removes features until the required number is retained. This is achieved by fitting a given algorithm model, sorting the features by importance, discarding the least important features, and refitting the model. This process is repeated until a specific number of features are retained to eliminate less important variables.

[0053] Preferably, the feature selection in step 5 includes: color feature selection, initial feature set selection of hyperspectral and wavelet features, and sensitive feature selection based on the RFE algorithm.

[0054] Preferably, in step 6, 70% of the dataset is subjected to 5-fold cross-validation. Each time, one part (S1-S5) is selected to test the model, the remaining four parts are used to train the model, and the remaining 30% of independent data is used for validation. This process is repeated 500 times. Then, the results of the five iterations (A1-A5, B1-B5) are averaged to calculate the average accuracy (Ai, Bi) of the training and validation results.

[0055] Preferably, the modeling in step 6 includes model building based on single-modal data combined with feature selection and model building based on multi-modal data combined with feature selection.

[0056] Preferably, the model construction based on single-modal data combined with feature screening is as follows: In order to evaluate the estimation ability of single-modal data, models are established based on spectral sensitive bands, wavelet sensitive features and color features, respectively, along with protein content and wet gluten content. Three machine learning methods, MLR, PLS and SVM, are selected for modeling.

[0057] Preferably, the model construction based on multimodal data combined with feature screening involves fusing spectral sensitive bands (OR), wavelet sensitive features (WF), and color features (CI) to perform multimodal data modeling using three machine learning methods, thereby estimating the protein and wet gluten content respectively.

[0058] (III) Beneficial Effects

[0059] Compared with existing technologies, this invention provides a method for estimating the protein and wet gluten content of flour based on multi-source data, which has the following beneficial effects:

[0060] 1. This method for estimating the protein and wet gluten content of flour based on multi-source data utilizes hyperspectral data acquisition. Hyperspectral technology provides continuous and wider-range spectral information, enhancing the ability to identify and quantify sample components. Furthermore, continuous wavelet transform (CWT), as a transformation feature of hyperspectral reflectance, can provide multi-scale analysis of powder samples and has high sensitivity for detecting different quality attributes such as texture and particle size distribution.

[0061] 2. This method for estimating the protein and wet gluten content of wheat flour based on multi-source data, by using an RGB camera, can easily capture the color of crop flour, making it simple to operate and inexpensive, giving it a good competitive advantage. Furthermore, by using a feature selection method to screen spectral bands, it can effectively solve the problem of feature redundancy, and further improve the remote sensing monitoring accuracy of wheat flour protein and wet gluten content. Attached Figure Description

[0062] Figure 1 The R value estimated by this invention for protein (a) and wet gluten content (b) derived from the original reflectance. 2 Scale diagram;

[0063] Figure 2 Ra is used to estimate the protein content (a) and wet gluten content (b) of the wavelet coefficients in this invention. 2 Scale diagram;

[0064] Figure 3 This invention selects the original reflectance feature variable map based on the RFE algorithm;

[0065] Figure 4 This invention selects wavelet feature variables based on the RFE algorithm.

[0066] Figure 5 This invention evaluates the estimation of protein content using different machine learning models for single-modality data.

[0067] Figure 6 This invention evaluates the estimation of wet gluten content using different machine learning models for single-modal data.

[0068] Figure 7 This is an evaluation graph showing the estimation of protein content (a) and wet gluten content (b) from multimodal data using different machine learning models in this invention. Detailed Implementation

[0069] The technical solutions of the present invention will be clearly and completely described below with reference to the embodiments of the present invention. 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.

[0070] Example: The wheat varieties selected for the experiment were obtained in 2022 from Xuchang City, Henan Province (113°48′E 340°00′N) and Harbin City, Heilongjiang Province (125°42′E, 44°04′N). Xuchang City has a temperate monsoon climate with an average temperature of 9–20°C and an annual precipitation of approximately 700 mm; the soil type is alluvial soil. Harbin City has a mid-temperate continental monsoon climate with an average temperature of 3.5°C and an average annual precipitation of 569.1 mm; the soil type is black soil. A total of 238 samples were collected from the two regions, constituting the dataset for this study.

[0071] A method for estimating the protein and wet gluten content of flour based on multi-source data includes the following steps:

[0072] Step 1: Collect research data: Harvest wheat after it matures, thresh the wheat ears, remove the husks, and grind them into flour to determine the quality indicators of the wheat flour.

[0073] Step 2: Determination of Quality Indicators: Protein Content Determination: Using GB / T5511-2008 "Determination of Nitrogen Content and Calculation of Crude Protein Content in Cereals and Legumes - Kjeldahl Method", 0.2g of flour was weighed into a digestion tube using an electronic balance, followed by the addition of 2.0g of catalyst and 5mL of concentrated sulfuric acid. The mixture was digested in a digestion furnace at 420℃ for 1 hour. After cooling for 1 hour, the nitrogen content was determined using a fully automated Kjeldahl nitrogen analyzer.

[0074] Protein content of flour = Total nitrogen content of flour × 5.7

[0075] The wet gluten content was determined according to GB / T5506.2-2008 using a gluten analyzer. 10g of the sample was weighed, accurate to 0.01g. Before the experiment, the washing chamber containing an 88μm polyester sieve was moistened. The weighed sample was placed inside, and 5mL of 20g / L sodium chloride solution was added. The washing chamber was then placed on the gluten washing apparatus and stirred for 25s. After washing for 2 minutes, the process was stopped. The washing chamber was removed, and the partially washed gluten containing bran was transferred to another washing chamber with an 800μm metal sieve under running cold water. Washing continued until the washing process was complete. The washing was considered complete when the effluent became clear and potassium iodide solution did not turn blue upon addition, indicating the absence of starch. The washed wet gluten was removed, divided into approximately two equal portions, and centrifuged in a gluten index analyzer for 60s. The portions were then removed with tweezers and weighed immediately, accurate to 0.01g. Since the gluten analyzer has two ends, it can produce two parallel samples simultaneously. The formula for calculating the wet gluten content is:

[0076] G wet =m1×10%

[0077] In the formula: m1 is the mass of wet gluten, in grams; G wet This refers to the wet gluten content.

[0078] Step 3: Hyperspectral Data Acquisition: Flour spectra were measured in a darkroom using a FieldSpec4 portable ground object spectrometer. The spectrometer was preheated for 15 minutes before testing. The spectrometer's spectral range was 350–2500 nm, with a sampling interval of 1.4 nm and a spectral resolution of 3.0 nm for the 350–1000 nm range; and a sampling interval of 1.1 nm and a spectral resolution of 6.0 nm for the 1000–2500 nm range. During measurement, the sensor probe was vertically downward, the spectrometer's field of view was 25°, and the distance from the flour sample to the vertical height was approximately 30 cm, resulting in a field of view diameter of 13.2 cm. Two replicates were set up for each flour variety, and the average value was used as the spectral reflectance value for that variety. Calibration was performed using a standard white board during the measurement process. The formula for the field of view is as follows:

[0079] GFOV = 2(h*TANθ / 2)

[0080] In the formula: GFOV is the field of view; h is the height; θ is the field of view angle of the spectrometer.

[0081] Step 4: RGB Data Acquisition: RGB data was acquired by shooting images on a platform in a darkroom using a camera. The shooting height was fixed at 30cm. When acquiring images, a zoom lens with optical image stabilization was used. The zoom lens had a focal length range of 18-135mm, a filter size of 67mm, a lens structure of 16 elements in 12 groups, a maximum aperture of F3.5-F5.6, a minimum aperture of F22-F36, and 6 aperture blades. The resolution of the flour image acquired using this camera was 5184×3456 pixels, and the image was recorded in true-color JPEG format.

[0082] Step 5: Data Preprocessing: CWT is used to preprocess the spectral data. CWT uses the mother wavelet basis function to convert the original reflectance spectrum into a set of coefficients with different wavelengths and scales.

[0083]

[0084]

[0085] Where a is the scale factor, representing the width of the wavelet, b is the displacement factor, representing the position, l1 and l2 are the start and end band numbers of the input reflectance spectrum, respectively, ψ(λ) is the wave function, ψa,b(λ) is the mother wavelet function after translation and scaling, and WFa,b is the wavelet coefficient, which can be regarded as the similarity between the mother wavelet function and the reflectance when the scale is a and the translation factor is b, and can also be called the wavelet feature; the transformed wavelet feature is denoted as WF;

[0086] This experiment utilizes the RGB color space, converting the colors in tiny rows and columns into numerical values ​​of the three primary colors (RGB) for memorization. The arrangement of colors into numerical data is called a pixel. The RGB values ​​of the true-color mask image are directly extracted using an RGB extraction algorithm. The captured image is opened using ENVI 5.3, and after reflectivity correction, a rectangular region of interest is identified and selected. The pixel spectrum of each region is then extracted and averaged. Finally, the normalized r, g, and b values ​​are calculated using the following formula:

[0087] r = R / (R + G + B)

[0088] g = G / (R + G + B)

[0089] b = B / (R + G + B)

[0090] Based on literature retrieval, eight visible light color indices were selected as color feature values ​​for estimating protein content and wet gluten content in this experiment. Details are shown in the table below.

[0091]

[0092]

[0093] Step 6: Color Feature Selection: Correlation analysis was performed on the eight color indices and the measured protein content and wet gluten content, as shown in the table below. The color indices EXG and EXGR were significantly correlated with protein content, with correlation coefficients of -0.547 and -0.603, respectively; EXG and RGBVI were significantly correlated with wet gluten content, with correlation coefficients of -0.504 and -0.582, respectively. The significantly correlated color indices were recorded as color features (CI) and used as input variables for RGB.

[0094]

[0095] Step 7: Initial Hyperspectral Feature Set Screening: Preliminary Screening of Raw Reflectance Features: Pearson correlation analysis was performed on the raw reflectance of the protein content and wet gluten content datasets. Only the most sensitive features with the top 5% coefficients of determination were retained as the initial spectral feature set. The top 5% of the most sensitive wavelengths were selected as the initial features of the raw reflectance, such as... Figure 1 As shown, there are 107 bands in total. The raw reflectance sensitive regions of the protein content dataset are mainly concentrated in the visible light region (380–700 nm) and the short-wave infrared region (1300–2500 nm). The correlation coefficients are significantly higher in the three intervals of 392–422 nm, 1970–2001 nm, and 2178–2222 nm (R0). 2 =0.664~0.701), with the highest correlation coefficient (R) at 407nm. 2 =0.701), the raw reflectance sensitive region of the wet gluten content dataset is mainly concentrated in the short-wave infrared region (1300-2500 nm), and the correlation coefficient is significantly improved in the two intervals of 1913-2012 nm and 2494-2500 nm (R = 0.701). 2 =0.471~0.516), with the highest correlation coefficient (R) at 1979nm. 2 =0.516); Initial wavelet feature selection: Only the most sensitive features with the highest coefficient of determination in the top 5% are retained as the initial wavelet feature set, such as... Figure 2 As shown, the wavelet-sensitive features of the protein content and wet gluten content datasets are generally dispersed, mainly distributed in the visible light region (380–700 nm) and the short-wave infrared region (1300–2500 nm). Among them, the most sensitive wavelet feature of the protein content dataset appears in the 2107 band at scale 8, R. 2 The value is 0.505; the most sensitive wavelet feature in the wet gluten content dataset appears in band 2083 at scale 8, R. 2 The value is 0.593; this study will Figure 2The 752 wavelet-sensitive features of the light-colored marked region in -a are used as the initial wavelet feature set of the protein content dataset. Figure 2 The 675 wavelet-sensitive features of the light-colored marked region in -b are used as the initial wavelet feature set for the wet gluten content dataset;

[0096] Step 8: Sensitive Feature Selection Based on RFE Algorithm: Sensitive Feature Selection of Raw Reflectance: RFE is needed to select variables with different input features, such as... Figure 3 As shown, the initial spectral feature set was filtered for protein content and wet gluten content. The protein content dataset identified five sensitive bands: 408nm, 410nm, 411nm, 1981nm, and 2192nm. The wet gluten content dataset identified three sensitive features: 1981nm, 1989nm, and 2012nm. Wavelet sensitive feature filtering: Sensitive features were further filtered based on the RFE algorithm, as shown... Figure 4 As shown, 114 wavelet-sensitive features were extracted from the protein content dataset, accounting for 0.9% of the initial wavelet feature set; 98 wavelet-sensitive features were extracted from the wet gluten content dataset, accounting for 0.7% of the initial wavelet feature set.

[0097] Step 9: Modeling and Validation: Predictive models for protein and wet gluten content in different wheat varieties were constructed using three machine learning methods: Multiple Linear Regression (MLR), Partial Least Squares Regression (PLSR), and Support Vector Machine (SVM). The models were then validated 100 times using a 5-fold cross-validation method to assess their stability and accuracy in estimating protein and wet gluten content. Finally, the coefficient of determination (R²) was used to determine the model's performance. 2 The goodness of fit between predicted and measured values ​​is evaluated using two metrics: root mean square error (RMSE). The calculation formula is as follows:

[0098]

[0099]

[0100] Where, x i Represents the measured value, y i Indicates the predicted value. For x i The average value, For y i The average value, where n represents the number of samples;

[0101] MLR is widely used in remote sensing monitoring due to its simplicity, but it relies on the linear relationship between sample data and variables. It is a method to establish a quantitative relationship between two or more explanatory independent variables and dependent variables by fitting linear equations to observed data. PLSR is a novel multivariate statistical data analysis method that can simultaneously perform multivariate linear regression analysis, principal component analysis, and canonical correlation analysis. This method can extract components from both independent and dependent variables for modeling and is not affected by the presence of multiple correlations among independent variables, thus overcoming the shortcomings of ordinary least squares. The SVM algorithm, first proposed by Cortes and Vapnik in 1995, is based on statistical learning theory. Based on dimensionality theory and the principle of structural risk minimization, it seeks the optimal trade-off between model complexity (the specific learning accuracy of training samples) and model learning ability (the ability to identify unbiased random samples) to achieve the best generalization ability. In the 5-fold cross-validation method, 70% of the dataset undergoes 5-fold cross-validation, with one copy (S1-S5) selected for testing each time, and the remaining four copies used to train the model. The remaining 30% of independent data is used for validation. This process is iterated 500 times, and then the results of five iterations (A1-A5, B1-B5) are averaged to calculate the average precision (Ai, Bi) of the training and validation results.

[0102] Step 10: Model Construction Based on Single-Modal Data and Feature Selection: To evaluate the estimation capability of single-modal data, models were built based on spectral sensitive bands, wavelet sensitive features, and color features, along with protein content and wet gluten content. Three machine learning methods—MLR, PLS, and SVM—were used for modeling. Figure 5 As shown, for the protein content dataset, the evaluation accuracy produced by inputting the selected features into different machine learning models is illustrated. The validation accuracy of the machine learning models varies depending on the input features; for example... Figure 6 As shown, for the wet gluten content dataset, the evaluation accuracy produced by inputting the selected features into different machine learning models is presented.

[0103] Step 11; Model construction based on multimodal data and feature selection: Spectral sensitive bands (OR), wavelet sensitive features (WF), and color features (CI) are fused together. Multimodal data modeling is performed using three machine learning methods to estimate protein and wet gluten content, such as... Figure 7 As shown.

[0104] Judgment criteria: Model construction based on single-modal data combined with feature selection, such as... Figure 6 As shown: The estimation accuracy for different input data is WF(R) 2 =0.916~0.769)>OR(R 2=0.659~0.539)>CI(R 2 =0.353~0.248); Comparing the three machine learning methods, the MLR model performs better for OR (R2=0.598~0.659, RMSE=1.508~1.901), while the SVM model performs better for WF and CI (WF: R2=0.884~0.916, RMSE=0.676~0.852; CI: R2=0.353~0.248). 2 =0.252~0.352, RMSE=1.621~2.086); the three machine learning methods based on color features performed relatively poorly in estimation (R 2 =0.078~0.226, RMSE=4.868~6.823), WF is the optimal input feature (R 2 =0.743~0.872, RMSE=2.130~3.730), the estimation performance of different machine learning methods with WF as the input variable is SVM>PLS>MLR, and the WF-SVM model has greater potential in predicting wet gluten content (R = 0.743~0.872, RMSE = 2.130~3.730). 2 =0.861, RMSE=2.349); This shows that when estimating protein and wet gluten content using single-modal data, the estimation effect based on wavelet-sensitive features is better than that based on spectral-sensitive bands, while the estimation effect based on color features is the worst; Model construction based on multimodal data combined with feature selection, such as Figure 7 As shown, overall, the estimation results from different modeling methods show a consistent trend, with model accuracy ranking as SVM > MLR > PLS. The SVM model result for estimating protein content using multimodal data OR+WF+CI is R. 2 =0.898, RMSE=0.761, compared to the single-data-source combined WF-SVM model R 2 The RSI increased by 0.4%, and the RMSE decreased by 1.9%. The SVM model results for estimating wet gluten content using multimodal data (OR+WF+CI) were R... 2 =0.865, RMSE=2.297, compared to the single-data-source combined WF-SVM model R 2 The accuracy was improved by 0.5% and the RMSE decreased by 2.2%. The results show that by combining wavelet features with spectral sensitive bands and color features, the model accuracy was greatly improved. Therefore, these three data sources can be fused as independent variables to predict wheat protein and wet gluten content.

[0105] Although embodiments of the invention have been shown and described, it will be understood by those skilled in the art that various changes, modifications, substitutions and alterations can be made to these embodiments without departing from the principles and spirit of the invention, the scope of which is defined by the appended claims and their equivalents.

Claims

1. A method for estimating the protein and wet gluten content of flour based on multi-source data, characterized in that: Includes the following steps: 1) Data collection and quality index determination: Wheat was harvested after maturity, the ears were threshed, the husks removed, and the wheat was ground into flour. The quality indexes of the wheat flour were then determined. For protein content determination, 0.2g of flour was weighed into a digestion tube using an electronic balance, followed by the addition of 2.0g of catalyst and 5mL of concentrated sulfuric acid. The mixture was digested at 420℃ for 1 hour, and after cooling for 1 hour, the nitrogen content was determined using an automated Kjeldahl nitrogen analyzer. Protein content of flour = Total nitrogen content of flour × 5.7 The wet gluten content was determined according to GB / T5506.2-2008 using a gluten analyzer. The formula for calculating the wet gluten content is as follows: G wet =m1×10% Where: m1 is the mass of wet gluten, in grams; G wet This refers to the wet gluten content; 2) Darkroom spectral measurement of the collected flour: The FieldSpec4 portable ground object spectrometer was used to perform spectral measurements of the flour in a darkroom. During the measurement, the sensor probe was vertically downward, the spectrometer's field of view was 25°, the vertical distance from the flour was approximately 30 cm, and the diameter of the field of view was 13.2 cm. Five spectra were used as one sampling spectrum, and two replicates were set up for each variety of flour sample. The average value was used as the spectral reflectance value of that variety. During the measurement, the standard white board was used for calibration. The formula for the field of view is as follows: GFOV=2(h*TANθ / 2) In the formula: GFOV is the field of view; h is the height; θ is the field of view angle of the spectrometer; 3) RGB data acquisition: RGB data is acquired by shooting the camera on a platform in a dark room at a fixed height of 30cm. When acquiring images, an 18-135 zoom lens with optical image stabilization is used, and the images are recorded in true color JPEG format. 4) Data Preprocessing: Continuous Wavelet Transform (CWT) is used to preprocess the spectral data. CWT uses the mother wavelet basis function to convert the original reflectance spectrum into a set of coefficients with different wavelengths and scales. ; ; Where a is the scale factor, representing the width of the wavelet, b is the displacement factor, representing the position, l1 and l2 are the start and end band numbers of the input reflectance spectrum, respectively, ψ(λ) is the wave function, ψa,b(λ) is the mother wavelet function after translation and scaling, and WFa,b is the wavelet coefficient, which can be regarded as the similarity between the mother wavelet function and the reflectance when the scale is a and the translation factor is b, and can also be called the wavelet feature; the transformed wavelet feature is denoted as WF; Color feature processing utilizes the RGB color space, converting the colors in tiny rows and columns into numerical values ​​of the three primary colors (RGB) for memorization. The arrangement of colors into numerical data is called a pixel. The RGB values ​​of the true-color mask image are directly extracted using an RGB extraction algorithm. The captured image is opened using ENVI 5.3, and after reflectivity correction, a rectangular region of interest is identified and selected. The pixel spectrum of each region is then extracted and averaged. Finally, the normalized r, g, and b values ​​are calculated using the following formula. Based on literature retrieval, a total of 8 visible light color indices were selected as color feature values ​​for estimating protein content and wet gluten content in this experiment. 5) Feature selection: First, for spectral reflectance, only the most sensitive features with the top 5% of the coefficient of determination are retained as the initial spectral feature set; for wavelet features, a visual scale map is generated to visualize the distribution of extracted spectral features, and only the most sensitive features with the top 5% of the maximum coefficient of determination are retained as the initial wavelet feature set; correlation analysis is performed on color index with measured protein content and wet gluten content to select color features, and the feature elimination algorithm RFE is used to further select the original reflectance and wavelet features, and 5x cross-validation is used, with the optimal variable subset determined by the highest cross-validation precision; 6) Modeling and Validation: Three machine learning methods—Multiple Linear Regression (MLR), Partial Least Squares Regression (PLSR), and Support Vector Machine (SVM)—were used to construct predictive models for protein and wet gluten content in different wheat varieties. Then, a 5-fold cross-validation method was used to perform 100 iterations of model validation to evaluate the stability and accuracy of all models in estimating protein and wet gluten content. Finally, the coefficient of determination R-squared was used... 2 The root mean square error (RMSE) and two other metrics are used to evaluate the goodness of fit between predicted and measured values. The calculation formula is as follows: ; This represents the measured value. Indicates the predicted value. for The average value, for The average value, where n represents the number of samples.

2. The method for estimating the protein and wet gluten content of flour based on multi-source data according to claim 1, characterized in that: In step 2, the flour spectrum measurement is performed by preheating for 15 minutes before testing. The spectrometer has a spectral range of 350~2500nm, with a sampling interval of 1.4nm for the 350~1000nm spectrum and a spectral resolution of 3.0nm; and a sampling interval of 1.1nm for the 1000~2500nm spectrum and a spectral resolution of 6.0nm.

3. The method for estimating the protein and wet gluten content of flour based on multi-source data according to claim 1, characterized in that: In step 3, the zoom lens has a focal length range of 18-135mm, a filter size of 67mm, a lens structure of 16 elements in 12 groups, a maximum aperture of F3.5-F5.6, a minimum aperture of F22-F36, and 6 aperture blades. The resolution of the flour image acquired using this camera is 5184×3456 pixels.

4. The method for estimating the protein and wet gluten content of flour based on multi-source data according to claim 1, characterized in that: In step 5, the Feature Elimination (RFE) algorithm starts by searching for a subset of features from all features in the training dataset and successfully removes features until the required number is retained. This is achieved by fitting a given algorithm model, sorting features by importance, discarding the least important features, and refitting the model. This process is repeated until a specific number of features are retained to eliminate less important variables.

5. The method for estimating the protein and wet gluten content of flour based on multi-source data according to claim 1, characterized in that, The feature selection in step 5 includes: color feature selection, initial feature set selection of hyperspectral and wavelet features, and sensitive feature selection based on the RFE algorithm.

6. The method for estimating the protein and wet gluten content of flour based on multi-source data according to claim 1, characterized in that: In step 6, the 5-fold cross-validation method involves performing 5-fold cross-validation on 70% of the dataset. Each time, one test model is selected, and the remaining four training models are used. The remaining 30% of the independent data is used for validation. This process is iterated 500 times, and then the results of the five iterations are averaged to calculate the average accuracy of the training and validation results.

7. The method for estimating the protein and wet gluten content of flour based on multi-source data according to claim 1, characterized in that, The modeling in step 6 includes model building based on single-modal data combined with feature selection and model building based on multimodal data combined with feature selection.

8. The method for estimating the protein and wet gluten content of flour based on multi-source data according to claim 7, characterized in that, The model construction based on single-modal data combined with feature selection: In order to evaluate the estimation ability of single-modal data, models were established based on spectral sensitive bands, wavelet sensitive features and color features, and protein content and wet gluten content, respectively. Three machine learning methods, MLR, PLSR and SVM, were selected for modeling.

9. The method for estimating the protein and wet gluten content of flour based on multi-source data according to claim 7, characterized in that, The model construction based on multimodal data combined with feature screening involves fusing spectral sensitive band OR, wavelet sensitive feature WF, and color feature CI, and using three machine learning methods to model multimodal data to estimate the protein and wet gluten content, respectively.