System and method for discriminating traditional Chinese medicine qi and blood through face image based on computer vision
By using a computer vision-based facial image discrimination system, an image feature extraction model is constructed using OpenCV and a simple SNN model. Combined with the TCMSP database and the CLAHE algorithm, the accuracy and coverage issues of traditional Chinese medicine Qi and blood diagnosis are solved, enabling rapid and objective judgment of Qi and blood status.
Patent Information
- Application Number
- CN202410980766.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-22
- Publication Date
- 2024-11-12
- Estimated Expiration
- 2044-07-22
AI Technical Summary
Existing TCM Qi and Blood diagnostic systems rely on the maturity of computer vision and image processing technologies, resulting in insufficient diagnostic accuracy, narrow coverage, limited applicability, and poor image quality that affects analysis results.
A computer vision-based facial image discrimination system is adopted, including image acquisition, feature extraction and comparison modules. An image feature extraction model is constructed using OpenCV and a simple SNN model, and a blood and qi discrimination model is constructed by combining the TCMSP database and the CLAHE algorithm. Diagnosis is performed through the feature comparison module.
It enables rapid and objective assessment of Qi and blood status, reduces human interference, simplifies operation, and improves the modernization and scientific level of TCM diagnosis.
Smart Images

Figure CN118942674A_ABST
Abstract
Description
Technical Field
[0001] The present invention discloses a computer vision-based facial image identification system and method for traditional Chinese medicine qi and blood, and relates to the field of traditional Chinese medicine. Background Art
[0002] In traditional Chinese medicine, the existing systems and methods for judging qi and blood have the following deficiencies:
[0003] Diagnostic accuracy depends on technology maturity: The diagnostic accuracy of the system is highly dependent on the maturity of computer vision and image processing technology. Insufficient technology will lead to deviations in diagnostic results.
[0004] Narrow coverage: Although the system can provide certain auxiliary diagnostic information, it still cannot completely replace the comprehensive judgment and experience of professional Chinese medicine practitioners.
[0005] Limitations of scope of application: Although the system has wide adaptability, its diagnostic accuracy will be affected for certain populations, such as those with abnormal facial features or suffering from certain diseases.
[0006] Image processing issues: Improper operation by patients or medical staff when taking facial images may result in poor image quality, which in turn affects the analysis results. Summary of the invention
[0007] In view of the deficiencies in the prior art, the purpose of the present invention is to provide a facial image based computer vision system and method for distinguishing TCM Qi and blood, aiming to solve the problem of low efficiency of TCM diagnosis.
[0008] In order to achieve the above object, the present invention is implemented by the following technical scheme: A facial image discrimination system of traditional Chinese medicine qi and blood based on computer vision comprises:
[0009] Image acquisition module: used to obtain the patient's name, mobile phone number and facial image to obtain patient data; establish a patient data set in the format of patient name + patient mobile phone number - patient facial image;
[0010] Feature extraction module: used to build an image feature extraction model; use the image feature extraction model to extract image features in the patient data set to obtain the patient's facial feature set;
[0011] Feature comparison module: used to obtain a set of TCM facial images; use the TCM facial image set as a test set to build a Qi and blood discrimination model; use the Qi and blood discrimination model to analyze the facial feature set and obtain the patient's diagnosis result;
[0012] Patient interaction module: The diagnosis results will be fed back to the corresponding patients based on their name and mobile phone number.
[0013] Furthermore, the workflow of the feature extraction module is as follows:
[0014] Process A1: Extract the patient's facial image; use the OpenCV library function to process the facial image, convert the image data into vector data, and obtain the facial vector;
[0015] Process A2: Use the simple SNN model as the basic model to build an image feature extraction model; define the constraints for the primary and secondary extraction of facial features;
[0016] Process A3: Back up the facial vectors, perform secondary extraction and aggregation on the facial vectors according to the constraints of primary and secondary extraction of facial features, obtain the patient's facial feature set, and send it to the feature comparison module.
[0017] Furthermore, the specific working process of process A2 is as follows:
[0018] Process A21: Define the primary extraction constraints of facial features:
[0019] Process A22: Define constraints for secondary extraction of facial features.
[0020] Furthermore, the specific workflow of process A22 is as follows:
[0021] Process A221: Assume that the secondary data set contains p face images;
[0022] Process A222: process the first face image; use the image function in the OpenCV library to process the first face image and obtain the grayscale value of each pixel in the face image; record the number of pixels as n;
[0023] Define the set B1{y1, y2~y n} represents the grayscale value of the first face image; where y1~y n , represents the grayscale value of the 1st to nth pixels in the 1st face image;
[0024] Process A223: Repeat the process of processing the first face image, process the second to p face images, and obtain a set B2 to Bp;
[0025] Process A223: Redefine the BN operation of the simple CNN model, recorded as BN′ operation;
[0026] Process A2231: Assume that the output of the convolutional layer of the simple CNN model is the input image B, and the grayscale set of the input image B is {x1, x2~x m}; where m represents the number of pixels in the input image B, x1~x m , represents the grayscale value of the 1st to mth pixels in the input image B;
[0027] Furthermore, the workflow of the feature comparison module is as follows:
[0028] Process B1: import the TCMSP database; randomly extract facial images (of people with insufficient Qi and blood) from the TCMSP database as a reference set;
[0029] Process B2: Construct a qi and blood discrimination model; use the CLAHE algorithm to perform image enhancement processing on the reference set, and then divide the reference set into a training set and a test set in a ratio of 4:1;
[0030] Process B3: Define the mean processing formula for the training set and test set:
[0031] Process B4: using the patient's facial feature set as the input of the qi and blood discrimination model to determine whether the qi and blood discrimination model has an output result;
[0032] If yes, it means that the patient has insufficient Qi and blood. The patient's condition is determined based on the output result and the process goes to process B5;
[0033] If not, it means that the patient's Qi and blood are normal, skip process B5, and the diagnosis result is normal Qi and blood;
[0034] Process B5: Use the output result as the query object and use SQL statements to query the patient's disease name in the TCMSP database; use the disease name as the diagnosis result.
[0035] Process B32: Use the test set as the model input x of the Qi and blood discrimination model, use the model output as y, and define the loss function J;
[0036] Process B33: Summarize the definitions and formulas in processes B31 to B32 as model constraints of the basic model to obtain the original model;
[0037] The test set is used as the original model input, and the training set is used as the training target; the original model is continuously iterated until the loss function is minimized to obtain the qi and blood discrimination model.
[0038] A method for identifying TCM Qi and blood based on facial images based on computer vision includes:
[0039] Step S1: used to obtain the patient's name, mobile phone number and facial image to obtain patient data; establish a patient data set in the format of patient name + patient mobile phone number - patient facial image;
[0040] Step S2: constructing an image feature extraction model; using the image feature extraction model to extract image features in the patient data set to obtain a facial feature set of the patient;
[0041] Step S3: used to obtain a set of TCM face images; use the TCM face image set as a test set to construct a Qi and blood discrimination model; use the Qi and blood discrimination model to analyze the facial feature set to obtain the patient's diagnosis result;
[0042] Step S4: Feedback the diagnosis result to the corresponding patient based on the patient's name and mobile phone number.
[0043] Compared with the prior art, the present invention has the following beneficial effects:
[0044] Quick feedback: With the help of computer vision technology, the system of the present invention can complete the processing and analysis of facial images in a short time and quickly give the judgment result of qi and blood status.
[0045] Enhanced objectivity: Compared with the subjective judgment of traditional Chinese medicine diagnosis, the data analysis results provided by endocrinology are more objective and reduce the interference of human factors.
[0046] Improved convenience: Patients only need to take facial images to perform qi and blood analysis. It is easy to operate and popularize; it helps promote the modernization and scientificization of traditional Chinese medicine diagnostic technology. BRIEF DESCRIPTION OF THE DRAWINGS
[0047] Other features, objects and advantages of the present invention will become more apparent from the detailed description of non-limiting embodiments made with reference to the following drawings:
[0048] Figure 1 It is a schematic diagram of the system of the present invention;
[0049] Figure 2 Schematic diagram of the method of the present invention. DETAILED DESCRIPTION
[0050] In order to make the above-mentioned objects, features and advantages of the present invention more obvious and easy to understand, the present invention is further described in detail below with reference to the accompanying drawings and specific embodiments.
[0051] Embodiment 1
[0052] See also Figure 1 A facial image discrimination system for traditional Chinese medicine qi and blood based on computer vision includes: an image acquisition module, a facial extraction module, a facial comparison module, a user interaction module, a database and a server; wherein the image acquisition module, the facial extraction module, the facial comparison module and the user interaction module are connected to the database and the server respectively.
[0053] Image acquisition module: used to obtain the patient's name, mobile phone number and facial image to obtain patient data; establish a patient data set in the format of patient name + patient mobile phone number - patient facial image.
[0054] Feature extraction module: used to build an image feature extraction model; use the image feature extraction model to extract image features in the patient data set to obtain the patient's facial feature set;
[0055] Process A: The workflow of the feature extraction module is as follows:
[0056] Process A1: Extract the patient's facial image; use the OpenCV library function to process the facial image, convert the image data into vector data, and obtain the facial vector;
[0057] Process A2: Use the simple SNN model as the basic model to build an image feature extraction model; define the constraints for the primary and secondary extraction of facial features;
[0058] Process A21: Define the primary extraction constraints of facial features:
[0059] Process A211: Assume that the (initial) primary data set contains N face images, and all face images are represented in the form of vectors, denoted as {L1, L2~L N}; Among them, L1~L N Represents (initial) the vector representation of all face images in a data set; calculates L1~L N The average value of is denoted as ψ;
[0060] Process A212: Define the difference calculation formula:
[0061] φ i =L i -ψ; where i represents 1 to N; φ i Represents the difference value of the initial data set in the i-th face image;
[0062] L1~L N Substitute into the difference calculation formula to calculate L1~L N The corresponding difference φ1~φ N ;
[0063] Process A213: In L1~L N Extract mutually orthogonal vectors from the equation, and record them as candidate vectors; count the number of candidate vectors, record them as z, and record the candidate vectors as λ1~λ z ;
[0064] Process A214: Define the unit vector discriminant:
[0065] Among them, i represents 1~z, λ i represents the i-th candidate vector; T represents transposition, Represents λ i The transpose of
[0066] φ1~φ N Substitute into the unit vector discriminant, extract the candidate vector that satisfies the unit vector discriminant, and use it as the eigenvalue of the initial data set; count the number of eigenvalues, denoted as S; denoted as μ1~μ S ;
[0067] Process A215: Define weight calculation formula:
[0068] Where i represents 1 to S, μ i represents the i-th eigenvalue, ω i represents the weight corresponding to the i-th eigenvalue; T represents transposition, Represents μ i The transpose of
[0069] Process A22: defining constraints for secondary extraction of facial features;
[0070] Process A221: Assume that the (initial) secondary data set contains p face images;
[0071] Process A222: process the first face image; use the image function in the OpenCV library to process the first face image and obtain the grayscale value of each pixel in the face image; record the number of pixels as n;
[0072] Define the set B1{y1, y2~y n} represents the grayscale value of the first face image; where y1~y n , represents the grayscale value of the 1st to nth pixels in the 1st face image;
[0073] Process A223: Repeat the process of processing the first face image, process the second to p face images, and obtain a set B2 to Bp;
[0074] Process A223: Redefine the BN operation of the simple CNN model, recorded as BN′ operation;
[0075] Process A2231: Assume that the output of the convolutional layer of the simple CNN model is the input image B, and the grayscale set of the input image B is {x1, x2~x m}; where m represents the number of pixels in the input image B, x1~x m , represents the grayscale value of the 1st to mth pixels in the input image B;
[0076] Process A2232: The process of performing the BN′ operation on any input image B is as follows:
[0077] Calculate the mean μB of the elements in set B,
[0078] Calculate the variance σB of the elements in set B 2 ,
[0079] Process A2233: Standardize the elements in set B to obtain set B'; the elements in set B' are
[0080] Calculate x1~x m get of The calculation formula is as follows:
[0081]
[0082] Process A3: Back up the facial vectors, perform secondary extraction and aggregation on the facial vectors according to the constraints of primary and secondary extraction of facial features, obtain the patient's facial feature set, and send it to the feature comparison module.
[0083] Feature comparison module: used to obtain a set of TCM facial images; use the TCM facial image set as a test set to build a Qi and blood discrimination model; use the Qi and blood discrimination model to analyze the facial feature set and obtain the patient's diagnosis result;
[0084] Process B: The workflow of the feature comparison module is as follows:
[0085] Process B1: Import the TCMSP database (Traditional Chinese Medicine System Pharmacology Database and Analysis Platform, website: https: / / ol d.tcmsp-e.com / tcmsp.php); randomly extract facial images (of people with insufficient qi and blood) from the TCMSP database as a reference set;
[0086] Process B2: Construct a qi and blood discrimination model; use the CLAHE algorithm to perform image enhancement processing on the reference set, and then divide the reference set into a training set and a test set in a ratio of 4:1;
[0087] Process B3: Define the mean processing formula for the training set and test set:
[0088] Process B31: Averaging formula 1:
[0089]
[0090] Mean value processing formula 2:
[0091]
[0092] The R, G, and B values are: the RGB values corresponding to random pixels on any image in the training set and the test set; R mij , G mij and B mijRepresents: the RGB value of the (i, j)th pixel in any mth image sample in the training set and the test set;
[0093] Process B32: Use the test set as the model input x of the Qi and blood discrimination model, use the model output as y, and define the loss function J:
[0094]
[0095] Where N represents the number of iterations (per model training), i.e., batch-size;
[0096] x i and i , respectively represent the model input and model output when the initial model of medicinal material identification is iterated i times; w represents the weight, and f(w, xi) represents the weight of the model input xi when the initial model of medicinal material identification is iterated i times;
[0097] R represents the regularization term, and λ represents the weight of the control regularization term;
[0098] L represents the cross entropy loss function, the cross entropy loss function L:
[0099] Among them, p ij =f(w,x i );
[0100] Regularization term R:
[0101] Among them, k is the number of weights, and wk represents the weight corresponding to the weight w;
[0102] Process B33: Summarize the definitions and formulas in processes B31 to B32 as model constraints of the basic model to obtain the original model;
[0103] The test set is used as the original model input, and the training set is used as the training target. The original model is continuously iterated until the loss function is minimized, and the Qi and blood discrimination model is obtained.
[0104] Process B4: using the patient's facial feature set as the input of the qi and blood discrimination model to determine whether the qi and blood discrimination model has an output result;
[0105] If yes, it means that the patient has insufficient Qi and blood. The patient's condition is determined based on the output result and the process goes to process B5;
[0106] If not, it means that the patient's Qi and blood are normal, skip process B5, and the diagnosis result is normal Qi and blood;
[0107] Process B5: Use the output result as the query object and use SQL statements to query the patient's disease name in the TCMSP database; use the disease name as the diagnosis result.
[0108] Patient interaction module: The diagnosis results will be fed back to the corresponding patients based on their name and mobile phone number.
[0109] Embodiment 2
[0110] See also Figure 2 A computer vision-based facial image identification method for TCM Qi and blood includes
[0111] Step S1: used to obtain the patient's name, mobile phone number and facial image to obtain patient data; establish a patient data set in the format of patient name + patient mobile phone number - patient facial image;
[0112] The workflow of the feature extraction module is as follows:
[0113] Extract the patient's facial image; use OpenCV library functions to process the facial image, convert the image data into vector data, and obtain the facial vector;
[0114] Use the simple SNN model as the basic model to build an image feature extraction model; define the constraints for the primary and secondary extraction of facial features;
[0115] Define the constraints for primary extraction of facial features:
[0116] Assume that a dataset contains N face images, and all face images are represented in the form of vectors, denoted as {L1, L2~L N}; Among them, L1~L N Represents (initial) the vector representation of all face images in a data set; calculates L1~L N The average value of is denoted as ψ;
[0117] Define the difference calculation formula:
[0118] φ i =L i -ψ; where i represents 1 to N; φ i Represents the difference value of the initial data set in the i-th face image;
[0119] L1~L N Substitute into the difference calculation formula to calculate L1~L N The corresponding difference φ1~φ N ;
[0120] In L1~L NExtract mutually orthogonal vectors from the equation, and record them as candidate vectors; count the number of candidate vectors, record them as z, and record the candidate vectors as λ1~λ z ;
[0121] Define the unit vector discriminant:
[0122] Among them, i represents 1~z, λ i represents the i-th candidate vector; T represents transposition, Represents λ i The transpose of
[0123] φ1~φ N Substitute into the unit vector discriminant, extract the candidate vector that satisfies the unit vector discriminant, and use it as the eigenvalue of the initial data set; count the number of eigenvalues, denoted as S; denoted as μ1~μ S ;
[0124] Define the weight calculation formula:
[0125] Where i represents 1 to S, μ i represents the i-th eigenvalue, ω i represents the weight corresponding to the i-th eigenvalue; T represents transposition, Represents μ i The transpose of
[0126] Define constraints for secondary extraction of facial features;
[0127] Assume that the secondary dataset contains p face images;
[0128] Process the first face image; use the image function in the OpenCV library to process the first face image and obtain the grayscale value of each pixel in the face image; record the number of pixels as n;
[0129] Define the set B1{y1, y2~y n} represents the grayscale value of the first face image; where y1~y n , represents the grayscale value of the 1st to nth pixels in the 1st face image;
[0130] Repeat the process of processing the first face image, process the second to p face images, and obtain a set B2 to Bp;
[0131] Redefine the BN operation of the simple CNN model, recorded as BN′ operation;
[0132] Assume that the output of the convolutional layer of the simple CNN model is the input image B, and the grayscale set of the input image B is {x1, x2~x m}; where m represents the number of pixels in the input image B, x1~xm , represents the grayscale value of the 1st to mth pixels in the input image B;
[0133] The process of performing BN′ operation for any input image B is as follows:
[0134] Calculate the mean μB of the elements in set B,
[0135] Calculate the variance σB of the elements in set B 2 ,
[0136] Standardize the elements in set B to obtain set B'; the elements in set B' are
[0137] Calculate x1~x m get of The calculation formula is as follows:
[0138]
[0139] The facial vector is backed up, and according to the constraints of the primary extraction and secondary extraction of facial features, the facial vector is secondary extracted and summarized to obtain the patient's facial feature set, and sent to the feature comparison module.
[0140] Step S2: constructing an image feature extraction model; using the image feature extraction model to extract image features in the patient data set to obtain a facial feature set of the patient;
[0141] The workflow of the feature comparison module is as follows:
[0142] Import the TCMSP database; randomly extract face images from the TCMSP database as a reference set;
[0143] A qi and blood discrimination model was constructed; the reference set was enhanced using the CLAHE algorithm, and then the reference set was divided into a training set and a test set at a ratio of 4:1;
[0144] Define the mean processing formula for the training set and test set:
[0145] Mean value processing formula 1:
[0146]
[0147] Mean value processing formula 2:
[0148]
[0149] The R, G, and B values are: the RGB values corresponding to random pixels on any image in the training set and the test set; R mij , G mij and B mij Represents: the RGB value of the (i, j)th pixel in any mth image sample in the training set and the test set;
[0150] The test set is used as the model input x of the Qi and blood discrimination model, the model output is used as y, and the loss function J is defined as:
[0151]
[0152] Where N represents the number of iterations (per model training), i.e., batch-size;
[0153] x i and i , respectively represent the model input and model output when the initial model of medicinal material identification is iterated i times; w represents the weight, and f(w, xi) represents the weight of the model input xi when the initial model of medicinal material identification is iterated i times;
[0154] R represents the regularization term, and λ represents the weight of the control regularization term;
[0155] L represents the cross entropy loss function, the cross entropy loss function L:
[0156] Among them, p ij =f(w,x i );
[0157] Regularization term R:
[0158] Among them, k is the number of weights, and wk represents the weight corresponding to the weight w;
[0159] Aggregate the data and use it as the model constraints of the basic model to obtain the original model;
[0160] The test set is used as the original model input, and the training set is used as the training target. The original model is continuously iterated until the loss function is minimized, and the Qi and blood discrimination model is obtained.
[0161] The facial feature set of the patient is used as the input of the Qi and Blood discrimination model to determine whether the Qi and Blood discrimination model has an output result;
[0162] If yes, it means the patient has insufficient Qi and blood, and the condition can be judged based on the output results;
[0163] If not, it means that the patient's qi and blood are normal. The diagnosis result is normal qi and blood;
[0164] Take the output result as the query object, use SQL statements to query the patient's disease name in the TCMSP database; take the disease name as the diagnosis result.
[0165] Step S3: used to obtain a set of TCM face images; use the TCM face image set as a test set to construct a Qi and blood discrimination model; use the Qi and blood discrimination model to analyze the facial feature set to obtain the patient's diagnosis result;
[0166] Step S4: Feedback the diagnosis result to the corresponding patient based on the patient's name and mobile phone number.
[0167] The above formulas are all dimensionless and numerical calculations. The formula is a formula for the most recent real situation obtained by collecting a large amount of data and performing software simulation. The preset parameters in the formula are set by technical personnel in this field according to actual conditions. For example, if there are weight coefficients and proportional coefficients, their set sizes are to quantify each parameter to obtain a specific value, which is convenient for subsequent comparison. Regarding the size of the weight coefficient and the proportional coefficient, it is sufficient as long as it does not affect the proportional relationship between the parameter and the quantized value.
[0168] Finally, it should be noted that the above-described embodiments are only specific implementations of the present invention, which are used to illustrate the technical solutions of the present invention, rather than to limit them. The protection scope of the present invention is not limited thereto. Although the present invention is described in detail with reference to the above-described embodiments, ordinary technicians in the field should understand that any technician familiar with the technical field can still modify the technical solutions recorded in the above-described embodiments within the technical scope disclosed by the present invention, or can easily think of changes, or make equivalent replacements for some of the technical features therein; and these modifications, changes or replacements do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the embodiments of the present invention, and should be included in the protection scope of the present invention. Therefore, the protection scope of the present invention shall be based on the protection scope of the claims.
Claims
1. A facial image identification system for traditional Chinese medicine qi and blood based on computer vision, characterized in that: The discrimination system includes: Image acquisition module: used to obtain the patient's name, mobile phone number and facial image to obtain patient data; establish a patient data set in the format of patient name + patient mobile phone number - patient facial image; Feature extraction module: used to build an image feature extraction model; use the image feature extraction model to extract image features in the patient data set to obtain the patient's facial feature set; Feature comparison module: used to obtain a set of TCM facial images; use the TCM facial image set as a test set to build a Qi and blood discrimination model; use the Qi and blood discrimination model to analyze the facial feature set and obtain the patient's diagnosis result; Patient interaction module: The diagnosis results will be fed back to the corresponding patients based on their name and mobile phone number.
2. According to the computer vision-based facial image identification system of traditional Chinese medicine Qi and blood according to claim 1, it is characterized in that: The workflow of the feature extraction module is as follows: Process A1: Extract the patient's facial image; use the OpenCV library function to process the facial image, convert the image data into vector data, and obtain the facial vector; Process A2: Use the simple SNN model as the basic model to build an image feature extraction model; define the constraints for the primary and secondary extraction of facial features; Process A3: Back up the facial vectors, perform secondary extraction and aggregation on the facial vectors according to the constraints of primary and secondary extraction of facial features, obtain the patient's facial feature set, and send it to the feature comparison module.
3. According to the computer vision-based facial image identification system of traditional Chinese medicine Qi and blood according to claim 2, it is characterized in that: The specific workflow of process A2 is as follows: Process A21: Define the primary extraction constraints of facial features: Process A22: Define constraints for secondary extraction of facial features.
4. According to the computer vision-based facial image identification system of traditional Chinese medicine Qi and blood according to claim 3, it is characterized in that: The specific workflow of process A22 is as follows: Process A221: Assume that the secondary data set contains p face images; Process A222: Process the first face image; use the image function in the OpenCV library to process the first face image and obtain the grayscale value of each pixel in the face image; Let the number of pixels be n; Define the set B1{y1, y2~y n } represents the grayscale value of the first face image; where y1~y n , represents the grayscale value of the 1st to nth pixels in the 1st face image; Process A223: Repeat the process of processing the first face image, process the second to p face images, and obtain a set B2 to Bp; Process A223: Redefine the BN operation of the simple CNN model, denoted as BN′ operation.
5. The facial image based computer vision system for distinguishing TCM Qi and blood according to claim 2, characterized in that: The workflow of the feature comparison module is as follows: Process B1: Import the TCMSP database; randomly extract face images from the TCMSP database as a reference set; Process B2: Construct a qi and blood discrimination model; use the CLAHE algorithm to perform image enhancement processing on the reference set, and then divide the reference set into a training set and a test set in a ratio of 4:1; Process B3: Define the mean processing formula for the training set and test set: Process B4: using the patient's facial feature set as the input of the qi and blood discrimination model to determine whether the qi and blood discrimination model has an output result; If yes, it means that the patient has insufficient Qi and blood. The patient's condition is judged based on the output result and the process goes to process B5; If not, it means that the patient's Qi and blood are normal, skip process B5, and the diagnosis result is normal Qi and blood; Process B5: Use the output result as the query object and use SQL statements to query the patient's disease name in the TCMSP database; use the disease name as the diagnosis result.
6. The facial image based computer vision system for distinguishing TCM Qi and blood according to claim 5, characterized in that: The subsequent workflow of process B3 is as follows: The test set is used as the model input x of the Qi and blood discrimination model, the model output is used as y, and the loss function J is defined; Process B33: Summarize the model constraints of the basic model in processes B31 and B32 to obtain the original model; The test set is used as the original model input, and the training set is used as the training target; the original model is continuously iterated until the loss function is minimized to obtain the qi and blood discrimination model.
7. A method for distinguishing TCM Qi and blood from facial images based on computer vision, applicable to a TCM Qi and blood distinguishing system from facial images based on computer vision as claimed in any one of claims 1 to 6, characterized in that: The discrimination method comprises: Step S1: used to obtain the patient's name, mobile phone number and facial image to obtain patient data; establish a patient data set in the format of patient name + patient mobile phone number - patient facial image; Step S2: constructing an image feature extraction model; using the image feature extraction model to extract image features in the patient data set to obtain a facial feature set of the patient; Step S3: used to obtain a set of TCM face images; use the TCM face image set as a test set to construct a Qi and blood discrimination model; use the Qi and blood discrimination model to analyze the facial feature set to obtain the patient's diagnosis result; Step S4: Feedback the diagnosis result to the corresponding patient based on the patient's name and mobile phone number.
Citation Information
Patent Citations
Traditional Chinese-medical face diagnosis analyzing and diagnosing system
CN103034775A
Health state diagnosis system based on facial image
CN110459304A
Qi and blood state analysis system and method based on facial recognition
CN116530981A
Face video traditional Chinese medicine qi and blood distinguishing system based on computer vision
CN117423041A
Face partition feature associated traditional Chinese medicine function state discrimination method based on graph structure
CN117935331A
