Safflower quality production and blending method and system based on near-infrared hyperspectral image recognition and LIBS (Laser-induced Breakdown Spectroscopy) data fusion

Through near-infrared hyperspectral image recognition and LIBS data fusion, combined with the deep reinforcement learning model, the problem of quality differences within batches of safflower Chinese medicinal materials has been solved, the online detection and deployment of safflower has been realized, and the quality consistency and quality of the products have been improved. Use effect.

CN118780937APending Publication Date: 2024-10-15TIANJIN UNIV OF TRADITIONAL CHINESE MEDICINE +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410832538.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-06-26
Publication Date
2024-10-15

AI Technical Summary

Technical Problem

Differences in the concentration of organic and inorganic components between different packaging bags of safflower Chinese medicinal materials in the same production batch lead to inconsistent efficacy, affecting the quality and use effect of Chinese medicinal materials.

Method used

Using near-infrared hyperspectral image recognition and LIBS data fusion, through the image-hydroxysafflor yellow A concentration recognition model and the deep reinforcement learning model DQN, online detection and deployment of safflower is achieved to ensure the consistency of quality within batches.

Benefits of technology

It achieves rapid online detection of organic and inorganic substances in safflower, reduces quality fluctuations, and improves product quality consistency and usage effects.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118780937A_ABST
    Figure CN118780937A_ABST
Patent Text Reader

Abstract

The invention provides a safflower quality production blending method and system based on near-infrared hyperspectral image recognition and LIBS data fusion. The method comprises the following steps: training to obtain an image-hydroxysafflor yellow A concentration recognition model of safflower; respectively carrying out near-infrared hyperspectral image data acquisition on the carthamus tinctorius of different packages in the same batch, and obtaining respective hydroxysafflor yellow A concentration through the carthamus tinctorius image-hydroxysafflor yellow A concentration identification model; detecting the carthamus tinctorius of the same batch and different packages in the step S2 through a laser-induced breakdown spectroscopy (LIBS) to obtain the concentration of inorganic ions; and performing blending decision on the hydroxysafflor yellow A concentration and the inorganic ion concentration of the carthamus tinctorius of the same batch and different packages through a deep reinforcement learning model DQN to obtain a blending scheme. The quality fluctuation in batches of traditional Chinese medicinal materials is effectively reduced, and the quality consistency of products is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the technical field of intelligent production of traditional Chinese medicine, and in particular relates to a safflower quality production and preparation method and system based on near-infrared hyperspectral image recognition and LIBS data fusion. Background Art

[0002] Safflower is an annual herbaceous plant of the Asteraceae family and the genus Safflower. The flower of Safflower is used as medicine to regulate menstruation and promote blood circulation, and is mainly used to treat women's diseases. According to the Kaibao Materia Medica, Safflower is pungent, warm, and non-toxic. It is used to treat postpartum blood circulation, lockjaw, abdominal blood retention, colic, and fetal death, and is boiled in wine and taken. It is also used to treat poisonous bleeding. As a commonly used medicine, the quality inspection of Safflower has become a research focus.

[0003] At present, since safflower is mainly derived from planting, there will be differences in the concentration of organic and inorganic components in different packaging bags of safflower slices in the same production batch, which has an uncertain impact on the efficacy of the medicinal materials. Therefore, it is necessary to start from the online detection data and quality evaluation index data of medicinal materials, and use artificial intelligence technology to achieve intelligent blending of Chinese medicinal materials in different packaging bags of the same batch, improve the batch consistency of the efficacy of Chinese medicinal materials, and improve the use effect of Chinese medicinal materials. Summary of the invention

[0004] The present invention proposes a safflower quality production and deployment method and system based on near-infrared hyperspectral image recognition and LIBS data fusion, which can effectively reduce the quality fluctuation within batches of Chinese medicinal materials and improve the quality consistency of products.

[0005] To achieve the above object, the technical solution of the present invention is achieved as follows:

[0006] A safflower quality production and adjustment method based on near-infrared hyperspectral image recognition and LIBS data fusion, comprising:

[0007] S1, collecting near-infrared hyperspectral image data of safflower, and detecting the concentration of hydroxysafflor yellow A on the collected safflower, using the near-infrared hyperspectral image data and the corresponding hydroxysafflor yellow A concentration data as a training sample set, and training to obtain a safflower image-hydroxysafflor yellow A concentration recognition model;

[0008] S2, collecting near-infrared hyperspectral image data of safflowers in different packages of the same batch, and obtaining the hydroxysafflor yellow A concentration of each safflower by using the safflower image-hydroxysafflor yellow A concentration recognition model;

[0009] S3, detecting the safflower of the same batch but different packages described in step S2 by laser induced breakdown spectroscopy (LIBS) to obtain the inorganic ion concentration;

[0010] S4. The concentration of hydroxysafflor yellow A and the concentration of inorganic ions of safflower in different packages of the same batch are adjusted through the deep reinforcement learning model DQN to obtain a adjustment plan.

[0011] Furthermore, the image-hydroxysafflor yellow A concentration recognition model in step S1 is obtained by extracting image features under various near-infrared wavelength conditions through a convolutional neural network and matching them with the hydroxysafflor yellow A concentration, so as to examine the correspondence between the hydroxysafflor yellow A concentration and its near-infrared hyperspectral image features and construct a recognition model for the two.

[0012] Furthermore, in step S3, the inorganic ion concentration is an average concentration data obtained by integrating the concentration data of calcium, magnesium, sodium and potassium ions respectively, and is calculated by algebraic mean.

[0013] Furthermore, in step S4, the method for making deployment decisions includes:

[0014] The core of the deep reinforcement learning model DQN adopts the Markov decision process, which consists of five elements; M = (S, A, P, R, γ), where M represents the Markov decision process; the state set S includes the hydroxysafflor yellow A concentration data and inorganic ion concentration data of each sample; the action set A represents a set of actions for sample preparation according to the concentration data of the state set S, and predicting the new concentration data after preparation and updating it to the state set S; P represents the transition probability, and γ is the discount factor; R represents the reward function, which gives feedback based on the sample preparation action results in the action set; and finally, a preparation plan for safflower of the same batch but different packages is obtained.

[0015] On the other hand, the present invention also provides a safflower quality production and deployment system based on near-infrared hyperspectral image recognition and LIBS data fusion, comprising:

[0016] Recognition model module: collect near-infrared hyperspectral image data of safflower, and detect the concentration of hydroxysafflor yellow A on the collected safflower, use the near-infrared hyperspectral image data and the corresponding hydroxysafflor yellow A concentration data as a training sample set, and train to obtain a safflower image-hydroxysafflor yellow A concentration recognition model;

[0017] Online yellow pigment detection module: collect near-infrared hyperspectral image data of safflower in different packages of the same batch, and obtain the hydroxysafflor yellow A concentration of each safflower through the safflower image-hydroxysafflor yellow A concentration recognition model;

[0018] Online inorganic ion detection module: The safflower of the same batch but different packages described in the online spectrum data module is detected by laser induced breakdown spectrometer LIBS to obtain the inorganic ion concentration;

[0019] Online blending module: The hydroxysafflor yellow A concentration and inorganic ion concentration of safflower in different packages of the same batch are blended through the deep reinforcement learning model DQN to obtain a blending plan.

[0020] Furthermore, the image-hydroxysafflor yellow A concentration recognition model in the recognition model module is obtained by extracting image features under various near-infrared wavelength conditions through a convolutional neural network and matching them with the hydroxysafflor yellow A concentration, so as to examine the correspondence between the hydroxysafflor yellow A concentration and its near-infrared hyperspectral image features and construct a recognition model for the two.

[0021] Furthermore, in the online inorganic ion data module, the inorganic ion concentration is the average concentration data obtained by integrating the concentration data of calcium, magnesium, sodium and potassium ions respectively, and is calculated by algebraic mean.

[0022] Furthermore, the formulation module includes: the core of the deep reinforcement learning model DQN adopts the Markov decision process, which is composed of five elements; M = (S, A, P, R, γ), where M represents the Markov decision process; the state set S includes the hydroxysafflor yellow A concentration data and the inorganic ion concentration data of each sample; the action set A represents a set of actions for performing sample formulation according to the concentration data of the state set S, and predicting the new concentration data after formulation and updating it to the state set S; P represents the transition probability, and γ is the discount factor; R represents the reward function, and the reward function gives feedback according to the sample formulation action results in the action set; and finally a formulation plan for safflower of the same batch but different packages is obtained.

[0023] Compared with the prior art, the present invention has the following beneficial effects:

[0024] 1. The present invention proposes a method and system for production and preparation of safflower based on near-infrared hyperspectral image analysis technology and LIBS metal content detection technology, which realizes rapid online detection of organic and inorganic substance concentrations in safflower, improves detection speed and detection range, and avoids the defect of low representativeness of samples for products caused by existing laboratory spot checks;

[0025] 2. The present invention achieves quality consistency among different packaging bags of safflower in the same production batch, avoids quality differences within the same production batch, achieves product quality stability, and improves the quality consistency of the final product. BRIEF DESCRIPTION OF THE DRAWINGS

[0026] Figure 1 is a schematic diagram of a method flow of an embodiment of the present invention;

[0027] Figure 2 This is a near-infrared hyperspectral safflower detection data diagram according to an embodiment of the present invention;

[0028] Figure 3 This is a graph of inorganic ion detection data according to an embodiment of the present invention. DETAILED DESCRIPTION

[0029] It should be noted that, in the absence of conflict, the embodiments of the present invention and the features in the embodiments may be combined with each other.

[0030] The present invention is further described below in conjunction with the accompanying drawings and specific embodiments.

[0031] Embodiment 1:

[0032] The method proposed by the present invention is as follows Figure 1 As shown, including:

[0033] (1) Image-Hydroxysafflor Yellow A concentration recognition model development and modeling:

[0034] like Figure 2 The figure shows the reflection intensity of safflower for light with a wavelength of 900 to 1700 nm. When the concentration of hydroxysafflor yellow A in safflower changes, the reflection intensity of near-infrared light changes. Therefore, an image-hydroxysafflor yellow A concentration recognition model can be established based on this principle.

[0035] 100g of safflower slices were sampled each time, placed on a conveyor belt and photographed by a near-infrared hyperspectral camera to obtain the corresponding near-infrared hyperspectral image;

[0036] A total of 400 samples were randomly sampled, and their corresponding near-infrared hyperspectral images were obtained;

[0037] High performance liquid chromatography (HPLC) was used to detect the concentration of hydroxysafflor yellow A in 400 samples;

[0038] The deep learning technology of convolutional neural network was used to model the hydroxysafflor yellow A concentration and near-infrared hyperspectral image data of 400 samples;

[0039] Since the materials are scattered on the conveyor belt, they may not be able to fully cover the conveyor belt, and the background of the conveyor belt will be exposed. Therefore, it is necessary to use a polarization image processing method to identify the contour of the safflower, subtract the conveyor belt from the image, and only retain the image part of the safflower;

[0040] The convolutional neural network is used to process and recognize images, and the convolution kernel is slid from the images of each near-infrared wavelength to directly extract their image features;

[0041] Randomly sample 200 replicates for image acquisition and HPLC concentration testing;

[0042] The images of 200 samples were input into the image-hydroxysafflor yellow A concentration recognition model to calculate the corresponding hydroxysafflor yellow A concentration, and compared with its HPLC concentration detection data to verify the reliability of the model;

[0043] The image features under each near-infrared wavelength condition were extracted by convolutional neural network and matched with the concentration of hydroxysafflor yellow A measured by HPLC, so as to investigate the correspondence between the concentration of hydroxysafflor yellow A and its near-infrared hyperspectral image features and build a recognition model for the two.

[0044] (2) Construction of online detection system:

[0045] Install LIBS and near-infrared hyperspectral cameras and related industrial computers on the conveyor belt;

[0046] The obtained image-hydroxysafflor yellow A concentration recognition model is deployed to the industrial computer to realize the automatic recognition of hydroxysafflor yellow A in safflower;

[0047] The safflower of the same production batch is fed into the conveyor belt in 10kg increments and packaged in separate bags;

[0048] Calculate the average concentration of hydroxysafflor yellow A and the average concentration of inorganic ions such as calcium, magnesium, sodium, and potassium in each bag;

[0049] A 10 kg sample is photographed according to near-infrared hyperspectral images of safflower taken every 10 cm in length, and the number of images obtained is counted. For each image, the hydroxysafflor yellow A concentration of safflower is predicted by the image-hydroxysafflor yellow A concentration recognition model, and the obtained results are algebraically averaged according to the number of images to obtain the average concentration of hydroxysafflor yellow A.

[0050] Laser induced breakdown spectroscopy (LIBS) is used to measure the concentration of inorganic ions, such as Figure 3 The figure shows the fluorescence intensity of safflower under laser excitation conditions. The emission peak at around 400nm may be the calcium ion emission peak, the emission peak at around 600nm is the emission peak of magnesium and sodium, and the emission peak at around 750nm is the potassium emission peak. The intensity of the emission peak is directly proportional to the concentration of related ions in safflower, because the concentration of the corresponding metal ions can be converted through the intensity of the related peaks.

[0051] The concentrations of inorganic ions such as calcium, magnesium, sodium, and potassium were measured by LIBS, and the concentration data of each ion were combined to obtain the average data (obtained by algebraic mean calculation) as the average concentration data of the inorganic ions.

[0052] (3) Development of the on-campus deployment system:

[0053] The average concentration of hydroxysafflor yellow A and the average concentration of inorganic ions such as calcium, magnesium, sodium, potassium, etc. in each sub-bag and the total number of sub-bags are used to calculate the average concentration of theoretical hydroxysafflor yellow A and the average concentration of inorganic ions such as calcium, magnesium, sodium, potassium, etc. in the production batch of safflower;

[0054] The drug is packaged in batches of 20 to ensure that the concentration in each packaged bag is close to the predicted average value.

[0055] There may be three situations in each bag: 1. The average concentration of hydroxysafflor yellow A is high, and the average concentration of inorganic ions such as calcium, magnesium, sodium, and potassium is low; 2. The average concentration of hydroxysafflor yellow A is low, and the average concentration of inorganic ions such as calcium, magnesium, sodium, and potassium is high; 3. The average concentration of hydroxysafflor yellow A is high, and the average concentration of inorganic ions such as calcium, magnesium, sodium, and potassium is high. In the subsequent extraction process, the precipitation concentration of hydroxysafflor yellow A in the solution may be affected by inorganic ions such as calcium, magnesium, sodium, and potassium. Therefore, it is necessary to comprehensively examine the concentrations of these two and the reverse flow to select a more appropriate blending concentration.

[0056] The DQN model uses deep reinforcement learning. The core of the DQN model uses the Markov decision process to describe it. It consists of five elements: M = (S, A, P, R, γ). M represents the Markov decision process, and S represents the state set (s∈S). The action set A represents a set of actions (a∈A). P represents the state transition probability, which represents the probability distribution of other states that will be transferred to after the action (a∈A) in the current state (s∈S). For example, when action a is performed in state s, the probability of transferring to s' can be expressed as p(s'|s,a). R is the reward function, which gives feedback on the current state. γ is the discount factor. When γ is 0, it is equivalent to considering only the immediate return without considering the long-term return. When γ is 1, the long-term return and the immediate return are considered equally important.

[0057] For the Chinese medicine manufacturing process, the three key elements of the optimal decision action solution process are the state set S, the action set A and the reward function R.

[0058] The state set S includes the concentration of hydroxysafflor yellow A of each sample, as well as the concentrations of inorganic ions such as calcium, magnesium, sodium, and potassium;

[0059] Action set A represents a set of blending actions. It performs trial blending of each sample according to the current average concentration of the state set S, predicts the concentration of each new sample after blending, and updates it to the state set S.

[0060] The reward function R represents feedback (reward or punishment) based on the results of the preparation action. By accumulating rewards, the agent is expected to learn the process parameter control rules to meet the final product quality requirements. The feedback is mainly based on the concentration of hydroxysafflor yellow A, as well as the concentration of inorganic ions such as calcium, magnesium, sodium, and potassium, to determine whether the concentration of hydroxysafflor yellow A in the prepared extract meets the requirements, thereby obtaining a preparation plan.

[0061] Take 10 packaged bags for extraction and conduct an experiment by boiling for 3 hours to examine whether the hydroxysafflor yellow A in the extract is equal, so as to verify the formulation plan.

[0062] Embodiment 2:

[0063] (1) Image-Hydroxysafflor Yellow A concentration recognition model development and modeling:

[0064] Each time 10g of sample is sampled, a translation stage equipped with a near-infrared hyperspectral camera is used to take photos to obtain the corresponding near-infrared hyperspectral image;

[0065] A total of 400 samples were randomly sampled to obtain their corresponding near-infrared hyperspectral image information;

[0066] HPLC was used to detect the concentration of hydroxysafflor yellow A in 400 samples;

[0067] The deep learning technology of convolutional neural network was used to model the hydroxysafflor yellow A concentration and near-infrared hyperspectral image data of 400 samples;

[0068] Randomly sample 400 replicates for image acquisition and HPLC concentration testing;

[0069] The images of 400 samples were input into the image-hydroxysafflor yellow A concentration recognition model to calculate the corresponding hydroxysafflor yellow A concentration, and compared with its HPLC concentration detection data to verify the reliability of the model;

[0070] (2) Construction of online detection system

[0071] Install LIBS and near-infrared hyperspectral cameras and related industrial computers on the conveyor belt;

[0072] The obtained image-hydroxysafflor yellow A concentration recognition model is deployed to the industrial computer to realize the automatic recognition of hydroxysafflor yellow A in safflower;

[0073] The safflower of the same production batch is fed into a conveyor belt in 2 kg increments and packaged in separate bags;

[0074] Calculate the average concentration of hydroxysafflor yellow A and the average concentration of inorganic ions such as calcium, magnesium, sodium, and potassium in each bag;

[0075] (3) Development of the on-campus deployment system:

[0076] The average concentration of hydroxysafflor yellow A and the average concentration of inorganic ions such as calcium, magnesium, sodium, potassium, etc. in each sub-bag and the total number of sub-bags are used to calculate the average concentration of theoretical hydroxysafflor yellow A and the average concentration of inorganic ions such as calcium, magnesium, sodium, potassium, etc. in the production batch of safflower;

[0077] According to the distribution of bagging data and the batch average, the DQN model based on deep reinforcement learning obtains the bagging allocation plan, and allocates and packages every 200 bags to ensure that the concentration in each packaged bag is basically close to the predicted average;

[0078] Take 10 packaged bags for extraction and conduct an experiment by boiling for 3 hours to examine whether the hydroxysafflor yellow A in the extract is equal, so as to verify the formulation plan.

[0079] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principle of the present invention should be included in the protection scope of the present invention.

Claims

1. A safflower quality production and deployment method based on near-infrared hyperspectral image recognition and LIBS data fusion, characterized in that: include: S1, collecting near-infrared hyperspectral image data of safflower, and detecting the concentration of hydroxysafflor yellow A on the collected safflower, using the near-infrared hyperspectral image data and the corresponding hydroxysafflor yellow A concentration data as a training sample set, and training to obtain a safflower image-hydroxysafflor yellow A concentration recognition model; S2, collecting near-infrared hyperspectral image data of safflowers in different packages of the same batch, and obtaining the hydroxysafflor yellow A concentration of each safflower by using the safflower image-hydroxysafflor yellow A concentration recognition model; S3, detecting the safflower of the same batch but different packages described in step S2 by laser induced breakdown spectroscopy (LIBS) to obtain the inorganic ion concentration; S4. The concentration of hydroxysafflor yellow A and the concentration of inorganic ions of safflower in different packages of the same batch are adjusted through the deep reinforcement learning model DQN to obtain a adjustment plan.

2. The safflower quality production and deployment method based on near-infrared hyperspectral image recognition and LIBS data fusion according to claim 1, characterized in that: The image-hydroxysafflor yellow A concentration recognition model in step S1 is obtained by extracting image features under various near-infrared wavelength conditions through a convolutional neural network and matching them with the hydroxysafflor yellow A concentration, so as to examine the correspondence between the hydroxysafflor yellow A concentration and its near-infrared hyperspectral image features and construct a recognition model for the two.

3. The safflower quality production and deployment method based on near-infrared hyperspectral image recognition and LIBS data fusion according to claim 1, characterized in that: In step S3, the inorganic ion concentration is the average concentration data obtained by integrating the concentration data of calcium, magnesium, sodium and potassium ions respectively, and is calculated by algebraic mean.

4. The safflower quality production and deployment method based on near-infrared hyperspectral image recognition and LIBS data fusion according to claim 1, characterized in that: In step S4, the method for making deployment decisions includes: The core of the deep reinforcement learning model DQN adopts the Markov decision process, which consists of five elements; M = (S, A, P, R, γ), where M represents the Markov decision process; the state set S includes the hydroxysafflor yellow A concentration data and inorganic ion concentration data of each sample; the action set A represents a set of actions for sample preparation according to the concentration data of the state set S, and predicting the new concentration data after preparation and updating it to the state set S; P represents the transition probability, and γ is the discount factor; R represents the reward function, which gives feedback based on the sample preparation action results in the action set; and finally, a preparation plan for safflower of the same batch but different packages is obtained.

5. A safflower quality production and blending system based on near-infrared hyperspectral image recognition and LIBS data fusion, characterized in that: include: Recognition model module: collect near-infrared hyperspectral image data of safflower, and detect the concentration of hydroxysafflor yellow A on the collected safflower, use the near-infrared hyperspectral image data and the corresponding hydroxysafflor yellow A concentration data as a training sample set, and train to obtain a safflower image-hydroxysafflor yellow A concentration recognition model; Online yellow pigment detection module: collect near-infrared hyperspectral image data of safflower in different packages of the same batch, and obtain the hydroxysafflor yellow A concentration of each safflower through the safflower image-hydroxysafflor yellow A concentration recognition model; Online inorganic ion detection module: The safflower of the same batch but different packages described in the online spectrum data module is detected by laser induced breakdown spectrometer LIBS to obtain the inorganic ion concentration; Online blending module: The concentration of hydroxysafflor yellow A and the concentration of inorganic ions of safflower in different packages of the same batch are blended through the deep reinforcement learning model DQN to obtain a blending plan.

6. The safflower quality production and deployment system based on near-infrared hyperspectral image recognition and LIBS data fusion according to claim 5, characterized in that: The image-hydroxysafflor yellow A concentration recognition model in the recognition model module is to extract the image features under various near-infrared wavelength conditions through a convolutional neural network and match them with the hydroxysafflor yellow A concentration, so as to examine the correspondence between the hydroxysafflor yellow A concentration and its near-infrared hyperspectral image features and construct a recognition model for the two.

7. The safflower quality production and deployment system based on near-infrared hyperspectral image recognition and LIBS data fusion according to claim 5, characterized in that: In the online inorganic ion data module, the inorganic ion concentration is the average concentration data obtained by integrating the concentration data of calcium, magnesium, sodium and potassium ions respectively, and is calculated by algebraic mean.

8. The safflower quality production and deployment system based on near-infrared hyperspectral image recognition and LIBS data fusion according to claim 5, characterized in that: The preparation module includes: the core of the deep reinforcement learning model DQN adopts the Markov decision process, which is composed of five elements; M = (S, A, P, R, γ), where M represents the Markov decision process; the state set S includes the hydroxysafflor yellow A concentration data and inorganic ion concentration data of each sample; the action set A represents a set of actions for preparing samples according to the concentration data of the state set S, and predicting the new concentration data after preparation and updating it to the state set S; P represents the transition probability, and γ is the discount factor; R represents the reward function, and the reward function gives feedback according to the sample preparation action results in the action set; and finally, a preparation plan for safflower of the same batch but different packages is obtained.