Quality characteristic contribution analysis method and system in white spirit quality evaluation
Through neural network model and SHAP value theory, the contribution of liquor quality characteristics to quality evaluation data is evaluated, and the subjectivity and inaccuracy of liquor quality evaluation results in the existing technology is solved, and more accurate and objective quality evaluation is achieved.
Patent Information
- Application Number
- CN202510365704.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-26
- Publication Date
- 2025-06-27
AI Technical Summary
It is difficult for the prior art to accurately judge the contribution of liquor quality characteristics to quality evaluation data, resulting in the subjectivity and inaccuracy of liquor quality evaluation results.
A neural network model is used to combine SHAP value theory, and a liquor quality evaluation model is established by obtaining the quality characteristic data and quality evaluation data of different liquor samples, and the contribution of each quality characteristic data is evaluated through SHAP value calculation.
Accurate quantitative analysis of the contribution of the quality characteristics of liquor to the quality evaluation data is achieved, which reduces the subjectivity of the evaluation results and improves the objectivity and accuracy of the evaluation results.
Smart Images

Figure CN120218744A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of liquor quality management, and particularly to a method and system for analyzing the contribution of quality characteristics in liquor quality evaluation. Background Art
[0002] The quality of liquor directly affects consumers' acceptance and market competitiveness. The quality evaluation of liquor usually relies on professional liquor tasters to score through sensory evaluation, which largely depends on the personal senses and experience of the tasters and has strong subjectivity. In addition, the physical state of the tasters may also affect the evaluation results, resulting in low accuracy and difficulty in accurately and objectively reflecting the contribution of liquor quality characteristics to the evaluation results. Therefore, there is an urgent need for a scientific method to quantitatively analyze the contribution of liquor quality characteristics by combining modern data analysis and modeling techniques.
[0003] Existing research pays more attention to the overall prediction of liquor quality and lacks in-depth analysis of the contribution of specific quality characteristics. In addition, existing research usually ignores the differential effects of quality characteristics on quality evaluation data (such as color, aroma, taste, or style), making it difficult to provide targeted guidance for the optimization of liquor quality. Summary of the Invention
[0004] The technical problem to be solved by the present invention: The present invention provides a method and system for analyzing the contribution of quality characteristics in liquor quality evaluation, which solves the problem that the prior art cannot accurately judge the contribution degree of liquor quality characteristics to quality evaluation data.
[0005] The technical solution adopted by the present invention to solve the above technical problem: A method for analyzing the contribution of quality characteristics in liquor quality evaluation includes the following steps:
[0006] S1. Obtain the quality characteristic data and quality evaluation data of different liquor samples, construct a data set, and divide the data set into a training set, a validation set, and a test set;
[0007] S2. Establish a neural network model, use the quality characteristic data in the training set as input, use the quality evaluation data in the training set as output, train the neural network model, and use the validation set to verify the trained neural network model to obtain a liquor quality evaluation model;
[0008] S3. Use the test set to test the liquor quality evaluation model, and calculate the SHAP value of each quality characteristic data in the test set based on the SHAP theory;
[0009] S4. Evaluate the contribution degree of each quality characteristic data according to the calculated SHAP value.
[0010] Further, the method for analyzing the contribution of quality characteristics in liquor quality evaluation further includes comparing the contribution degrees of the same quality characteristic data in different liquor samples to obtain the positive and negative effects of each quality characteristic data.
[0011] Further, the quality characteristic data includes the contents of the physical and chemical indexes of total esters, total acids, fusel oil, solids, turbidity, alcohol content, ethyl acetate, ethyl lactate, ethyl butyrate, ethyl hexanoate, acetic acid, butyric acid, hexanoic acid, methanol, n-propanol, n-butanol, isobutanol, n-pentanol, isopentanol, ethyl palmitate, ethyl oleate, and ethyl linoleate.
[0012] Further, the turbidity in the quality characteristic data is collected in NTU units; the alcohol content in the quality characteristic data is collected as a percentage of alcohol content; the contents of the remaining compounds in the quality characteristic data are collected in the form of concentration.
[0013] Further, the quality evaluation data includes one of the scores of color, aroma, taste, and style.
[0014] Further, the neural network model includes one or a combination of more than one of MLP, LSTM, RNN, CNN, GRU, and Transformer.
[0015] Further, the calculation formula of the SHAP value is: where, φ j is the SHAP value of the j-th quality characteristic data; N is the set of all quality characteristic data; N\{j} is all subsets that do not include the j-th quality characteristic data, S is a subset in N\{j}; v(S) is the output value of the liquor quality evaluation model when only the subset S is included, and v(S∪{j}) - v(S) represents the change in the output value of the liquor quality evaluation model brought about by adding the j-th quality characteristic data; |S| is the size of the subset S; |N| is the total number of quality characteristic data.
[0016] Further, the liquor quality evaluation model adopts the SmoothL1 loss function, and the expression of the SmoothL1 loss function is: where, x is the predicted value of the liquor quality evaluation model, y is the true value of the quality evaluation data, β is the smoothing threshold, and SmoothL1(x, y) is the loss function value.
[0017] Further, before training, it also includes preprocessing the data of the fermentation stage and the corresponding microbial abundance data. The preprocessing includes missing value processing, outlier processing, and normalization processing. During the training process, if the loss function value of the liquor quality evaluation model is less than the preset loss function threshold, or the coefficient of determination of the liquor quality evaluation model is greater than the preset coefficient of determination threshold, then the training of the liquor quality evaluation model is completed. After obtaining the normalized quality evaluation data using the liquor quality evaluation model, the inverse process corresponding to the normalization is adopted to restore the quality evaluation data to the real order of magnitude.
[0018] The present invention also provides a system for analyzing the contribution of quality characteristics in liquor quality evaluation, which implements the method for analyzing the contribution of quality characteristics in liquor quality evaluation as described above. The system includes a data acquisition module, a model training module, a model verification module, a model testing module, and a quality characteristic contribution module. The data acquisition module is used to acquire the quality characteristic data and quality evaluation data of different liquor samples, construct a data set, and divide the data set into a training set, a verification set, and a test set. The model training module is used to establish a neural network model, take the quality characteristic data in the training set as the input, and take the quality evaluation data in the training set as the output to train the neural network model. The model verification module is used to verify the trained neural network model using the verification set to obtain a liquor quality evaluation model. The model testing module is used to test the liquor quality evaluation model using the test set. The quality characteristic contribution module is used to calculate the SHAP value of each quality characteristic data in the test set based on the SHAP theory, and evaluate the contribution degree of each quality characteristic data according to the calculated SHAP value.
[0019] The beneficial effects of the present invention: The present invention provides a method and a system for analyzing the contribution of quality characteristics in liquor quality evaluation. By acquiring the quality characteristic data and quality evaluation data of different liquor samples, constructing a data set, and dividing the data set into a training set, a verification set, and a test set, establishing a neural network model, taking the quality characteristic data in the training set as the input, and taking the quality evaluation data in the training set as the output to train the neural network model, and using the verification set to verify the trained neural network model to obtain a liquor quality evaluation model, using the test set to test the liquor quality evaluation model, calculating the SHAP value of each quality characteristic data in the test set based on the SHAP theory, and evaluating the contribution degree of each quality characteristic data according to the calculated SHAP value, it solves the problem that the prior art cannot accurately judge the contribution degree of liquor quality characteristics to the quality evaluation data. Description of the Drawings
[0020] Figure 1 It is a flowchart of a method for analyzing the contribution of quality characteristics in liquor quality evaluation provided by the present invention. Detailed Embodiments
[0021] In view of the problem that the prior art cannot accurately determine the contribution degree of the quality characteristics of Baijiu to the quality evaluation data, the present invention provides a method for analyzing the contribution of quality characteristics in the quality evaluation of Baijiu. As Figure 1 shown, it includes the following steps:
[0022] S1. Obtain the quality characteristic data and quality evaluation data of different Baijiu samples, construct a data set, and divide the data set into a training set, a validation set, and a test set;
[0023] Specifically, the quality characteristic data includes the contents of physical and chemical indexes of total esters, total acids, fusel oil, solids, turbidity, alcohol content, ethyl acetate, ethyl lactate, ethyl butyrate, ethyl hexanoate, acetic acid, butyric acid, hexanoic acid, methanol, n-propanol, n-butanol, isobutanol, n-pentanol, isopentanol, ethyl palmitate, ethyl oleate, and ethyl linoleate. The turbidity in the quality characteristic data is collected in NTU units; the alcohol content in the quality characteristic data is collected as a percentage of alcohol content; the contents of the remaining compounds in the quality characteristic data are collected in the form of concentration. The quality evaluation data includes one of the scores of color, aroma, taste, and style. The scores of color, aroma, taste, and style are averaged or weighted after being scored by several experts or wine tasters in the field. For example, using a 10-point system, that is, 0 points is considered the worst and 10 points is the best. The final scores of color, aroma, taste, and style are obtained by averaging the scores of 10 experts in the field.
[0024] S2. Establish a neural network model, use the quality characteristic data in the training set as the input, and use the quality evaluation data in the training set as the output, train the neural network model, and use the validation set to verify the trained neural network model to obtain a Baijiu quality evaluation model;
[0025] Specifically, the neural network model includes one or a combination of MLP, LSTM, RNN, CNN, GRU, and Transformer. The Baijiu quality evaluation model uses the SmoothL1 loss function, and the expression of the SmoothL1 loss function is: where x is the predicted value of the Baijiu quality evaluation model, y is the true value of the quality evaluation data, β is the smoothing threshold, and SmoothL1(x, y) is the loss function value. Before training, it also includes preprocessing the data in the fermentation stage and the corresponding microbial abundance data. The preprocessing includes missing value processing, outlier processing, and normalization processing. During the training process, if the loss function value of the Baijiu quality evaluation model is less than the preset loss function threshold, or the determination coefficient of the Baijiu quality evaluation model is greater than the preset determination coefficient threshold, then the training of the Baijiu quality evaluation model is completed.
[0026] S3. Use the test set to test the liquor quality evaluation model, and calculate the SHAP values of each quality characteristic data in the test set based on the SHAP theory;
[0027] Specifically, the calculation formula of the SHAP value is: Among them, φ j is the SHAP value of the j-th quality characteristic data; N is the set of all quality characteristic data; N\{j} is all subsets excluding the j-th quality characteristic data, S is a subset in N\{j}; v(S) is the output value of the liquor quality evaluation model when only subset S is included, and v(S∪{j}) - v(S) represents the change in the output value of the liquor quality evaluation model brought about by adding the j-th quality characteristic data; |S| is the size of subset S; |N| is the total number of quality characteristic data.
[0028] S4. Evaluate the contribution degree of each quality characteristic data according to the calculated SHAP values.
[0029] Specifically, the higher the SHAP value, the higher the contribution degree of the quality characteristic data.
[0030] Furthermore, the quality characteristic contribution analysis method in the liquor quality evaluation further includes comparing the contribution degrees of the same quality characteristic data in different liquor samples to obtain the positive and negative effects of each quality characteristic data.
[0031] Specifically, taking the score of taste in the quality evaluation data as an example, by comparing the contribution degrees of the same quality characteristic data in different liquor samples, the positive and negative effects of each quality characteristic data on the score of taste are obtained. For example, if the contribution degree of A in the quality characteristic data increases as the content of A increases, then A has a positive effect on the score of taste; if the contribution degree of B in the quality characteristic data decreases as the content of B increases, then B has a negative effect on the score of taste, providing a scientific basis for improving the quality of liquor.
[0032] The present invention also provides a system for analyzing the contribution of quality characteristics in the evaluation of Chinese liquor quality, which implements the method for analyzing the contribution of quality characteristics in the evaluation of Chinese liquor quality as described above. The system includes a data acquisition module, a model training module, a model verification module, a model testing module, and a quality characteristic contribution module. The data acquisition module is used to obtain the quality characteristic data and quality evaluation data of different Chinese liquor samples, construct a data set, and divide the data set into a training set, a verification set, and a test set. The model training module is used to establish a neural network model, take the quality characteristic data in the training set as input, and take the quality evaluation data in the training set as output to train the neural network model. The model verification module is used to verify the trained neural network model with the verification set to obtain a Chinese liquor quality evaluation model. The model testing module is used to test the Chinese liquor quality evaluation model with the test set. The quality characteristic contribution module is used to calculate the SHAP value of each quality characteristic data in the test set based on the SHAP theory, and evaluate the contribution degree of each quality characteristic data according to the calculated SHAP value.
[0033] Specifically, in the present invention, one Chinese liquor quality evaluation model corresponds to one quality characteristic evaluation. For example, the first Chinese liquor quality evaluation model is used to predict the score of color, the second Chinese liquor quality evaluation model is used to predict the score of aroma, the third Chinese liquor quality evaluation model is used to predict the score of taste, and the fourth Chinese liquor quality evaluation model is used to predict the score of style, so as to complete the evaluation of the contribution degree of quality characteristic data to the scores of color, aroma, taste, and style.
Claims
1. A method for analyzing the contribution of quality characteristics in liquor quality evaluation, characterized in that: The following steps are involved: S1. Obtain quality characteristic data and quality evaluation data of different liquor samples, construct a data set, and divide the data set into a training set, a validation set, and a test set; S2. Establish a neural network model, use the quality feature data in the training set as input, use the quality evaluation data in the training set as output, train the neural network model, and use the validation set to validate the trained neural network model to obtain a liquor quality evaluation model; S3, using the test set to test the liquor quality evaluation model, and calculating the SHAP value of each quality characteristic data in the test set based on the SHAP theory; S4. Evaluate the contribution of each quality characteristic data based on the calculated SHAP value.
2. The method for identifying key microorganisms in the Daqu fermentation stage according to claim 1, characterized in that: It also includes comparing the contribution of the same quality characteristic data in different liquor samples to obtain the positive and negative effects of each quality characteristic data.
3. The method for identifying key microorganisms in the Daqu fermentation stage according to claim 1, characterized in that: The quality characteristic data include the contents of physical and chemical indicators of total esters, total acids, fusel oil, solids, turbidity, alcohol content, ethyl acetate, ethyl lactate, ethyl butyrate, ethyl caproate, acetic acid, butyric acid, caproic acid, methanol, n-propanol, n-butanol, isobutanol, n-pentanol, isopentanol, ethyl palmitate, ethyl oleate and ethyl linoleate.
4. The method for analyzing the contribution of quality characteristics in liquor quality evaluation according to claim 1, characterized in that: The turbidity in the quality characteristic data is collected in NTU units; the alcohol content in the quality characteristic data is collected in alcohol percentage; the content of other compounds in the quality characteristic data is collected in the form of concentration.
5. The method for analyzing the contribution of quality characteristics in liquor quality evaluation according to claim 1, characterized in that: The quality evaluation data includes one of a color score, an aroma score, a taste score, and a price score.
6. The method for analyzing the contribution of quality characteristics in liquor quality evaluation according to claim 1, characterized in that: The neural network model includes one or more combinations of MLP, LSTM, RNN, CNN, GRU and Transformer.
7. The method for analyzing the contribution of quality characteristics in liquor quality evaluation according to claim 1, characterized in that: The calculation formula of SHAP value is: Among them, φ j is the SHAP value of the j-th quality characteristic data; N is the set of all quality characteristic data; N\{j} is all subsets that do not contain the j-th quality characteristic data, S is a subset in N\{j}; v(S) is the output value of the liquor quality evaluation model when it only contains subset S, v(S∪{j})-v(S) represents the change in the output value of the liquor quality evaluation model after adding the j-th quality characteristic data; |S| is the size of subset S; |N| is the total number of quality characteristic data.
8. The method for analyzing the contribution of quality characteristics in liquor quality evaluation according to claim 1, characterized in that: The liquor quality evaluation model uses the SmoothL1 loss function, and the expression of the SmoothL1 loss function is: Among them, x is the predicted value of the liquor quality evaluation model, y is the true value of the quality evaluation data, β is the smoothing threshold, and SmoothL1(x,y) is the loss function value.
9. The method for analyzing the contribution of quality characteristics in liquor quality evaluation according to claim 1, characterized in that: Before training, the fermentation stage data and the corresponding microbial abundance data are also preprocessed, and the preprocessing includes missing value processing, outlier processing and normalization processing. During the training process, if the loss function value of the liquor quality evaluation model is less than the preset loss function threshold, or the determination coefficient of the liquor quality evaluation model is greater than the preset determination coefficient threshold, then the liquor quality evaluation model training is completed. After using the liquor quality evaluation model to obtain the normalized quality evaluation data, the inverse processing corresponding to the normalization is used to restore the quality evaluation data to the true order of magnitude.
10. The quality characteristic contribution analysis system in liquor quality evaluation is characterized by: To implement the quality feature contribution analysis method in liquor quality evaluation as described in claim 1, the system includes a data acquisition module, a model training module, a model verification module, a model testing module and a quality feature contribution module; the data acquisition module is used to acquire the quality feature data and quality evaluation data of different liquor samples, construct a data set, and divide the data set into a training set, a verification set and a test set; the model training module is used to establish a neural network model, take the quality feature data in the training set as input, take the quality evaluation data in the training set as output, and train the neural network model; the model verification module is used to verify the trained neural network model with the verification set to obtain the liquor quality evaluation model; the model testing module is used to test the liquor quality evaluation model with the test set; the quality feature contribution module is used to calculate the SHAP value of each quality feature data in the test set based on the SHAP theory, and evaluate the contribution of each quality feature data according to the calculated SHAP value.