Fig maturity evaluation method based on spectral data and mathematical model
Through spectral data and mathematical model combined with CARS and PLSR algorithms, the objectivity and standardization problems of fig maturity discrimination evaluation are solved, and the rapid lossless discrimination of fig maturity is achieved, and the fruit harvesting efficiency and economic value are improved.
Patent Information
- Application Number
- CN202411165280.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-23
- Publication Date
- 2024-11-29
AI Technical Summary
In the prior art, the evaluation of fig maturity discrimination lacks objectivity and standardization, resulting in a decrease in the value of the fruit during transportation, storage and processing, making it difficult to achieve rapid and lossless maturity discrimination.
Using a method based on spectral data and mathematical model, by measuring the color index, soluble solids and hardness of figs, combined with CARS and PLSR algorithms, a linear regression model is constructed, and feature wavelength extraction is optimized to achieve rapid lossless discrimination of fig maturity.
It improves the field fruit harvesting efficiency, improves the economic value of figs, promotes the healthy development of the industrial chain, and provides an objective and standardized maturity assessment method.
Smart Images

Figure CN119044077A_ABST
Abstract
Description
Technical field:
[0001] The invention relates to a fig maturity evaluation method based on spectral data and mathematical models. Background technology:
[0002] Figs are widely grown around the world. Their fruits are rich in nutrients and have antioxidant, antibacterial and anti-cancer effects. They are an important economic forest crop. Ripe figs are sweet, have soft skin, and are not easy to transport and store. Since the maturity of the fruit determines its nutrient content, appearance and shelf life, the evaluation and prediction of the maturity of the fruit is very important.
[0003] Generally speaking, the maturity of figs is mainly assessed through subjective judgment by fruit farmers, who sometimes need to pinch the fruit by hand to feel its hardness. This method lacks objectivity and is difficult to standardize. It also causes certain damage to the fruit, which is not conducive to the later transportation, sale, storage and deep processing of the fruit, greatly reducing the economic value of the figs. Summary of the invention:
[0004] The embodiment of the present invention provides a fig maturity assessment method based on spectral data and a mathematical model. The method is reasonably designed. The fig maturity assessment method based on spectral data and a mathematical model adopts a plurality of different preprocessing algorithms to preprocess the spectral data of fresh figs and extract characteristic wavelength variables, constructs an optimal preprocessing model of color index, SSC and hardness, performs partial least squares regression modeling through color index data and spectral data, formulates standardized assessment indicators, adopts a nonlinear algorithm PLSR and a variable screening algorithm CARS to construct and optimize the model, replaces the existing SSC index and hardness index with the color index to achieve rapid and non-destructive discrimination of mature figs, can effectively improve the efficiency of field fruit harvesting, greatly improve the economic value of fresh figs, promote the healthy development of the fig industry chain, and solve the problems existing in the prior art.
[0005] The technical solution adopted by the present invention to solve the above technical problems is:
[0006] A fig maturity assessment method based on spectral data and mathematical models, the assessment method comprising the following steps:
[0007] S1, measuring the color index, soluble solids and firmness of figs;
[0008] S2, spectra were collected at three randomly selected positions along the equator of the fig, and the average value was used as the original spectrum of the fig sample;
[0009] S3, uses the CARS algorithm to extract characteristic wavelengths to remove a large amount of redundant data and reduce the model calculation cost;
[0010] S4, constructing a linear regression model of multiple independent variables using partial least squares through spectral data and color index data;
[0011] S5, CARS algorithm and PLSR algorithm were used to optimize the linear regression model, and the color index was used to achieve rapid and non-destructive discrimination of ripe figs.
[0012] Measuring the color index, soluble solids and firmness of figs involves the following steps:
[0013] S1.1, using SC-10 colorimeter to measure the color parameters (L*, a*, b*) of figs, where L* represents brightness, the larger the value, the brighter the fruit color; the range of L* value is 0-100; when the L* value is 0, it represents black, and when the L* value is 100, it represents white;
[0014] a* represents red and green, and the a* value from negative to positive indicates the color evolution from green to red; b* represents blue and yellow, and the b* value from negative to positive indicates the color evolution from blue to yellow; three measurements were made at the spectrum collection point, and the average L*, a* and b* values were used as the color parameters of the sample;
[0015] S1.2, use GY-4 fruit hardness tester to measure the hardness of figs, measure each fig fruit 3 times and calculate the average value; use handheld sugar refractometer to measure the soluble solids of figs, measure each fig fruit 3 times and calculate the average value.
[0016] The CARS algorithm is used to extract characteristic wavelengths to remove a large amount of redundant data and reduce the model calculation cost. The following steps are included:
[0017] S3.1, the fig sample set was divided into a calibration set and a prediction set according to a 4:1 ratio, and the partial least squares method was used for modeling analysis, and the absolute value weight of the regression coefficient of each sampling process was recorded;
[0018] S3.2, using an exponential decay function to remove wavelengths with small absolute weights of regression coefficients;
[0019] S3.3, remove variables based on the number of iterative sampling variables, establish an analytical prediction model based on the screened variables and calculate its RMSE;
[0020] S3.4, perform loop calculation according to the set number of loop iterations, determine the best variable set according to the minimum RMSECV, that is, the characteristic variables of the desired wavelength, and then remove redundant data.
[0021] The linear regression model of multiple independent variables is constructed by using partial least squares through spectral data and color index data, including the following steps:
[0022] S4.1, constructing data sets X0 and Y0 with color index data as independent variables and spectral data as dependent variables, and standardizing the original data of the data sets to form N*P dimensional matrices and N*n dimensional matrices, respectively, where N is the number of samples, n is the number of dependent variables (n=1 in this application), and p is the number of independent variables (p=2028 in this application);
[0023]
[0024] S4.2, perform principal component analysis on matrices X and Y, and set the first principal component axis vectors of X and Y to ω1(p×1) and c1(n×1), respectively. Then the first pair of principal components is
[0025] t1=Xω1,u1=Yc1;
[0026] S4.3, perform principal component regression modeling and obtain the regression equation:
[0027]
[0028] Use the principal components of X to regress Y.
[0029]
[0030] Among them, X1, Y1 and F are residual matrices;
[0031] S4.4, use the least squares method to solve the above regression equation to obtain the first set of regression coefficients:
[0032]
[0033] S4.5, solve the residual matrices X1 and Y1 using the least squares method to calculate the second set of regression coefficients:
[0034]
[0035] At this time, the regression equation is:
[0036]
[0037] in,
[0038]
[0039] Finally, we get:
[0040]
[0041]
[0042] S4.6, build a linear regression model, and use the model's coefficient of determination (R2), the ratio of the standard deviation of the validation set to the standard error of the prediction, and the root mean square error to determine the quality of the model. The calculation formula is as follows:
[0043]
[0044] in, is the predicted value, y i is the measurement value of the ith graph, is the mean value of the training set or prediction set. L and m are the number of samples in the training set and prediction set, is the number of samples in the training set or prediction set, and SD is the standard error of the prediction set.
[0045] 2028 bands were selected as effective bands in the 500-1200 nm region to eliminate the noise existing in the front and rear regions of the spectrum.
[0046] The CARS algorithm is used to optimize the linear regression model, and the rapid and non-destructive identification of ripe figs by color index includes the following steps:
[0047] S5.1, use baseline correction and orthogonal signals to correct and remove noise to eliminate environmental and instrument noise and baseline drift in the NTR spectrum;
[0048] S5.2, performing gradient and normalization preprocessing on the linear regression model to obtain a linear regression model with good calibration ability for color indices a* and L*;
[0049] S5.3, combining the CARS algorithm and the PLSR algorithm, using fewer variables, constructs a linear regression model with better stability and higher prediction accuracy.
[0050] The present invention adopts the structure, extracts characteristic wavelengths by adopting the CARS algorithm to remove a large amount of redundant data and reduce the model calculation cost; pre-processes near-infrared spectrum data, performs principal component analysis dimension reduction and characteristic wavelength selection, and adopts the nonlinear algorithm PLSR to construct and optimize the model; accurately reflects the maturity of fig fruit by measuring the color index of fig, and constructs a linear regression model of multivariate independent variables by using the partial least squares through the spectrum data and the color index data; and constructs a data set with the color index data as the independent variable and the spectrum data as the dependent variable, and standardizes the original data of the data set, which has the advantages of accuracy, practicality, economy and reliability. Description of the drawings:
[0051] Figure 1 It is a schematic diagram of the process of the present invention.
[0052] Figure 2 It is a schematic diagram of the spectrum curve of the present invention.
[0053] Figure 3 Schematic diagram of extracting characteristic wavelengths using the CARS algorithm of the present invention.
[0054] Figure 4 It is a fitting diagram of the predicted value and the true value of each color index of the present invention. Specific implementation method:
[0055] In order to clearly illustrate the technical features of the present solution, the present invention is described in detail below through specific implementation methods and in conjunction with the accompanying drawings.
[0056] like Figure 1-4 As shown in, a fig maturity assessment method based on spectral data and mathematical models, the assessment method comprises the following steps:
[0057] S1, measuring the color index, soluble solids and firmness of figs;
[0058] S2, spectra were collected at three randomly selected positions along the equator of the fig, and the average value was used as the original spectrum of the fig sample;
[0059] S3, uses the CARS algorithm to extract characteristic wavelengths to remove a large amount of redundant data and reduce the model calculation cost;
[0060] S4, constructing a linear regression model of multiple independent variables using partial least squares through spectral data and color index data;
[0061] S5, CARS algorithm and PLSR algorithm were used to optimize the linear regression model, and the color index was used to achieve rapid and non-destructive discrimination of ripe figs.
[0062] Measuring the color index, soluble solids and firmness of figs involves the following steps:
[0063] S1.1, using SC-10 colorimeter to measure the color parameters (L*, a*, b*) of figs, where L* represents brightness, the larger the value, the brighter the fruit color; the range of L* value is 0-100; when the L* value is 0, it represents black, and when the L* value is 100, it represents white;
[0064] a* represents red and green, and the a* value from negative to positive indicates the color evolution from green to red; b* represents blue and yellow, and the b* value from negative to positive indicates the color evolution from blue to yellow; three measurements were made at the spectrum collection point, and the average L*, a* and b* values were used as the color parameters of the sample;
[0065] S1.2, use GY-4 fruit hardness tester to measure the hardness of figs, measure each fig fruit 3 times and calculate the average value; use handheld sugar refractometer to measure the soluble solids of figs, measure each fig fruit 3 times and calculate the average value.
[0066] The CARS algorithm is used to extract characteristic wavelengths to remove a large amount of redundant data and reduce the model calculation cost. The following steps are included:
[0067] S3.1, the fig sample set was divided into a calibration set and a prediction set according to a 4:1 ratio, and the partial least squares method was used for modeling analysis, and the absolute value weight of the regression coefficient of each sampling process was recorded;
[0068] S3.2, using an exponential decay function to remove wavelengths with small absolute weights of regression coefficients;
[0069] S3.3, remove variables based on the number of iterative sampling variables, establish an analytical prediction model based on the screened variables and calculate its RMSE;
[0070] S3.4, perform loop calculation according to the set number of loop iterations, determine the best variable set according to the minimum RMSECV, that is, the characteristic variables of the desired wavelength, and then remove redundant data.
[0071] The linear regression model of multiple independent variables is constructed by using partial least squares through spectral data and color index data, including the following steps:
[0072] S4.1, constructing data sets X0 and Y0 with color index data as independent variables and spectral data as dependent variables, and standardizing the original data of the data sets to form N*P dimensional matrices and N*n dimensional matrices, respectively, where N is the number of samples, n is the number of dependent variables (n=1 in this application), and p is the number of independent variables (p=2028 in this application);
[0073]
[0074] S4.2, perform principal component analysis on matrices X and Y, and set the first principal component axis vectors of X and Y to ω1(p×1) and c1(n×1), respectively. Then the first pair of principal components is
[0075] t1=Xω1,u1=Yc1;
[0076] S4.3, perform principal component regression modeling and obtain the regression equation:
[0077]
[0078] Use the principal components of X to regress Y.
[0079]
[0080] Among them, X1, Y1 and F are residual matrices;
[0081] S4.4, use the least squares method to solve the above regression equation to obtain the first set of regression coefficients:
[0082]
[0083] S4.5, solve the residual matrices X1 and Y1 using the least squares method to calculate the second set of regression coefficients:
[0084]
[0085] At this time, the regression equation is:
[0086]
[0087]
[0088] in,
[0089]
[0090] Finally, we get:
[0091]
[0092] S4.6, build a linear regression model, and use the model's coefficient of determination (R2), the ratio of the standard deviation of the validation set to the standard error of the prediction, and the root mean square error to determine the quality of the model. The calculation formula is as follows:
[0093]
[0094] in, is the predicted value, y i is the measurement value of the ith graph, is the mean value of the training set or prediction set. L and m are the number of samples in the training set and prediction set, is the number of samples in the training set or prediction set, and SD is the standard error of the prediction set.
[0095] 2028 bands were selected as effective bands in the 500-1200 nm region to eliminate the noise existing in the front and rear regions of the spectrum.
[0096] The CARS algorithm is used to optimize the linear regression model, and the rapid and non-destructive identification of ripe figs by color index includes the following steps:
[0097] S5.1, use baseline correction and orthogonal signals to correct and remove noise to eliminate environmental and instrument noise and baseline drift in the NTR spectrum;
[0098] S5.2, performing gradient and normalization preprocessing on the linear regression model to obtain a linear regression model with good calibration ability for color indices a* and L*;
[0099] S5.3, combining the CARS algorithm and the PLSR algorithm, using fewer variables, constructs a linear regression model with better stability and higher prediction accuracy.
[0100] The working principle of the fig maturity assessment method based on spectral data and mathematical model in the embodiment of the present invention is as follows: the fig maturity assessment method based on spectral data and mathematical model adopts a plurality of different preprocessing algorithms to preprocess the spectral data of fresh figs and extract characteristic wavelength variables, constructs the best preprocessing model of color index, SSC and hardness, performs partial least squares regression modeling through color index data and spectral data, formulates standardized evaluation indexes, adopts nonlinear algorithm PLSR and variable screening algorithm CARS to construct and optimize the model, replaces the existing SSC index and hardness index by color index to realize rapid and non-destructive discrimination of mature figs, can effectively improve the efficiency of field fruit harvesting, greatly improve the economic value of fresh figs, and promote the healthy development of the fig industry chain.
[0101] Rapid non-destructive detection methods for fruit quality and accurate harvesting have always been hot research issues. Researchers have explored a variety of fruit maturity indicators and developed visible / near-infrared spectroscopy detection technology and different chemometric algorithms to predict fruit maturity models. Most of the work focuses on indicators such as fruit hardness and sugar content. A large number of studies have shown that fruit color is intrinsically linked to the nutrient content and maturity of the fruit, and can well reflect related information. Therefore, color plays an important role in the evaluation of fruit maturity and internal quality.
[0102] For fruits with high hardness, such as watermelon, mango and apple, SSC and hardness can indeed predict their maturity well. However, mature figs have thin skin and soft flesh. SSC and hardness vary greatly among different varieties, maturity stages and storage processes. The effect of predicting mature figs by SSC and hardness is not ideal, so it is difficult to establish an accurate prediction model; because yellow-green figs are rich in carotenoids, anthocyanins, flavonoids and other chemicals, the conjugated double bonds of carotenoids, the phenolic hydroxyl groups of anthocyanins and the hydroxyl groups of flavonoid compounds have stronger reflection signals in their diffuse reflectance spectra, so the fig quality detection model constructed based on color index has better prediction effect; based on this, this application aims to explore new methods for evaluating the maturity of figs and achieve high-quality and accurate harvesting of figs.
[0103] In the overall scheme, the evaluation method includes the following steps: measuring the color index, soluble solids and hardness of figs; randomly selecting three positions along the equator of the fig map to collect spectra, and taking the average value as the original spectrum of the fig sample; using the CARS algorithm to extract characteristic wavelengths to remove a large amount of redundant data and reduce the model calculation cost; using partial least squares to construct a linear regression model of multivariate independent variables based on spectral data and color index data; using the CARS algorithm and PLSR algorithm to optimize the linear regression model, and realizing rapid and non-destructive discrimination of mature figs through color indicators.
[0104] Further, measuring the color index, soluble solids and hardness of figs includes the following steps: using an SC-10 colorimeter to measure the color parameters (L*, a*, b*) of figs, wherein L* represents brightness, and the larger the value, the brighter the fruit color; the range of L* values is 0-100; when the L* value is 0, it represents black, and when the L* value is 100, it represents white; a* represents red and green, and a* values from negative to positive represent the color evolution from green to red; b* represents blue and yellow, and b* values from negative to positive represent the color evolution from blue to yellow; three measurements were performed at the spectrum collection point, and the average L*, a* and b* values were used as the color parameters of the sample; using a GY-4 fruit hardness meter to measure the hardness of figs, measuring each fig fruit 3 times, and calculating the average value; using a handheld sugar refractometer to measure the soluble solids of figs, measuring each fig fruit 3 times, and calculating the average value.
[0105] Before spectral analysis, the light source was heated for 20 minutes. The scanned spectrum of a 99% reflective white board was used as the baseline data. The reflective white board was rescanned every 30 samples. The spectrum was obtained by randomly selecting three positions along the equator of the fruit, and the average value was used as the original spectrum of the sample. If a spectrum was significantly different from the NIR spectra of other samples, it was resampled at the same position.
[0106] Each sample data consists of 2028 variables. Due to the multicollinearity between variables, a large amount of redundant data exists, which increases the calculation cost of the model. Therefore, it is necessary to extract the characteristic wavelength. UVE, SPA, GA and CARS algorithms can be used to extract the characteristic wavelength.
[0107] After algorithm comparison and combined with actual application scenarios, compared with GA, SPA and UVE algorithms, the CARS algorithm has the best optimization effect on the PLSR model.
[0108] Specifically, CARS is a feature variable selection method that combines Monte Carlo sampling and PLS regression modeling. Through adaptive weighted sampling, points with larger absolute value weights of the PLS model regression coefficients are retained as new subsets, points with smaller weights are removed, and then a PLS model is established based on the new subset; after multiple calculations, the wavelength in the subset with the smallest root mean square error of interactive verification (RMSECV) of the PLS model is selected as the feature wavelength.
[0109] The CARS algorithm is used to extract characteristic wavelengths to remove a large amount of redundant data and reduce the model calculation cost, including the following steps: a fig sample set is divided into a calibration set and a prediction set according to a ratio of 4:1, a partial least squares method is used for modeling analysis, and the absolute value weight of the regression coefficient of each sampling process is recorded; 50 samplings are performed in the present application, and an exponential decay function is used to remove wavelengths with small absolute value weights of the regression coefficient; variables are eliminated based on the number of iterative sampling variables, an analysis and prediction model based on screening variables is established, and its RMSE is calculated; a cyclic calculation is performed according to the set number of cyclic iterations, and the optimal variable set is determined according to the minimum RMSECV, which is the characteristic variable of the desired wavelength, and then redundant data is removed.
[0110] Partial least squares regression is a supervised learning algorithm that uses partial least squares to construct a linear regression model for multiple independent variables. It is often used as a dimensionality reduction technique in machine learning and predictive analysis, especially for highly collinear data with many factors.
[0111] Specifically, constructing a linear regression model of multiple independent variables by using partial least squares through spectral data and color index data includes the following steps:
[0112] S4.1, constructing data sets X0 and Y0 with color index data as independent variables and spectral data as dependent variables, and standardizing the original data of the data sets to form N*P dimensional matrices and N*n dimensional matrices, respectively, where N is the number of samples, n is the number of dependent variables (n=1 in this application), and p is the number of independent variables (p=2028 in this application);
[0113]
[0114] S4.2, perform principal component analysis on matrices X and Y, and set the first principal component axis vectors of X and Y to ω1(p×1) and c1(n×1), respectively. Then the first pair of principal components is
[0115] t1=Xω1,u1=Yc1;
[0116] S4.3, perform principal component regression modeling and obtain the regression equation:
[0117]
[0118] Use the principal components of X to regress Y.
[0119]
[0120] Among them, X1, Y1 and F are residual matrices;
[0121] S4.4, use the least squares method to solve the above regression equation to obtain the first set of regression coefficients:
[0122]
[0123] S4.5, solve the residual matrices X1 and Y1 using the least squares method to calculate the second set of regression coefficients:
[0124]
[0125] At this time, the regression equation is:
[0126]
[0127] in,
[0128]
[0129] Finally, we get:
[0130]
[0131] S4.6, build a linear regression model, and use the model's coefficient of determination (R2), the ratio of the standard deviation of the validation set to the standard error of the prediction, and the root mean square error to determine the quality of the model. The calculation formula is as follows:
[0132]
[0133] in, is the predicted value, y i is the measurement value of the ith graph, is the mean value of the training set or prediction set. N and m are the number of samples in the training set and prediction set, is the number of samples in the training set or prediction set, and SD is the standard error of the prediction set.
[0134] The results of the physical and chemical indicators obtained are shown in Table 1. The variation range and mean square error of L*, a*, b*, E, SSC and hardness are all large, indicating that there are large differences in the quality of fig samples; therefore, the sample is representative to a certain extent; the measurement results show that the increase in L* value indicates that the color of the peel becomes darker, the increase in the absolute value of a* indicates that the green color of the peel deepens, and the increase in the absolute value of b* indicates that the color of the peel gradually turns yellow. The minimum mean square error of a* shows that it is the most stable and is least affected by the change of peel color. The smaller the E value, the less difference in the peel color of mature figs. The difference in the hardness and SSC of figs shows that the quality of figs cannot be judged based solely on the hardness and SSC of figs.
[0135]
[0136] Table 1
[0137] Since there is obvious noise in the front and back regions of the spectrum, 2028 bands were selected as effective bands in the 500-1200 nm region. The spectral curves of the effective regions of all samples are shown in the attached figure. Figure 2 As shown in the figure, all spectral curves show similar trends, but different reflectance intensities, indicating that different fruits contain the same internal substances, but the content of individual compounds is different; further, the spectral curve has a strong absorption peak at 740nm and 990nm, and a weak absorption peak at 640nm; the absorption peak at 960nm is related to the second-order frequency harmonic of the OH bond, and the absorption peak at 1040nm is related to the OH bond and the NH bond. Therefore, the difference in spectral reflectance intensity provides a premise for establishing a regression model.
[0138] Preferably, the linear regression model is optimized by using the CARS algorithm, and the rapid and non-destructive discrimination of ripe figs by color index includes the following steps: using baseline correction and orthogonal signals to correct and remove noise, so as to eliminate noise and baseline drift in the environment and instrument in the NTR spectrum; performing gradient and normalization preprocessing on the linear regression model to obtain a linear regression model with color indexes a* and L* having good calibration ability; combining the CARS algorithm and the PLSR algorithm, using fewer variables, to construct a linear regression model with better stability and higher prediction accuracy.
[0139] In order to highlight the prediction accuracy of the model after screening variables, the feature extraction algorithm was combined with the nonlinear algorithm to establish the optimal prediction model for each index. The variable screening algorithm (CARS) and the nonlinear algorithm (PLSR) of this application both have obvious advantages, using fewer variables to construct models with better stability and higher prediction accuracy. The prediction results of fruit color parameters are significantly higher than those of SSC and hardness indicators, which shows that the spectral information obtained from the spectral system has higher potential in predicting color, and nonlinear models can provide better results.
[0140] As attached Figure 3 As shown in the figure, 212 wavelengths of L* were extracted by CARS algorithm, and the wavelength utilization rate was 10%. The subsequent PLSR modeling increased the prediction accuracy of the prediction set by about 0.95, which was 38% higher than the prediction result of the entire band; 104 wavelengths of a* were extracted by CARS algorithm, and the utilization rate of wavelength variables was 5%. After PLSR modeling, the accuracy of the prediction set was improved to 0.96, which was about 30% higher than the prediction result of the full band. Using the CARS algorithm, 104 wavelengths of SSC were selected, and the utilization rate of wavelength variables was 5%. After PLSR modeling, the accuracy of the prediction set was improved to about 0.90, which was 77% higher than the prediction result of the full band, and the improvement was the largest among the 6 indicators. The CARS algorithm was used to screen 104 wavelengths of hardness, and the utilization rate of wavelength variables was 6%. After PLSR modeling, the accuracy of the prediction set was improved to about 0.87.
[0141] Due to the nutritional value of figs, the demand for fresh ripe figs is increasing. In order to improve the accuracy of fig maturity identification and achieve rapid and non-destructive identification, this application preprocessed near-infrared spectral data, performed principal component analysis dimensionality reduction and characteristic wavelength selection, and used the nonlinear algorithm PLSR to construct and optimize the model.
[0142] It is particularly noted that for yellow-green figs, the color L* and a* values can better reflect the maturity and internal quality of the fruit than the fruit hardness and SSC, which provides a new idea and method for rapid non-destructive testing of fig maturity and quality, filling the gap in non-destructive testing of figs through fruit color. It also provides a theoretical basis and technical support for rapid non-destructive testing of other fruit quality.
[0143] In summary, the fig maturity assessment method based on spectral data and mathematical model in the embodiment of the present invention adopts a variety of different preprocessing algorithms to preprocess the spectral data of fresh figs and extract characteristic wavelength variables, constructs the optimal preprocessing model of color index, SSC and hardness, performs partial least squares regression modeling through color index data and spectral data, formulates standardized evaluation indicators, adopts nonlinear algorithm PLSR and variable screening algorithm CARS to construct and optimize the model, and replaces the existing SSC index and hardness index by color index to achieve rapid and non-destructive discrimination of mature figs, which can effectively improve the efficiency of field fruit harvesting, greatly improve the economic value of fresh figs, and promote the healthy development of the fig industry chain.
[0144] The above specific implementation manner cannot be used as a limitation on the protection scope of the present invention. For those skilled in the art, any substitution, improvement or change made to the implementation manner of the present invention falls within the protection scope of the present invention.
[0145] The matters not described in detail in the present invention are all known technologies to those skilled in the art.
Claims
1. A fig maturity assessment method based on spectral data and mathematical models, characterized in that: The evaluation method comprises the following steps: S1, measuring the color index, soluble solids and firmness of figs; S2, spectra were collected at three randomly selected positions along the equator of the fig, and the average value was used as the original spectrum of the fig sample; S3, uses the CARS algorithm to extract characteristic wavelengths to remove a large amount of redundant data and reduce the model calculation cost; S4, constructing a linear regression model of multiple independent variables using partial least squares through spectral data and color index data; S5, CARS algorithm and PLSR algorithm were used to optimize the linear regression model, and the color index was used to achieve rapid and non-destructive discrimination of ripe figs.
2. The fig maturity assessment method based on spectral data and mathematical model according to claim 1, characterized in that, Measuring the color index, soluble solids and firmness of figs involves the following steps: S1.1, using SC-10 colorimeter to measure the color parameters (L*, a*, b*) of figs, where L* represents brightness, the larger the value, the brighter the fruit color; the range of L* value is 0-100; when the L* value is 0, it represents black, and when the L* value is 100, it represents white; a* represents red and green, and the a* value from negative to positive indicates the color evolution from green to red; b* represents blue and yellow, and the b* value from negative to positive indicates the color evolution from blue to yellow; three measurements were made at the spectrum collection point, and the average L*, a* and b* values were used as the color parameters of the sample; S1.2, use GY-4 fruit hardness tester to measure the hardness of figs, measure each fig fruit 3 times and calculate the average value; use handheld sugar refractometer to measure the soluble solids of figs, measure each fig fruit 3 times and calculate the average value.
3. The fig maturity assessment method based on spectral data and mathematical model according to claim 1, characterized in that, The CARS algorithm is used to extract characteristic wavelengths to remove a large amount of redundant data and reduce the model calculation cost. The following steps are included: S3.1, the fig sample set was divided into a calibration set and a prediction set according to a 4:1 ratio, and the partial least squares method was used for modeling analysis, and the absolute value weight of the regression coefficient of each sampling process was recorded; S3.2, using an exponential decay function to remove wavelengths with small absolute weights of regression coefficients; S3.3, remove variables based on the number of iterative sampling variables, establish an analytical prediction model based on the screened variables and calculate its RMSE; S3.4, perform loop calculation according to the set number of loop iterations, determine the best variable set according to the minimum RMSECV, that is, the characteristic variables of the desired wavelength, and then remove redundant data.
4. The fig maturity assessment method based on spectral data and mathematical model according to claim 1, characterized in that, The linear regression model of multiple independent variables is constructed by using partial least squares through spectral data and color index data, including the following steps: S4.1, constructing data sets X0 and Y0 with color index data as independent variables and spectral data as dependent variables, and standardizing the original data of the data sets to form N*P dimensional matrices and N*n dimensional matrices, respectively, where N is the number of samples, n is the number of dependent variables (n=1 in this application), and p is the number of independent variables (p=2028 in this application); S4.2, perform principal component analysis on matrices X and Y, and set the first principal component axis vectors of X and Y to ω1(p×1) and c1(n×1), respectively. Then the first pair of principal components is t1=Xω1,u1=Yc1; S4.3, perform principal component regression modeling and obtain the regression equation: Use the principal components of X to regress Y. Y=t1r1 T +Y1. Among them, X1, Y1 and F are residual matrices; S4.4, use the least squares method to solve the above regression equation to obtain the first set of regression coefficients: S4.5, solve the residual matrices X1 and Y1 using the least squares method to calculate the second set of regression coefficients: At this time, the regression equation is: in, <h2 style=";text-align:left;direction:ltr">A2=W2R2<h2 style=";text-align:left;direction:ltr"> T <h2 style=";text-align:left;direction:ltr"> ,W2=(ω1,ω2),R2=(r1,r2), Finally, we get: S4.6, build a linear regression model, and use the model's coefficient of determination (R2), the ratio of the standard deviation of the validation set to the standard error of the prediction, and the root mean square error to determine the quality of the model. The calculation formula is as follows: in, is the predicted value, y i is the measurement value of the ith graph, is the mean value of the training set or prediction set. L and m are the number of samples in the training set and prediction set, is the number of samples in the training set or prediction set, and SD is the standard error of the prediction set.
5. The fig maturity assessment method based on spectral data and mathematical model according to claim 1, characterized in that: 2028 bands were selected as effective bands in the 500-1200 nm region to eliminate the noise existing in the front and rear regions of the spectrum.
6. The fig maturity assessment method based on spectral data and mathematical model according to claim 1, characterized in that, The CARS algorithm is used to optimize the linear regression model, and the rapid and non-destructive identification of ripe figs by color index includes the following steps: S5.1, use baseline correction and orthogonal signals to correct and remove noise to eliminate environmental and instrument noise and baseline drift in the NTR spectrum; S5.2, performing gradient and normalization preprocessing on the linear regression model to obtain a linear regression model with good calibration ability for color indices a* and L*; S5.3, combining the CARS algorithm and the PLSR algorithm, using fewer variables, constructs a linear regression model with better stability and higher prediction accuracy.
Citation Information
Cited By
Blueberry SSC prediction method based on spectral index optimization through fractional derivative coupling
CN120067620A
A Prediction Method of Blueberry SSC Based on Fractional Derivative Coupled Optimization of Spectral Index
CN120067620B
