Efficient nondestructive detection method for sugar content of strawberry based on intelligent algorithm
By combining hyperspectral imager and near-infrared spectrometer with intelligent algorithms to process strawberry spectral data, the destructive and inefficient problems of traditional detection methods have been solved, enabling rapid, non-destructive, and accurate detection of strawberry sugar content and promoting the intelligent development of strawberry detection technology.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- SOUTH CHINA UNIV OF TECH
- Filing Date
- 2025-06-16
- Publication Date
- 2026-04-14
AI Technical Summary
Traditional methods for detecting strawberry sugar content are destructive, inefficient, and susceptible to human error, making it difficult to meet the needs of the strawberry industry for refined development.
Strawberry spectral data were acquired using a hyperspectral imager and a near-infrared spectrometer. Intelligent algorithms were then used for wavelet denoising and polynomial baseline correction to extract key feature wavelengths. An SVM model was constructed and optimized to achieve rapid and non-destructive detection of strawberry sugar content.
This technology enables rapid, non-destructive, and accurate detection of strawberry sugar content, reducing human error, improving detection efficiency and accuracy, and promoting the development of strawberry detection technology towards intelligence.
Smart Images

Figure CN120703080B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of nondestructive testing technology, and particularly relates to an efficient nondestructive testing method for strawberry sugar content based on intelligent algorithms. Background Technology
[0002] Sugar content is a key indicator of strawberry quality and requires precise testing. It plays a crucial role in strawberry cultivation, harvesting, sorting, and sales. Traditional destructive testing methods, such as handheld refractometers, while providing relatively accurate sugar content values, have several drawbacks: first, they require destructive sampling of strawberries, affecting their integrity and marketability; second, they are inefficient and cannot meet the needs of large-scale strawberry quality testing; and third, they are easily affected by subjective factors such as human operation and environmental influences, leading to unstable measurement results. With the increasing scale and sophistication of the strawberry industry, traditional testing methods are no longer sufficient to meet market demands.
[0003] In recent years, spectral technology has gained widespread attention in the field of agricultural product quality testing due to its speed, non-destructive nature, and rich information content. Hyperspectral imagers and near-infrared spectrometers can acquire spectral data of strawberries in the 400–1000 nm wavelength range. This spectral data contains rich information about the internal chemical composition and physical structure of strawberries, which is closely related to quality indicators such as sugar content. However, spectral data is typically characterized by high dimensionality, strong noise, and complex nonlinear relationships, making direct use of raw spectral data for sugar content prediction often ineffective. Therefore, it is necessary to combine intelligent algorithms to process and analyze spectral data, extract key features related to sugar content, and establish accurate prediction models.
[0004] Intelligent algorithms and artificial intelligence technologies have been widely applied in the fields of agriculture and food testing in recent years. By introducing intelligent algorithms, complex spectral data can be effectively processed, key features extracted, prediction models optimized, and the accuracy and efficiency of testing improved. This method not only overcomes the limitations of traditional testing methods but also enables rapid and non-destructive testing of strawberry sugar content, representing an important trend in promoting the intelligent and efficient development of strawberry quality testing. Summary of the Invention
[0005] To address the aforementioned technical challenges, this invention proposes a highly efficient and non-destructive method for detecting strawberry sugar content based on intelligent algorithms. This method enables rapid, non-destructive, and accurate detection of strawberry sugar content, providing technical support for the intelligent development of the strawberry industry.
[0006] To achieve the above objectives, this invention provides an efficient and non-destructive method for detecting strawberry sugar content based on intelligent algorithms, comprising:
[0007] Acquire several strawberry spectral data and sugar content reference values, and divide the strawberry spectral data into a training set, a validation set, and a test set;
[0008] The spectral data is subjected to wavelet denoising and polynomial baseline correction to obtain preprocessed data;
[0009] Key feature wavelengths are extracted from the preprocessed data, and an initial SVM model is constructed based on the key feature wavelengths;
[0010] The initial SVM model is optimized using the training set to obtain an optimized SVM model;
[0011] Obtain the spectral data of the target strawberry and input it into the optimized SVM model to obtain the detection results.
[0012] Optionally, obtaining sugar content reference values includes:
[0013]
[0014] Where T represents the sugar content reference value, H represents the scale reading of the refractometer, and n represents the number of measurements.
[0015] Optionally, wavelet denoising of the spectral data includes:
[0016]
[0017] Where cj(k) represents the approximation coefficient at scale j, dj(k) represents the detail coefficient at scale j, sj-1(m) represents the signal at scale j-1, and h(m) and g(m) are the coefficients of the low-pass and high-pass filters, respectively.
[0018] Optionally, polynomial baseline correction of the spectral data includes:
[0019] I=a·λ 2 +b·λ+c;
[0020] Where I corresponds to spectral intensity, λ represents wavelength, and a, b, and c are polynomial coefficients.
[0021] Optionally, an initial SVM model is constructed based on the key feature wavelengths using the RBF kernel function. Initial parameters are determined through cross-validation to establish a nonlinear mapping relationship between strawberry sugar content and feature wavelengths. Considering the influence of individual fitness on the crossover probability, an adaptive crossover probability formula is designed as follows:
[0022]
[0023] Among them, P c The crossover probability of individuals. f represents the maximum and minimum crossover probabilities, respectively. i f represents individual fitness. avg fmax These are the population average and maximum fitness, respectively.
[0024] Optionally, the impact of individual fitness on mutation probability needs to be considered during the construction of the initial SVM model. The adaptive mutation probability formula is designed as follows:
[0025]
[0026] Among them, P m This represents the mutation probability of an individual, and k is a coefficient that controls the rate of change of the mutation probability.
[0027] Optionally, a fitness function is designed during the extraction of key feature wavelengths from the preprocessed data, and the fitness function is selected as R. 2 Using RMSE as key evaluation indicators, the predictive performance of the feature wavelength combination is quantitatively evaluated from two perspectives: goodness of fit and error magnitude. The calculation formulas are as follows:
[0028]
[0029] Where f represents the fitness value of an individual; α and β are weighting coefficients used to balance R0. 2 The relative importance of RMSE in fitness calculation, and satisfying α+β=1; RMSE max This is the RMSE value of the initial model built on the training set using the full wavelength range, used to normalize the RMSE so that it matches R0. 2 They have similar dimensions and ranges of values.
[0030] Optionally, when optimizing the initial SVM model using the training set, the impact of inertia weights on global and local search capabilities needs to be considered. The dynamic inertia weight adjustment formula is designed as follows:
[0031]
[0032] Where w represents the inertia weight of the current iteration, w start w end t and tmax are the initial and final inertia weights, respectively, and t and tmax are the current and maximum number of iterations, respectively.
[0033] Optionally, when optimizing the initial SVM model using the training set, it is also necessary to consider the escape mechanism when particles get stuck in local optima. The position update formula is designed as follows:
[0034] x i =x i +Δx·rand;
[0035] Where, x iThis represents the position of the particle, Δx is the step size, and rand is a random number.
[0036] Technical effects of the invention:
[0037] (1) Non-destructive testing: Traditional destructive testing methods, such as handheld refractometer measurement, require destructive sampling of strawberries, affecting their integrity and marketability. However, this invention uses a hyperspectral imager and a near-infrared spectrometer to obtain spectral data without damaging the strawberries, thus preserving their integrity. This aligns with the current development trend of non-destructive testing and provides a higher quality raw material guarantee for the subsequent sales and processing of strawberries.
[0038] (2) High Efficiency: Traditional methods are inefficient in meeting the demands of large-scale strawberry quality testing. The intelligent algorithm of this invention can quickly process high-dimensional spectral data, accurately extract key feature wavelengths, and significantly shorten the testing time. For example, in the data preprocessing stage, wavelet denoising and polynomial baseline correction can efficiently remove noise and correct the baseline, improving data quality. During feature extraction, the improved intelligent algorithm can quickly lock feature wavelengths highly correlated with sugar content, providing effective data support for model construction and meeting the timeliness requirements of large-scale testing.
[0039] (3) High Accuracy: Spectral data is complex, containing a large amount of noise and interference, making direct prediction of sugar content ineffective. This invention combines intelligent algorithms and optimized models to deeply explore the intrinsic relationship between spectral data and sugar content. Multiple measurements are taken to average the sugar content as a reference value, reducing random errors. Noise is removed and baselines are corrected during data preprocessing to improve data accuracy. Key feature wavelengths are accurately identified during feature extraction to reduce interference from irrelevant information. Finally, the optimized prediction model accurately maps the relationship between sugar content and feature wavelengths, significantly improving prediction accuracy and providing reliable data support for strawberry quality grading and harvesting decisions.
[0040] (4) Intelligentization: Integrating intelligent algorithms and artificial intelligence technologies, the system achieves automated and intelligent detection, reducing the need for manual operation, minimizing human error, and enhancing the stability and reliability of detection results. From data acquisition, preprocessing, and feature extraction to model construction and optimization, each step incorporates intelligent operational processes. For example, intelligent algorithms automatically extract feature wavelengths, avoiding the subjectivity and limitations of manual selection. Simultaneously, the model possesses self-learning and optimization capabilities, continuously improving its predictive performance based on new data, adapting to the detection of different strawberry varieties and maturity levels, promoting the intelligent development of strawberry detection technology, and enhancing the overall intelligence level of the industry.
[0041] (5) Wide Applicability: This invention targets strawberry sugar content detection, but its technical framework has broad applicability. The combination of hyperspectral imaging and near-infrared spectroscopy with intelligent algorithms can be extended to other agricultural product quality detection fields, such as detecting apple sugar content, citrus acidity, and tomato firmness, requiring only adjustments to data acquisition parameters and model structure based on the specific agricultural product. The preprocessing methods used in the solution, such as wavelet denoising and polynomial baseline correction, as well as the feature extraction and model optimization approaches, offer valuable insights for related fields of spectral data processing. Furthermore, the solution can be integrated with online detection equipment to achieve real-time detection on production lines, improving production efficiency and product quality. It provides a universal and flexible technical template for agricultural product quality detection, contributing to the intelligent upgrading of the agricultural industry. Attached Figure Description
[0042] The accompanying drawings, which form part of this application, are used to provide a further understanding of this application. The illustrative embodiments and descriptions of this application are used to explain this application and do not constitute an undue limitation of this application. In the drawings:
[0043] Figure 1 This is a flowchart illustrating the efficient and non-destructive testing method for strawberry sugar content based on intelligent algorithms, according to an embodiment of the present invention. Detailed Implementation
[0044] It should be noted that, unless otherwise specified, the embodiments and features described in this application can be combined with each other. This application will now be described in detail with reference to the accompanying drawings and embodiments.
[0045] It should be noted that the steps shown in the flowchart in the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions, and although a logical order is shown in the flowchart, in some cases the steps shown or described may be executed in a different order than that shown here.
[0046] like Figure 1 As shown, this embodiment provides a method for efficient and non-destructive testing of strawberry sugar content based on intelligent algorithms, including:
[0047] Acquire several strawberry spectral data and sugar content reference values, and divide the strawberry spectral data into a training set, a validation set, and a test set;
[0048] The spectral data is subjected to wavelet denoising and polynomial baseline correction to obtain preprocessed data;
[0049] Key feature wavelengths are extracted from the preprocessed data, and an initial SVM model is constructed based on the key feature wavelengths;
[0050] The initial SVM model is optimized using the training set to obtain an optimized SVM model;
[0051] Obtain the spectral data of the target strawberry and input it into the optimized SVM model to obtain the detection results.
[0052] Furthermore, a hyperspectral imager was used to scan the strawberries, acquiring spectral data in the 400-1000 nm wavelength range, while a handheld refractometer was used to measure sugar content. One hundred samples were collected, covering different varieties and ripeness levels. Sugar content reference values were obtained, including:
[0053]
[0054] Where T represents the sugar content reference value, H represents the refractometer reading, and n represents the number of measurements. This formula, by averaging multiple measurements, effectively reduces random errors and improves the accuracy of the measurement results. Data acquisition is the foundation of the entire scheme. The hyperspectral imager can acquire rich spectral information, while the handheld refractometer provides an accurate sugar content reference value. Averaging multiple measurements effectively reduces random errors and improves the accuracy of the measurement results. This method, combining destructive and non-destructive testing, provides a high-quality data foundation for subsequent model training.
[0055] Furthermore, wavelet denoising of the spectral data includes:
[0056]
[0057] Where cj(k) represents the approximation coefficients at the j-th scale, dj(k) represents the detail coefficients at the j-th scale, sj-1(m) represents the signal at the (j-1)-th scale, and h(m) and g(m) are the coefficients of the low-pass and high-pass filters, respectively. The db4 wavelet basis function is chosen, with a decomposition scale of 3, to remove high-frequency noise and retain useful information in the signal.
[0058] Furthermore, polynomial baseline correction of the spectral data includes:
[0059] I=a·λ 2 +b·λ+c;
[0060] Here, I corresponds to spectral intensity, λ represents wavelength, and a, b, and c are polynomial coefficients. Baseline correction using second-order polynomial fitting eliminates slow variation trends in the spectral data, improving its consistency and comparability. Spectral data is susceptible to noise and baseline drift during acquisition. Wavelet denoising effectively removes high-frequency noise while preserving useful information in the signal; polynomial baseline correction eliminates slow variation trends in the spectral data, improving its consistency and comparability. These two preprocessing steps significantly improve data quality, laying a solid foundation for subsequent feature extraction and model building.
[0061] Furthermore, an improved genetic algorithm was used to extract characteristic wavelengths from the strawberry spectral data. Initialization parameters: population size 50, chromosome length 121, crossover probability 0.8, mutation probability 0.1. The fitness function was based on R... 2 Alternatively, RMSE is used to evaluate the accuracy of the feature wavelength combination in predicting strawberry sugar content. An adaptive crossover and mutation probability, along with an elite retention strategy, is employed, evolving through 100 generations to obtain the optimal feature wavelength combination. An initial SVM model is constructed based on the key feature wavelengths using the RBF kernel function. Initial parameters are determined through cross-validation to establish a nonlinear mapping relationship between strawberry sugar content and feature wavelengths. Considering the influence of individual fitness on the crossover probability, an adaptive crossover probability formula is designed as follows:
[0062]
[0063] Among them, P c The crossover probability of individuals. f represents the maximum and minimum crossover probabilities, respectively. i f represents individual fitness. avg f max These represent the population average and maximum fitness, respectively. Individuals with low fitness receive a higher crossover probability, increasing population diversity and preventing premature convergence.
[0064] Furthermore, in the process of constructing the initial SVM model, it is necessary to consider the impact of individual fitness on the mutation probability, and the adaptive mutation probability formula is designed as follows:
[0065]
[0066] Among them, P m This represents the mutation probability of an individual, and k is a coefficient that controls the rate of change of the mutation probability. Individuals with low fitness acquire a higher mutation probability, further enhancing population diversity.
[0067] Furthermore, in the feature extraction process based on the genetic algorithm, a fitness function was carefully designed to ensure that the algorithm can evolve in the direction of improving the accuracy of strawberry sugar content prediction. A fitness function was designed during the extraction of key feature wavelengths from the preprocessed data, and the fitness function was selected as R. 2 Using RMSE as key evaluation indicators, the predictive performance of the feature wavelength combination is quantitatively evaluated from two perspectives: goodness of fit and error magnitude. The calculation formulas are as follows:
[0068]
[0069] Where f represents the fitness value of an individual; α and β are weighting coefficients used to balance R0. 2 The relative importance of RMSE in fitness calculation, and satisfying α+β=1; RMSEmax This is the RMSE value of the initial model built on the training set using the full wavelength range, used to normalize the RMSE so that it matches R0. 2 They have similar dimensions and value ranges. This fitness function design allows the genetic algorithm to comprehensively consider the model's goodness of fit and prediction error during the search for feature wavelength combinations, thereby more accurately selecting the feature wavelength combinations most valuable for predicting strawberry sugar content.
[0070] Feature extraction is a crucial step in strawberry sugar content detection. An improved genetic algorithm can automatically search for the most critical combination of feature wavelengths for sugar content prediction. This improved genetic algorithm enhances search efficiency and convergence speed by adaptively adjusting crossover and mutation probabilities and introducing an elite retention strategy. The SVM model then constructs a prediction model using the selected feature wavelengths. The RBF kernel function effectively handles nonlinear relationships, establishing a mapping between strawberry sugar content and spectral features, providing a good starting point for subsequent model optimization.
[0071] Furthermore, the collected strawberry spectral dataset was divided into training, validation, and test sets in a 7:1:2 ratio. The SVM parameters were optimized using an improved PSO on the training set. PSO parameter initialization: particle size 30, maximum iterations 100, inertia weight initially 0.9 decreasing to 0.4. Dynamic adjustment of the inertia weight and the introduction of a jump mechanism optimized the SVM kernel function parameter σ and penalty parameter C to improve the accuracy and generalization ability of the strawberry sugar content prediction model. During the optimization of the initial SVM model using the training set, the impact of inertia weight on global and local search capabilities needs to be considered. The dynamic inertia weight adjustment formula is designed as follows:
[0072]
[0073] Where w represents the inertia weight of the current iteration, w start w end t and tmax are the initial and final inertia weights, respectively, and t and tmax are the current and maximum number of iterations, respectively.
[0074] Furthermore, the inertia weight gradually decreases with the number of iterations, balancing global and local search capabilities. When optimizing the initial SVM model using the training set, it is also necessary to consider the escape mechanism when particles get stuck in local optima. The position update formula is designed as follows:
[0075] x i =x i +Δx·rand;
[0076] Where, x i This represents the position of the particle, Δx is the step size, and rand is a random number.
[0077] When a particle fails to update its individual extreme value for L consecutive iterations, with probability P jump Randomly adjust their positions to help the population escape local optima and continue searching for the global optimum.
[0078] In strawberry sugar content detection, model training and optimization are crucial. By appropriately dividing the dataset, the scientific rigor and effectiveness of the model during training, validation, and testing are ensured. The improved PSO algorithm, through dynamically adjusting inertia weights and introducing a local optimum escape mechanism, can more accurately optimize SVM model parameters, improving the model's prediction accuracy and generalization ability. This optimization process not only accelerates the model's convergence speed but also enhances its adaptability to different strawberry sample data conditions, ensuring the model can accurately predict strawberry sugar content.
[0079] Evaluate the optimized SVM model using the test set. Calculate Ri. 2 Indicators such as RMSE and MAE. If R... 2 If the RMSE is ≥0.8 and low, the model will be integrated into the detection device. During actual detection, the strawberry spectral data is preprocessed and characteristic wavelengths are extracted before being input into the model to predict sugar content.
[0080] Model testing and application are the final stages of the solution. Evaluation on independent test sets verifies the model's predictive performance and generalization ability. These metrics comprehensively reflect the model's predictive effectiveness, providing a scientific basis for its practical application. In practical applications, the optimized model can quickly and accurately predict strawberry sugar content, providing strong support for strawberry quality grading and harvesting decisions, and promoting the intelligent development of the strawberry industry.
[0081] A specific application example of this invention:
[0082] First, data collection was conducted. Each strawberry sample was scanned using a hyperspectral imager, acquiring spectral data within the 400-1000 nm wavelength range. Simultaneously, a handheld refractometer was used to measure the sugar content of each sample three times, and the average value was calculated as the final sugar content reference value. The 100 collected samples covered various strawberry varieties and different stages of ripeness to ensure data diversity and representativeness.
[0083] The results of the sugar content reference values collected are shown in Table 1.
[0084] Table 1
[0085]
[0086] Wavelet denoising and polynomial baseline correction were performed on the acquired spectral data. Specifically, the db4 wavelet basis function was selected, and the decomposition scale was set to 3. Wavelet denoising was applied to the spectral data, effectively removing high-frequency noise. Subsequently, baseline correction was performed on the denoised spectral data using quadratic polynomial fitting, eliminating the influence of baseline drift and improving data consistency and comparability.
[0087] The spectral data results after data preprocessing are shown in Table 2.
[0088] Table 2
[0089]
[0090] An improved genetic algorithm was used to extract features from the preprocessed spectral data, selecting 10 feature wavelengths most strongly correlated with strawberry sugar content. Based on this, an SVM model was constructed, using RBF as the kernel function. Initial model parameters were determined through cross-validation, providing a foundation for subsequent model optimization. The extracted feature wavelength points are shown in Table 3.
[0091] Table 3
[0092]
[0093] The collected strawberry spectral dataset was divided into training, validation, and test sets in a ratio of 7:1:2. Then, an improved PSO algorithm was used on the training set to optimize the parameters of the SVM model. The PSO algorithm parameters were set as follows: particle size 30, maximum number of iterations 100, and inertia weight linearly decreasing from 0.9 to 0.4. By dynamically adjusting the inertia weight and introducing a local optimum escape mechanism, the kernel function parameter σ and penalty parameter C of the SVM model were successfully optimized, significantly improving the model's prediction accuracy and generalization ability. The results of model training and optimization are shown in Table 4.
[0094] Table 4
[0095]
[0096] The optimized SVM model was evaluated using a test set. Test results show that the model achieves R0 on the test set. 2 The model achieved a value of 0.91, an RMSE of 0.85, and a MAE of 0.68, indicating good predictive ability and generalization performance. Therefore, it was decided to integrate this model into a strawberry sugar content detection device. In practical applications, only preprocessing and feature extraction of the strawberry's spectral data are required, followed by inputting the extracted feature wavelengths into the model to quickly and accurately predict the strawberry's sugar content. The model's test indicators are shown in Table 5, and the test results are shown in Table 6.
[0097] Table 5
[0098]
[0099] Table 6
[0100]
[0101] The above practical example demonstrates the complete implementation process and results of a support vector machine-based strawberry sugar content determination scheme based on an improved genetic algorithm and particle swarm optimization. This invention effectively combines multiple intelligent algorithms to achieve efficient and non-destructive detection of strawberry sugar content, exhibiting good prediction accuracy and generalization ability, and providing a reliable technical means for strawberry quality inspection.
[0102] The above are merely preferred embodiments of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the technical scope disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.
Claims
1. A method for efficient and non-destructive detection of strawberry sugar content based on intelligent algorithms, characterized in that, include: Acquire several strawberry spectral data and sugar content reference values, and divide the strawberry spectral data into a training set, a validation set, and a test set; The spectral data is subjected to wavelet denoising and polynomial baseline correction to obtain preprocessed data; Key feature wavelengths are extracted from the preprocessed data, and an initial SVM model is constructed based on the key feature wavelengths; The initial SVM model is optimized using the training set to obtain an optimized SVM model; Acquire the spectral data of the target strawberry and input it into the optimized SVM model to obtain the detection results; A fitness function is designed during the extraction of key feature wavelengths from the preprocessed data, and the fitness function is selected as R. 2 Using RMSE as key evaluation indicators, the predictive performance of the feature wavelength combination is quantitatively evaluated from two perspectives: goodness of fit and error magnitude. The calculation formulas are as follows: ; Where f represents the fitness value of an individual; α and β are weighting coefficients used to balance R0. 2 The relative importance of RMSE in fitness calculation, and satisfying α+β=1; RMSE max This is the RMSE value of the initial model built on the training set using the full wavelength range, used to normalize the RMSE so that it matches R0. 2 They have similar units and ranges of values; When optimizing the initial SVM model using the training set, the impact of inertia weights on global and local search capabilities needs to be considered. The dynamic inertia weight adjustment formula is designed as follows: ; Where w represents the inertia weight of the current iteration, w start w end t and tmax are the initial and final inertia weights, respectively, and t and tmax are the current and maximum iteration counts, respectively. When optimizing the initial SVM model using the training set, it is also necessary to consider the escape mechanism when particles get stuck in local optima. The position update formula is designed as follows: ; Where, x i This represents the position of the particle, Δx is the step size, and rand is a random number.
2. The efficient and non-destructive method for detecting strawberry sugar content based on intelligent algorithms as described in claim 1, characterized in that, Obtaining sugar content reference values includes: ; in, T This indicates the sugar content reference value. H This indicates the scale reading of the refractometer. n Indicates the number of measurements.
3. The efficient and non-destructive method for detecting strawberry sugar content based on intelligent algorithms as described in claim 1, characterized in that, Wavelet denoising of the spectral data includes: ; Where cj(k) represents the approximation coefficient at scale j, dj(k) represents the detail coefficient at scale j, sj-1(m) represents the signal at scale j-1, and h(m) and g(m) are the coefficients of the low-pass and high-pass filters, respectively.
4. The efficient and non-destructive method for detecting strawberry sugar content based on intelligent algorithms as described in claim 1, characterized in that, Polynomial baseline correction of the spectral data includes: ; Where I corresponds to spectral intensity, λ represents wavelength, and a, b, and c are polynomial coefficients.
5. The efficient and non-destructive method for detecting strawberry sugar content based on intelligent algorithms as described in claim 1, characterized in that, Based on the key feature wavelengths, an initial SVM model is constructed using the RBF kernel function. Initial parameters are determined through cross-validation to establish a nonlinear mapping relationship between strawberry sugar content and feature wavelengths. Considering the influence of individual fitness on the crossover probability, an adaptive crossover probability formula is designed as follows: ; in, The crossover probability of individuals. , These are the maximum and minimum crossover probabilities, respectively. Indicates individual fitness. , These are the population average and maximum fitness, respectively.
6. The efficient and non-destructive method for detecting strawberry sugar content based on intelligent algorithms as described in claim 5, characterized in that, The influence of individual fitness on mutation probability needs to be considered when constructing the initial SVM model. The adaptive mutation probability formula is designed as follows: ; Among them, P m This represents the mutation probability of an individual, and k is a coefficient that controls the rate of change of the mutation probability.
Citation Information
Patent Citations
Fruit and vegetable sugar degree detection model construction and sugar degree detection method based on hyperspectral imaging
CN119274698A