Tobacco formula recommendation algorithm based on distance multi-model fusion
Through an algorithm based on distance multi-model fusion, combined with probability calculation and automatic decision-making system, the problem of low tobacco leaf formula recommendation efficiency in the existing technology is solved, more accurate and reliable tobacco leaf raw material recommendation is achieved, and the formula efficiency is improved.
Patent Information
- Application Number
- CN202410624561.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-05-20
- Publication Date
- 2024-09-06
AI Technical Summary
The existing technology lacks a simple, effective, and production-ready intelligent tobacco leaf formula recommendation method, which results in manual selection of alternative raw materials that is highly subjective and inefficient, and cannot effectively solve the problem of fluctuations in tobacco leaf raw material formulas.
An algorithm based on distance multi-model fusion is used to extract the characteristics of tobacco leaf raw materials through one-hot coding, and multiple single distance models are used to calculate the distance. Combined with probability calculation and the voting mechanism of the automatic decision-making system, alternative tobacco leaf raw materials are recommended to eliminate the limitations of the single distance model. sex.
It improves the accuracy and robustness of tobacco leaf formula recommendation, provides a reliable intelligent recommendation system, reduces manual intervention, and improves formula efficiency.
Smart Images

Figure SMS_3 
Figure SMS_6 
Figure SMS_1
Abstract
Description
Technical Field
[0001] The invention belongs to the technical field of tobacco leaf formula intelligent recommendation, and specifically relates to a tobacco formula recommendation algorithm based on distance multi-model fusion. Background Art
[0002] Tobacco leaf formula is the basis of cigarettes and the key to determining cigarette quality. Since the tobacco leaf raw material formula is directly connected to factory production and warehouse inventory, it is also the cigarette raw material that fluctuates most frequently. According to the sensory quality characteristics of the missing tobacco leaf raw materials and their role in cigarette specifications, finding suitable alternative raw materials is an important task for formulators and directly affects the quality of cigarettes. The disadvantages of manual screening of replacement raw materials are high subjectivity, limited efficiency, and high work repetitiveness. In other words, the prior art lacks a simple, effective, and production-ready intelligent tobacco leaf formula recommendation method. For this reason, the present invention is proposed. Summary of the invention
[0003] The algorithm based on multi-distance model fusion of the present invention is an intelligent recommendation algorithm that can replace artificial intelligence and is used to solve the limitation problem of the single distance model calculation method in the prior art. The algorithm of the present invention has the conditions for application in actual production and provides reference significance for related tobacco research.
[0004] The present invention provides the following technical solutions:
[0005] A tobacco recipe recommendation algorithm based on distance multi-model fusion includes the following steps:
[0006] (1) extracting the target tobacco leaf raw material features and the tobacco leaf raw material features to be replaced at the same level respectively, quantizing each tobacco leaf raw material feature dimension through one-hot encoding, and obtaining a feature vector of each feature;
[0007] (2) using multiple single distance models to respectively calculate the distance between the target tobacco leaf raw material and the tobacco leaf raw material to be replaced, and counting the tobacco leaf raw materials to be replaced to generate a set of recommended tobacco leaf raw materials; selecting the number of recommended tobacco leaf raw materials in ascending order of distance, and taking the key tobacco leaf raw material set of the single distance model;
[0008] (3) Using the probability calculation method, the voting mechanism in the automatic decision-making system is used to vote for the frequency of occurrence of elements in each key tobacco leaf raw material set, and the confidence level P is calculated;
[0009] (4) Sort the raw materials according to their P values from large to small, and select the tobacco leaf raw materials with the highest ranking as the final recommended tobacco leaf raw materials.
[0010] Preferably, the tobacco leaf raw material characteristics include five levels, namely: the first level is the primary origin of tobacco leaves, the second level is the secondary origin of tobacco leaves, the third level is the tobacco leaf variety, the fourth level is the tobacco leaf grade, and the fifth level is the tobacco leaf part.
[0011] Preferably, the first-level origin includes within the province, outside the province, and imported.
[0012] Preferably, the secondary origin includes Yunnan Province, outside Yunnan Province, and countries outside China; Yunnan Province includes Dehong area, Baoshan area, Chuxiong area, Dali area, Lijiang area, Honghe area, Yunnan mixed, Kunming area, Lincang area, Pu'er area, Qujing area, Wenshan area, Yuxi area, Zhaotong area, and any two or more of the above mixed; outside Yunnan Province includes Chongqing City, Henan Province, Guizhou Province, Sichuan Province, Liaoning Province, Jilin Province, Shaanxi Province, Anhui Province, Heilongjiang Province, Guangdong Province, Fujian Province, Xinjiang Uygur Autonomous Region, Guangxi Zhuang Autonomous Region, Hunan Province, Hubei Province, Shandong Province, Inner Mongolia Autonomous Region, Jiangxi Province, Zhejiang Province, Shanxi Province, and any two or more of the above mixed; countries outside China include Argentina, Brazil, France, Zimbabwe, Malawi, the United States, Turkey, Indonesia, Zambia and any two or more of the above mixed.
[0013] Preferably, the varieties include K326, Hongda, Yun 87, Yun 85, Yun 97, CB-1, NC102, Yunyan 105, Longjiang 911, Zhongyan 100, K series, N series, Yun series, Qinyan series, Yuyan series, Liaoyan series, and Jiyan series.
[0014] Preferably, the grades include superior, medium and inferior.
[0015] Preferably, the parts include upper part, upper middle part, middle C1F, middle C3F, middle part, lower middle part, and lower part.
[0016] Preferably, the multiple single distance models are five, namely: Mahalanobis distance, Euclidean distance, Manhattan distance, Minkowski distance and Chebyshev model.
[0017] Preferably, each single distance model calculates the distance between each material using a parallel computing method.
[0018] Preferably, the number of tobacco leaf raw materials recommended by each single distance model is the same and no more than 10.
[0019] Preferably, the confidence value P is calculated by the formula P=c / 5, where c is the frequency of occurrence of the tobacco raw material feature.
[0020] The beneficial effects of the present invention are:
[0021] The algorithm of the present invention combines multiple distance models instead of the traditional single distance model calculation method, eliminating the limitations of different distance calculation methods. The algorithm of the present invention also introduces probability statistics calculation to increase the accuracy of the model; at the same time, through the probability statistics of the recommended material frequency, the model has good robustness, which brings great reliability to the recommendation of tobacco raw materials for the formula. DETAILED DESCRIPTION
[0022] In order to make the purpose, technical scheme and advantages of the present invention clearer, the present invention is further described in detail below in conjunction with the embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not intended to limit the present invention. If no specific technology or conditions are specified in the embodiments, the technology or conditions described in the literature in the art or the product instructions are used.
[0023] A tobacco recipe recommendation algorithm based on distance multi-model fusion of the present invention comprises the following steps:
[0024] (1) Extract the target tobacco raw material A feature layer and the tobacco raw material B feature to be replaced at the same level respectively, quantify each tobacco raw material feature dimension through one-hot coding, and obtain the feature vector of each feature; the tobacco raw material features include five levels, namely: the first level of tobacco leaf production area, the second level of tobacco leaf production area, the third level of tobacco leaf variety, the fourth level of tobacco leaf grade, and the fifth level of tobacco leaf part; the first level of production area includes within the province, outside the province, and imported; the second level of production area includes within Yunnan Province, outside Yunnan Province, and countries outside China; Yunnan Province includes Dehong area, Baoshan area, Chuxiong area, Dali area, Lijiang area, Honghe area, Yunnan mixed, Kunming area, Lincang area, Pu'er area, Qujing area, Wenshan area, Yuxi area, Zhaotong area, and any two or more of the above mixed; outside Yunnan Province includes Chongqing City, Henan Province, Guizhou Province, Yunnan ... Zhejiang Province, Sichuan Province, Liaoning Province, Jilin Province, Shaanxi Province, Anhui Province, Heilongjiang Province, Guangdong Province, Fujian Province, Xinjiang Uygur Autonomous Region, Guangxi Zhuang Autonomous Region, Hunan Province, Hubei Province, Shandong Province, Inner Mongolia Autonomous Region, Jiangxi Province, Zhejiang Province, Shanxi Province, and any two or more of the above-mentioned mixed; countries outside China include Argentina, Brazil, France, Zimbabwe, Malawi, the United States, Turkey, Indonesia, Zambia, and any two or more of the above-mentioned mixed; varieties include K326, Hongda, Yun87, Yun85, Yun97, CB-1, NC102, Yunyan 105, Longjiang 911, Zhongyan 100, K series, N series, Yun series, Qinyan series, Yuyan series, Liaoyan series, Jiyan series; grades include superior, medium, and inferior; parts include upper, upper middle, middle C1F, middle C3F, middle, middle lower, and lower;
[0025] The one-hot encoding quantization method is shown below as an example, where the column is its feature vector;
[0026]
[0027]
[0028]
[0029] (2) using multiple single distance models to calculate the distance between the target tobacco raw material and the tobacco raw material to be replaced, and counting the tobacco raw materials to be replaced to generate a set of recommended tobacco raw materials; selecting the number of recommended tobacco raw materials according to the distance from small to large, and taking the key tobacco raw material set of the single distance model; the multiple single distance models are five, namely: Mahalanobis distance, Euclidean distance, Manhattan distance, Minkowski distance and Chebyshev model; each single distance model uses a parallel calculation method to calculate the distance between each material; each single distance model recommends the same number of recommended tobacco raw materials, and is not more than 10;
[0030] (3) Using the probability calculation method, the voting mechanism in the automatic decision-making system is used to vote for the frequency of occurrence of elements in each key tobacco leaf raw material set, and the confidence P is calculated; the confidence P value is calculated by the formula P = c / 5, where c is the frequency of occurrence of the tobacco leaf raw material feature;
[0031] (4) Sort the raw materials according to their P values from large to small, and select the tobacco leaf raw materials with the highest ranking as the final recommended tobacco leaf raw materials.
[0032] Embodiment 1: Given a target tobacco raw material A (within the province / Yunnan Province / Kunming area / Red Large / Middle / Superior) and four types of tobacco raw materials to be replaced in the set B (within the province / Yunnan Province / Kunming area / K326 / Middle C3F / Superior, outside the province / outside Yunnan Province / Chongqing / Yun 87 / Middle / Superior, within the province / Yunnan Province / Kunming area / Red Large / Upper / Superior, within the province / Yunnan Province / Kunming area / Red Large / Upper / Middle), this embodiment calculates the raw material of the tobacco raw material A that is most likely to be replaced in the set B of tobacco raw materials to be replaced, and the tobacco formula recommendation algorithm based on distance multi-model fusion is performed according to the above steps:
[0033] (1) Extract the target tobacco leaf raw material A feature layer and the tobacco leaf raw material B feature to be replaced at five levels, as shown in Table 1:
[0034]
[0035] The material features are quantified by one-hot encoding to obtain the feature vector of each tobacco leaf raw material, as shown in Table 2:
[0036]
[0037]
[0038]
[0039] (2) Calculate five distances between tobacco leaf raw material A and four types of tobacco leaf raw materials to be replaced in the set of four types of tobacco leaf raw materials B. The results are shown in Table 3 below:
[0040] Distance Model B1 B2 B3 B4 Mahalanobis distance 0.4256 0.6385 0.2128 0.2128 Euclidean distance 2.0000 2.4495 1.4142 1.4142 Minkowski distance 2.0000 2.4495 1.4142 1.4142 Manhattan distance 4.0000 6.0000 2.0000 2.0000 Chebyshev distance model 1.0000 1.0000 1.0000 1.0000
[0041] The number of tobacco leaf raw materials recommended by the single distance model is set to 2, and the recommended tobacco leaf raw material set is as shown in Table 4:
[0042] Distance Model B1 B2 B3 B4 Mahalanobis distance √ √ Euclidean distance √ √ Minkowski distance √ √ Manhattan distance √ √ Chebyshev distance model √ √ √ √
[0043] (3) Using the probability calculation method, the voting mechanism in the automatic decision-making system is used to vote for the frequency of occurrence of elements in each set of key tobacco leaf raw materials, and the confidence P is calculated; the confidence P value is calculated using the formula P = c / 5, where c is the frequency of occurrence of the tobacco leaf raw material feature. The recommended frequencies of the raw materials B1-B4 to be replaced are 1, 1, 5, and 5, respectively, and the calculated confidence P values are 0.2, 0.2, 1, and 1, respectively;
[0044] (4) From the results, it can be seen that according to the P value from large to small, the probability of B3 and B4 tobacco leaf raw materials replacing tobacco leaf raw materials A is the highest, and they are the final recommended tobacco leaf raw materials.
[0045] The above preferred embodiments are only used to illustrate the technical solution of the invention rather than to limit the present invention. Although the present invention has been described in detail through the above preferred embodiments, those skilled in the art should understand that various changes can be made in form and details without departing from the protection scope of the present invention.
Claims
1. A tobacco recipe recommendation algorithm based on distance multi-model fusion, characterized in that: The following steps are involved: (1) extracting the target tobacco leaf raw material features and the tobacco leaf raw material features to be replaced at the same level respectively, quantizing each tobacco leaf raw material feature dimension through one-hot encoding, and obtaining a feature vector of each feature; (2) using multiple single distance models to respectively calculate the distance between the target tobacco leaf raw material and the tobacco leaf raw material to be replaced, and counting the tobacco leaf raw materials to be replaced to generate a set of recommended tobacco leaf raw materials; selecting the number of recommended tobacco leaf raw materials in ascending order of distance, and taking the key tobacco leaf raw material set of the single distance model; (3) Using the probability calculation method, the voting mechanism in the automatic decision-making system is used to vote for the frequency of occurrence of elements in each key tobacco leaf raw material set, and the confidence level P is calculated; (4) Sort the raw materials according to their P values from large to small, and select the tobacco leaf raw materials with the highest ranking as the final recommended tobacco leaf raw materials.
2. The algorithm according to claim 1, characterized in that The characteristics of tobacco leaf raw materials include five levels, namely: the first level of tobacco leaf origin, the second level of tobacco leaf origin, the third level of tobacco leaf variety, the fourth level of tobacco leaf grade, and the fifth level of tobacco leaf part.
3. The algorithm according to claim 2, characterized in that First-level origins include within the province, outside the province, and imported.
4. The algorithm according to claim 2, characterized in that Secondary origins include Yunnan Province, outside Yunnan Province, and countries outside China; Yunnan Province includes Dehong area, Baoshan area, Chuxiong area, Dali area, Lijiang area, Honghe area, Yunnan mixed, Kunming area, Lincang area, Pu'er area, Qujing area, Wenshan area, Yuxi area, Zhaotong area, and any two or more of the above; outside Yunnan Province includes Chongqing City, Henan Province, Guizhou Province, Sichuan Province, Liaoning Province, Jilin Province, Shaanxi Province, Anhui Province, Heilongjiang Province, Guangdong Province, Fujian Province, Xinjiang Uygur Autonomous Region, Guangxi Zhuang Autonomous Region, Hunan Province, Hubei Province, Shandong Province, Inner Mongolia Autonomous Region, Jiangxi Province, Zhejiang Province, Shanxi Province, and any two or more of the above; countries outside China include Argentina, Brazil, France, Zimbabwe, Malawi, the United States, Turkey, Indonesia, Zambia, and any two or more of the above.
5. The algorithm according to claim 2, characterized in that Varieties include K326, Hongda, Yun 87, Yun 85, Yun 97, CB-1, NC102, Yunyan 105, Longjiang 911, Zhongyan 100, K series, N series, Yun series, Qinyan series, Yuyan series, Liaoyan series, and Jiyan series.
6. The algorithm according to claim 2, characterized in that The grades include upper, middle and lower.
7. The algorithm according to claim 2, characterized in that The locations include upper, upper middle, middle C1F, middle C3F, middle, lower middle, and lower.
8. The algorithm according to claim 1, characterized in that There are five single distance models, namely: Mahalanobis distance, Euclidean distance, Manhattan distance, Minkowski distance and Chebyshev model.
9. The algorithm according to claim 1, characterized in that Each single distance model uses parallel computing to calculate the distance between each material; each single distance model recommends the same number of tobacco leaf raw materials, which is no more than 10.
10. The algorithm according to claim 1, characterized in that The confidence value P is calculated by the formula P=c / 5, where c is the frequency of occurrence of the tobacco raw material feature.
Citation Information
Patent Citations
Large-scale face identification method based on GPU accelerated retrieval
CN107577990A
Machine click detection method and device and readable storage medium
CN110210507A
Positioning method based on scene matching and machine learning in urban canyon environment
CN112666588A
Method for rapidly and qualitatively discriminating complete tobacco leaves based on near infrared spectrum
CN114689542A
Batch type active learning method based on multiple candidate sets
CN116049718A
Cited By
Method and system for assisting material synthesis by using multi-mode large model and storage medium
CN119626418A
