An image feature-based traditional Chinese medicine powder identification method
Patent Information
- Application Number
- CN202410973229.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-19
- Publication Date
- 2026-10-27
- Estimated Expiration
- 2044-07-19
AI Technical Summary
目前常用的中药鉴定手段有很多种,如宏观性状辨别法、微观显微鉴定法、色谱法等,另外还有一些特殊的方法,包括水试法、火试法、荧光法等;但是上述方法实施普遍复杂,操作不易,即实际检测工作效率不高
[0029](1)本发明所设计一种基于图像特征的中药粉末识别方法,基于VPS数字显微图像方式,为中药粉末提供高精度图像采集,并引入分类网络机器学习,在以样本对目标分类网络进行训练的过程中,考虑各基础特征彼此间的相关性,构建各个特征分组,并基于各特征分组中各基础特征复杂度下的排序,顺序筛选各基础特征的输入组合,执行目标分类网络训练,再以提高识别准确率、减少输入特征维度为衡量因素,筛选最优训练后分类网络,即获得中药粉末识别模型;在实际应用下,基于VPS数字显微图像,应用中药粉末识别模型,高效实现关于待识别中药粉末的识别。
Smart Images

Figure CN118968508B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to a method for identifying traditional Chinese medicine powder based on image features, belonging to the field of powder image recognition technology. Background Technology
[0002] Traditional Chinese medicine (TCM), as an important component of traditional Chinese medicine culture, boasts a long history and widespread application. Its use is very common in my country, playing a vital role in safeguarding the health of the Chinese people. However, driven by profit, many unscrupulous merchants have introduced counterfeit and adulterated TCM products into the market, significantly impacting their efficacy and safety. Therefore, the identification of genuine and high-quality TCM is crucial for protecting public health. Currently, there are many commonly used methods for TCM identification, such as macroscopic identification, microscopic identification, and chromatography. There are also some special methods, including water testing, fire testing, and fluorescence methods; however, these methods are generally complex to implement and difficult to operate, resulting in low efficiency in actual testing.
[0003] In clinical applications, certain Chinese medicinal materials are often crushed into powder. After being ground into powder, the medicinal materials lose their external characteristics and cannot be identified and judged by their macroscopic properties. Therefore, a microscope is used to observe their microscopic structural characteristics in order to determine the authenticity and quality of the medicinal powder. However, the existing microscopic observation methods are not very accurate overall. Summary of the Invention
[0004] The technical problem to be solved by this invention is to provide a method for identifying Chinese medicine powder based on image features. It adopts a brand-new design logic, continuously optimizes feature selection, improves the accuracy of classification network machine learning, and thus improves the accuracy and efficiency of Chinese medicine powder identification.
[0005] To solve the above-mentioned technical problems, the present invention adopts the following technical solution: The present invention designs a method for identifying traditional Chinese medicine powder based on image features. For a sample group including at least one known category of traditional Chinese medicine sample powder, the following steps A to B are performed to obtain a corresponding traditional Chinese medicine powder identification model; then, the traditional Chinese medicine powder identification model is applied to perform the following step I to identify the traditional Chinese medicine powder to be identified.
[0006] Step A. Based on the VPS digital micrographs corresponding to the powder samples of Chinese medicine of each known category in the sample group, obtain the preset number of feature values corresponding to each preset basic feature of the powder samples of Chinese medicine of each known category, and then proceed to Step B;
[0007] Step B. Based on the correlation between the basic features, and using the known categories of Chinese medicine powder samples as input and the known categories of Chinese medicine powder samples as output, train the target classification network according to the sample group, obtain the optimal training classification network and the corresponding optimal features, that is, obtain the Chinese medicine powder recognition model corresponding to the sample group.
[0008] Step I. Based on the VPS digital microscopic image corresponding to the Chinese medicine powder to be identified, obtain the feature values of each optimal feature corresponding to the Chinese medicine powder to be identified, and execute the Chinese medicine powder identification model to realize the identification of the Chinese medicine powder to be identified with respect to the known categories of Chinese medicine sample powders in the sample group.
[0009] As a preferred embodiment of the present invention, step B includes the following steps B1 to B2:
[0010] Step B1. Based on the feature values of the preset number of each basic feature corresponding to each known category of Chinese medicine sample powder, obtain the correlation between all pairs of basic features in each group, and divide all basic features in a way that groups the two basic features corresponding to the correlation greater than the preset correlation threshold, obtain each feature group, and then proceed to step B2.
[0011] Step B2. Based on the basic feature combinations in each feature group, and taking the known category of Chinese medicine sample powder as input and the known category of Chinese medicine sample powder as output, train the target classification network according to the sample group, and measure the recognition accuracy of the trained classification network and the basic feature combination corresponding to the trained classification network to obtain the optimal trained classification network and the corresponding optimal features, that is, obtain the Chinese medicine powder recognition model corresponding to the sample group.
[0012] As a preferred embodiment of the present invention, step B2 includes the following steps B2-1 to B2-7:
[0013] Step B2-1. For each feature group, take each basic feature in the feature group as a node, and connect the two basic features corresponding to the correlation greater than the preset correlation threshold with an edge to construct an undirected graph corresponding to the feature group. Then, according to the degree of each node in the undirected graph, sort the nodes in the undirected graph in descending order of degree to obtain the sorting of each basic feature in the feature group. Then proceed to step B2-2.
[0014] Step B2-2. Initialize i = 1, randomly select a feature group that has not participated in the processing of steps B2-2 to B2-5 as the current iteration feature group, and proceed to step B2-3;
[0015] Step B2-3. Select the i-th basic feature in the current iteration feature group and add it to the feature group to be analyzed under the current iteration feature group. Then, based on the sample group, take the feature values of each basic feature in the feature group to be analyzed under the current iteration feature group corresponding to the known category of Chinese medicine sample powder as input and the known category of Chinese medicine sample powder as output. Train the original target classification network to obtain the trained classification network and the recognition accuracy corresponding to the trained classification network. Then proceed to step B2-4.
[0016] Step B2-4. Determine if i is equal to the number of basic features in the current iterative feature group. If yes, proceed to step B2-5; otherwise, increment the value of i by 1 and return to step B2-3.
[0017] Step B2-5. For the recognition accuracy of each trained classification network obtained under the current iterative feature group, determine whether there are other recognition accuracies within the preset fluctuation range of the maximum recognition accuracy. If so, for the training classification networks corresponding to the maximum recognition accuracy and each of the other recognition accuracies, obtain the training classification network with the minimum number of features to be analyzed, and use it as the intermediate training classification network under the current iterative feature group, and then proceed to step B2-6; otherwise, select the training classification network corresponding to the maximum recognition accuracy as the intermediate training classification network under the current iterative feature group, and then proceed to step B2-6.
[0018] Step B2-6. Determine if there are any feature groups that were not processed in steps B2-2 to B2-5. If yes, return to step B2-2; otherwise, proceed to step B2-7.
[0019] Step B2-7. Based on the intermediate-level training classification network under each feature group, obtain the optimal training classification network and the corresponding optimal features, that is, obtain the Chinese medicine powder recognition model corresponding to the sample group.
[0020] As a preferred embodiment of the present invention, step B2-7 includes the following steps B2-7-1 to B2-7-2;
[0021] Step B2-7-1. For each feature group, determine whether there are other recognition accuracies within the preset fluctuation range of the maximum recognition accuracy. If so, select the maximum recognition accuracy and the intermediate training classification network corresponding to each of the other recognition accuracies as the training network to be analyzed, and proceed to step B2-7-2.
[0022] Otherwise, select the intermediate post-training classification network corresponding to the maximum recognition accuracy as the optimal post-training classification network, and take each feature to be analyzed as the optimal feature corresponding to the optimal post-training classification network, thus obtaining the Chinese medicine powder recognition model corresponding to the sample group.
[0023] Step B2-7-2. For each network to be analyzed after training, determine whether the number of networks to be analyzed after training with the minimum number of features to be analyzed is greater than 1. If so, for each network to be analyzed after training, obtain the sum of the degrees of each feature to be analyzed in its respective feature group, which constitutes the feature complexity of the network to be analyzed. Then, select the network to be analyzed after training with the minimum feature complexity as the optimal training classification network, and the corresponding features to be analyzed as the optimal features of the optimal training classification network, thus obtaining the Chinese medicine powder recognition model corresponding to the sample group.
[0024] If the number of trained networks corresponding to the minimum number of features to be analyzed is equal to 1, then the trained network to be analyzed is selected as the optimal trained classification network, and each feature to be analyzed is selected as the optimal feature corresponding to the optimal trained classification network, thus obtaining the Chinese medicine powder recognition model corresponding to the sample group.
[0025] As a preferred technical solution of the present invention, the iteration in the training process of the target classification network aims to continuously increase the recognition accuracy and make it fluctuate within a certain data range.
[0026] Corresponding to the above, the present invention also provides a computer device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the steps of the above method.
[0027] Accordingly, the present invention also provides a computer-readable storage medium storing a computer program thereon, which, when executed by a processor, implements the steps of the above-described method.
[0028] The method for identifying traditional Chinese medicine powder based on image features described in this invention has the following technical advantages compared with existing technologies:
[0029] (1) The present invention designs a method for identifying Chinese medicine powder based on image features. Based on VPS digital microscopy, it provides high-precision image acquisition for Chinese medicine powder and introduces classification network machine learning. In the process of training the target classification network with samples, the correlation between each basic feature is considered, each feature group is constructed, and the input combination of each basic feature is sequentially selected based on the ranking of the complexity of each basic feature in each feature group. The target classification network is trained, and the optimal training classification network is selected by taking the improvement of recognition accuracy and the reduction of input feature dimensionality as the evaluation factors, thus obtaining the Chinese medicine powder identification model. In practical applications, based on VPS digital microscopy, the Chinese medicine powder identification model is applied to efficiently realize the identification of the Chinese medicine powder to be identified. Attached Figure Description
[0030] Figure 1 This is a flowchart illustrating the image feature-based method for identifying traditional Chinese medicine powders designed in this invention.
[0031] Figure 2 This is a diagram illustrating the effect of sample identification in the application of the design embodiment of the present invention;
[0032] Figure 3 This is a diagram showing the effect of identifying cattail pollen samples under the application of the design embodiment of the present invention;
[0033] Figure 4 This is a diagram illustrating the effect of yam sample identification in an application of the design embodiment of the present invention;
[0034] Figure 5 This is a diagram showing the effect of puffball sample recognition in the application of the design embodiment of the present invention;
[0035] Figure 6 This is a diagram showing the effect of Poria cocos sample identification under the application of the design embodiment of the present invention;
[0036] Figure 7 This is a diagram showing the effect of identifying Juncus effusus samples under the application of the design embodiment of the present invention. Detailed Implementation
[0037] The specific embodiments of the present invention will be further described in detail below with reference to the accompanying drawings.
[0038] This invention presents a method for identifying traditional Chinese medicine (TCM) powder based on image features. This method applies to TCM powder, requiring the collection, drying, pulverizing, and sieving of the herbs to obtain the powder. Specifically, appropriate amounts of each TCM sample are taken and pulverized in a micro-pulverizer for 1-2 minutes, then poured out and passed through a 100-mesh sieve to obtain the sample powder. Similarly, standard TCM samples are directly passed through a 100-mesh sieve to obtain the standard TCM powder.
[0039] The designed method for identifying Chinese herbal medicine powder, such as Figure 1 As shown, for a sample group including at least one known category of Chinese medicine powder, the following steps A to B are performed to obtain the corresponding Chinese medicine powder recognition model.
[0040] Step A. Based on the VPS digital micrographs corresponding to the known categories of Chinese medicine sample powders in the sample group, obtain the preset number of feature values for each of the preset basic features corresponding to each known category of Chinese medicine sample powders, and then proceed to Step B.
[0041] VPS digital microscopy, also known as lensless chip digital microscopy, offers advantages over traditional lens-based optical microscopes. It features decoupled imaging field of view and resolution, a simple system structure, and achieves both a large field of view and high resolution without the need for any optical lenses. This results in low cost, miniaturization, and portability, significantly compensating for the shortcomings of existing traditional optical microscopes. VPS digital microscopy is based on the principle of projection-type on-chip microscopy. Because the projection is directly recorded through an image sensor chip, the system resolution is directly determined by the physical size of a single pixel on the imaging chip, while the field of view is the entire photosensitive area of the image sensor chip.
[0042] The VPS digital microscope used in this embodiment is equipped with a 600-megapixel imaging chip with a 500nm pixel size, enabling a single field of view of 150mm. 2 With a resolution of 500nm / pixel, it can be used for microscopic imaging, which is sufficient for observing and identifying the microstructure of most Chinese medicinal powders.
[0043] In the application, a small amount of Chinese herbal powder is placed in a 5ml centrifuge tube, and 3-4ml of pure water is added and mixed evenly. The Chinese herbal powder aqueous suspension is then injected into a BC1600-VPS digital microscope. After standing for a while, a color image is taken to obtain a digital micrograph of the Chinese herbal powder aqueous suspension. This yields VPS digital micrographs corresponding to the Chinese herbal sample powder. Based on the observation and marking in the VPS digital micrographs, the preset number of feature values corresponding to each preset basic feature of the Chinese herbal sample powder are obtained. Furthermore, the BC1600-VPS digital microscope uses a sealed microfluidic cavity for injection, which effectively reduces the generation of air bubbles and the movement of powder particles.
[0044] Step B. Based on the correlation between the basic features, and using the known categories of Chinese medicine powder samples as input and the known categories of Chinese medicine powder samples as output, train the target classification network according to the sample group, obtain the optimal training classification network and the corresponding optimal features, thus obtaining the Chinese medicine powder recognition model corresponding to the sample group.
[0045] Based on the above execution, a corresponding Chinese medicine powder recognition model is obtained. Then, using the Chinese medicine powder recognition model, the following step I is performed to identify the Chinese medicine powder to be identified.
[0046] Step I. Based on the VPS digital microscopic image corresponding to the Chinese medicine powder to be identified, obtain the feature values of each optimal feature corresponding to the Chinese medicine powder to be identified, and execute the Chinese medicine powder identification model to realize the identification of the Chinese medicine powder to be identified with respect to the known categories of Chinese medicine sample powders in the sample group.
[0047] Regarding the specific implementation and application of the above design scheme, step B is specifically designed and executed as follows: steps B1 to B2.
[0048] Step B1. Based on the preset number of feature values corresponding to each preset basic feature of each known category of Chinese medicine sample powder, obtain the correlation between all pairs of basic features in each group, and divide all basic features according to the method of grouping the two basic features corresponding to the correlation greater than the preset correlation threshold into a group, obtain each feature group, and then proceed to step B2.
[0049] Step B2. Based on the basic feature combinations in each feature group, and taking the known category of Chinese medicine sample powder as input and the known category of Chinese medicine sample powder as output, train the target classification network according to the sample group, and measure the recognition accuracy of the trained classification network and the basic feature combination corresponding to the trained classification network to obtain the optimal trained classification network and the corresponding optimal features, that is, obtain the Chinese medicine powder recognition model corresponding to the sample group.
[0050] In practical applications, the specific steps of step B2 are designed as follows: steps B2-1 to B2-7.
[0051] Step B2-1. For each feature group, take each basic feature in the feature group as a node, and connect the two basic features corresponding to the correlation greater than the preset correlation threshold with an edge to construct the undirected graph corresponding to the feature group. Sort the nodes in the undirected graph according to the degree of each node in descending order of degree to obtain the sorting of each basic feature in the feature group. Then proceed to step B2-2.
[0052] Step B2-2. Initialize i = 1, randomly select a feature group that has not participated in the processing of steps B2-2 to B2-5 as the current iteration feature group, and proceed to step B2-3.
[0053] Step B2-3. Select the i-th basic feature in the current iteration feature group and add it to the feature group to be analyzed under the current iteration feature group. Then, based on the sample group, take the feature values of each basic feature in the feature group to be analyzed under the current iteration feature group corresponding to the known category of Chinese medicine sample powder as input and the known category of Chinese medicine sample powder as output. Train the original target classification network to obtain the trained classification network and the recognition accuracy corresponding to the trained classification network. Then proceed to step B2-4.
[0054] Here, the target classification network is chosen to be the YOLOv8 classification network. The YOLOv8 classification network is an efficient and accurate target detection algorithm. It uses deep learning technology to extract image features, generate prediction boxes, and perform target detection, classification, and localization. This classification network has high real-time performance and accuracy, and is suitable for target detection tasks in various scenarios. Furthermore, the goal of the iterative training process of the target classification network is to continuously increase the recognition accuracy and make it tend to fluctuate within a certain data range.
[0055] Step B2-4. Determine if i is equal to the number of basic features in the current iterative feature group. If yes, proceed to step B2-5; otherwise, increment the value of i by 1 and return to step B2-3.
[0056] Step B2-5. For the recognition accuracy of each trained classification network obtained under the current iterative feature group, determine whether there are other recognition accuracies within the preset fluctuation range of the maximum recognition accuracy. If so, for the training classification networks corresponding to the maximum recognition accuracy and each of the other recognition accuracies, obtain the training classification network with the minimum number of features to be analyzed, and use it as the intermediate training classification network under the current iterative feature group, and then proceed to step B2-6; otherwise, select the training classification network corresponding to the maximum recognition accuracy as the intermediate training classification network under the current iterative feature group, and then proceed to step B2-6.
[0057] Step B2-6. Determine if there are any feature groups that were not processed in steps B2-2 to B2-5. If yes, return to step B2-2; otherwise, proceed to step B2-7.
[0058] Step B2-7. Based on the intermediate-level training classification network under each feature group, perform steps B2-7-1 to B2-7-2 to obtain the optimal training classification network and the corresponding optimal features, that is, obtain the Chinese medicine powder recognition model corresponding to the sample group.
[0059] Step B2-7-1. For each feature group, determine whether there are other recognition accuracies within the preset fluctuation range of the maximum recognition accuracy. If so, select the maximum recognition accuracy and the intermediate training classification network corresponding to each of the other recognition accuracies as the training network to be analyzed, and proceed to step B2-7-2.
[0060] Otherwise, select the intermediate post-trained classification network corresponding to the maximum recognition accuracy as the optimal post-trained classification network, and use each feature to be analyzed as the optimal feature corresponding to the optimal post-trained classification network, thus obtaining the Chinese medicine powder recognition model corresponding to the sample group.
[0061] Step B2-7-2. For each network to be analyzed after training, determine whether the number of networks to be analyzed after training with the minimum number of features to be analyzed is greater than 1. If so, for each network to be analyzed after training, obtain the sum of the degrees of each feature to be analyzed in its respective feature group, which constitutes the feature complexity of the network to be analyzed. Then, select the network to be analyzed after training with the minimum feature complexity as the optimal training classification network, and the corresponding features to be analyzed as the optimal features of the optimal training classification network, thus obtaining the Chinese medicine powder recognition model corresponding to the sample group.
[0062] If the number of trained networks corresponding to the minimum number of features to be analyzed is equal to 1, then the trained network to be analyzed is selected as the optimal trained classification network, and each feature to be analyzed is selected as the optimal feature corresponding to the optimal trained classification network, thus obtaining the Chinese medicine powder recognition model corresponding to the sample group.
[0063] Applying the above design to specific embodiments, such as to identify six traditional Chinese medicines—Lygodium japonicum, Typha pollen, Dioscorea opposita, Lycoperdon perlatum, Poria cocos, and Juncus effusus—is as follows: First, obtain powders of these six traditional Chinese medicines according to the above method. Then, build a sample group. If the sample group contains only one of these six traditional Chinese medicine powders, the corresponding traditional Chinese medicine powder identification model obtained from the sample group is a single traditional Chinese medicine powder identification model. In the application, only the identification of a single traditional Chinese medicine category is realized. For example, the application can identify the authenticity of traditional Chinese medicine powders. Specifically, for example, obtaining the traditional Chinese medicine powder identification model corresponding to Lycoperdon perlatum. When there is actually a Lycoperdon perlatum to be analyzed, the traditional Chinese medicine powder corresponding to the Lycoperdon perlatum to be analyzed can be obtained according to the design scheme. Then, the traditional Chinese medicine powder identification model corresponding to the Lycoperdon perlatum is applied to determine whether the Lycoperdon perlatum to be analyzed is genuine.
[0064] Alternatively, if the sample group includes at least two of these six types of Chinese herbal powders, then the identification of the Chinese herbal powder to be identified can be achieved based on the known categories of Chinese herbal powders in the sample group. For example, if the sample group includes three known categories of Chinese herbal powders: Lygodium japonicum, Typha pollen, and Dioscorea opposita, then a Chinese herbal powder identification model corresponding to Lygodium japonicum, Typha pollen, and Dioscorea opposita can be obtained. This Chinese herbal powder identification model can then be applied to identify the Chinese herbal powder to be analyzed and determine whether it is Lygodium japonicum, Typha pollen, or Dioscorea opposita.
[0065] In practical applications, the traditional Chinese medicine powder recognition model for the six herbs mentioned above—Lygodium japonicum, Typha pollen, Dioscorea opposita, Lycoperdon perlatum, Poria cocos, and Juncus effusus—obtained using the design of this invention can, in actual recognition, achieve the following results: Figures 2 to 7 As shown, the identification effects of samples of Lygodium japonicum, Typha pollen, Dioscorea opposita, Lycoperdon perlatum, Poria cocos, and Juncus effusus are shown in order. It can be seen that the design method of the present invention can accurately identify the category of Chinese medicine powder.
[0066] In practical applications, the above-mentioned method for identifying Chinese medicine powder also includes a computer device and a computer-readable storage medium. The computer device includes a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, it implements the steps of the above method.
[0067] A computer program is stored on a computer-readable storage medium, which, when executed by a processor, implements the steps of the above method.
[0068] This patented design proposes a method for identifying traditional Chinese medicine (TCM) powders based on image features. Utilizing VPS digital microscopy imaging, it provides high-precision image acquisition of TCM powders and introduces a classification network machine learning approach. During the training of the target classification network with samples, the correlation between various basic features is considered, constructing feature groups. Based on the ranking of the complexity of each basic feature within each feature group, the input combinations of each basic feature are sequentially selected, and the target classification network is trained. Finally, the optimal trained classification network is selected based on factors such as improving recognition accuracy and reducing the dimensionality of input features, thus obtaining the TCM powder identification model. In practical applications, based on VPS digital microscopy images and the TCM powder identification model, the identification of the TCM powder to be identified is efficiently achieved.
[0069] The embodiments of the present invention have been described in detail above with reference to the accompanying drawings. However, the present invention is not limited to the above embodiments. Within the scope of knowledge possessed by those skilled in the art, various changes can be made without departing from the spirit of the present invention.
Claims
1. A method for identifying traditional Chinese medicine powder based on image features, characterized in that: For a sample group including at least one known category of Chinese herbal medicine powder, perform steps A to B as follows to obtain a corresponding Chinese herbal medicine powder recognition model; then, using the Chinese herbal medicine powder recognition model, perform the following steps. The identification is performed on the powder of the Chinese medicine to be identified. Step A. Based on the VPS digital micrographs corresponding to the powder samples of Chinese medicine in each known category in the sample group, obtain the preset number of feature values corresponding to each preset basic feature of the powder samples of Chinese medicine in each known category, and then proceed to Step B; Step B. Based on the correlation between the basic features, and using the known categories of Chinese medicine powder samples as input and the known categories of Chinese medicine powder samples as output, train the target classification network according to the sample group, obtain the optimal training classification network and the corresponding optimal features, that is, obtain the Chinese medicine powder recognition model corresponding to the sample group. Step B above includes the following steps B1 to B2: Step B1. Based on the feature values of the preset number of each basic feature corresponding to each known category of Chinese medicine sample powder, obtain the correlation between all pairs of basic features in each group, and divide all basic features according to the method of grouping the two basic features corresponding to the correlation greater than the preset correlation threshold into a group, obtain each feature group, and then proceed to step B2. Step B2. Based on the basic feature combinations in each feature group, and taking the feature values corresponding to the known categories of Chinese medicine sample powder as input and the known categories of Chinese medicine sample powder as output, train the target classification network according to the sample group. Measure the recognition accuracy of the trained classification network and the basic feature combinations corresponding to the trained classification network to obtain the optimal trained classification network and the corresponding optimal features, thus obtaining the Chinese medicine powder recognition model corresponding to the sample group. Step B2 above includes the following steps B2-1 to B2-7: Step B2-1. For each feature group, each basic feature in the feature group is used as a node. The two basic features corresponding to the correlation greater than the preset correlation threshold are connected by an edge. Construct an undirected graph corresponding to the feature group. Sort the nodes in the undirected graph in descending order of degree according to the degree of each node. That is, obtain the sorting of each basic feature in the feature group. Then proceed to step B2-2. Step B2-2. Initialization Randomly select a feature group that did not participate in steps B2-2 to B2-5 as the current iteration feature group, and proceed to step B2-3; Step B2-3. Select the sequential number of features in the current iteration group. The basic features are added to the feature group to be analyzed under the current iteration feature group. Then, based on the sample group, the feature values of each basic feature in the feature group to be analyzed under the current iteration feature group corresponding to the known category of Chinese medicine sample powder are used as inputs, and the known category of Chinese medicine sample powder is used as outputs. The original target classification network is trained to obtain the trained classification network and the recognition accuracy corresponding to the trained classification network. Then, proceed to step B2-4. Step B2-4. Judgment Is it equal to the number of basic features in the current iterative feature group? If yes, proceed to step B2-5; otherwise, for... The value is incremented by 1 and the process returns to step B2-3; Step B2-5. For the recognition accuracy of each trained classification network obtained under the current iterative feature group, determine whether there are other recognition accuracies within the preset fluctuation range of the maximum recognition accuracy. If so, for the training classification networks corresponding to the maximum recognition accuracy and each of the other recognition accuracies, obtain the training classification network with the minimum number of features to be analyzed, and use it as the intermediate training classification network under the current iterative feature group, and then proceed to step B2-6; otherwise, select the training classification network corresponding to the maximum recognition accuracy as the intermediate training classification network under the current iterative feature group, and then proceed to step B2-6. Step B2-6. Determine if there are any feature groups that were not processed in steps B2-2 to B2-5. If so, return to step B2-2. Otherwise proceed to step B2-7; Step B2-7. Based on the intermediate-level training classification network under each feature group, obtain the optimal training classification network and the corresponding optimal features, that is, obtain the Chinese medicine powder recognition model corresponding to the sample group. Step B2-7 above includes steps B2-7-1 to B2-7-2; Step B2-7-1. For each feature group, determine whether there are other recognition accuracies within the preset fluctuation range of the maximum recognition accuracy. If so, select the maximum recognition accuracy and the intermediate training classification network corresponding to each of the other recognition accuracies as the training network to be analyzed, and proceed to step B2-7-2. Otherwise, select the intermediate post-training classification network corresponding to the maximum recognition accuracy as the optimal post-training classification network, and take each feature to be analyzed as the optimal feature corresponding to the optimal post-training classification network, thus obtaining the Chinese medicine powder recognition model corresponding to the sample group. Step B2-7-2. For each network to be analyzed after training, determine whether the number of networks to be analyzed after training with the minimum number of features to be analyzed is greater than 1. If so, for each network to be analyzed after training, obtain the sum of the degrees of each feature to be analyzed in its respective feature group, which constitutes the feature complexity of the network to be analyzed. Then, select the network to be analyzed after training with the minimum feature complexity as the optimal training classification network, and the corresponding features to be analyzed as the optimal features of the optimal training classification network, thus obtaining the Chinese medicine powder recognition model corresponding to the sample group. If the number of trained networks corresponding to the minimum number of features to be analyzed is equal to 1, then the trained network to be analyzed is selected as the optimal trained classification network, and each feature to be analyzed is selected as the optimal feature corresponding to the optimal trained classification network, thus obtaining the Chinese medicine powder recognition model corresponding to the sample group. step Based on the VPS digital microscopic image of the Chinese medicine powder to be identified, the feature values of each optimal feature of the Chinese medicine powder to be identified are obtained, and the Chinese medicine powder identification model is executed to realize the identification of the Chinese medicine powder to be identified with respect to the known categories of Chinese medicine sample powders in the sample group.
2. The method for identifying traditional Chinese medicine powder based on image features according to claim 1, characterized in that: The iterations during the training process of the target classification network aim to continuously increase the recognition accuracy and make it fluctuate within a certain data range.
3. A computer device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the computer program, it implements the steps of the method of claim 1 or 2.
4. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the steps of the method of claim 1 or 2.
Citation Information
Patent Citations
Intelligent traditional Chinese medicine powder identification method and system based on microscopic images
CN111709389A