CN110298829A - A kind of lingual diagnosis method, apparatus, system, computer equipment and storage medium - Google Patents

A kind of lingual diagnosis method, apparatus, system, computer equipment and storage medium Download PDF

Info

Publication number
CN110298829A
CN110298829A CN201910534520.3A CN201910534520A CN110298829A CN 110298829 A CN110298829 A CN 110298829A CN 201910534520 A CN201910534520 A CN 201910534520A CN 110298829 A CN110298829 A CN 110298829A
Authority
CN
China
Prior art keywords
image
tongue body
tongue
obtains
characteristic
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201910534520.3A
Other languages
Chinese (zh)
Inventor
白全海
高长龙
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shanghai National Group Health Technology Co Ltd
Original Assignee
Shanghai National Group Health Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shanghai National Group Health Technology Co Ltd filed Critical Shanghai National Group Health Technology Co Ltd
Priority to CN201910534520.3A priority Critical patent/CN110298829A/en
Publication of CN110298829A publication Critical patent/CN110298829A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T5/00Image enhancement or restoration
    • G06T5/90Dynamic range modification of images or parts thereof
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/0002Inspection of images, e.g. flaw detection
    • G06T7/0012Biomedical image inspection
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/10Segmentation; Edge detection
    • G06T7/13Edge detection
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/10Segmentation; Edge detection
    • G06T7/155Segmentation; Edge detection involving morphological operators
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/10Segmentation; Edge detection
    • G06T7/187Segmentation; Edge detection involving region growing; involving region merging; involving connected component labelling
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/60Analysis of geometric attributes
    • G06T7/62Analysis of geometric attributes of area, perimeter, diameter or volume
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/90Determination of colour characteristics
    • GPHYSICS
    • G16INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR SPECIFIC APPLICATION FIELDS
    • G16HHEALTHCARE INFORMATICS, i.e. INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR THE HANDLING OR PROCESSING OF MEDICAL OR HEALTHCARE DATA
    • G16H50/00ICT specially adapted for medical diagnosis, medical simulation or medical data mining; ICT specially adapted for detecting, monitoring or modelling epidemics or pandemics
    • G16H50/20ICT specially adapted for medical diagnosis, medical simulation or medical data mining; ICT specially adapted for detecting, monitoring or modelling epidemics or pandemics for computer-aided diagnosis, e.g. based on medical expert systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/20Special algorithmic details
    • G06T2207/20081Training; Learning
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/20Special algorithmic details
    • G06T2207/20084Artificial neural networks [ANN]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/30Subject of image; Context of image processing
    • G06T2207/30004Biomedical image processing

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Health & Medical Sciences (AREA)
  • Medical Informatics (AREA)
  • Biomedical Technology (AREA)
  • General Health & Medical Sciences (AREA)
  • Public Health (AREA)
  • Pathology (AREA)
  • Databases & Information Systems (AREA)
  • Epidemiology (AREA)
  • Data Mining & Analysis (AREA)
  • Primary Health Care (AREA)
  • Nuclear Medicine, Radiotherapy & Molecular Imaging (AREA)
  • Radiology & Medical Imaging (AREA)
  • Quality & Reliability (AREA)
  • Geometry (AREA)
  • Image Processing (AREA)

Abstract

The invention belongs to technical field of image processing more particularly to a kind of lingual diagnosis method, apparatus, system, computer equipment and storage mediums.Method includes: the tongue body original image for obtaining user, carries out color correction to tongue body original image, obtains tongue body correcting image;Tongue body correcting image is subjected to image parameter transformation, obtains tongue body changing image;Tongue body changing image is split and micronization processes, obtains tongue body segmented image;Tongue body segmented image is inputted preset identification neural network to identify, obtains and exports tongue body diagnostic result.A kind of lingual diagnosis method provided in an embodiment of the present invention, professional environment is applicable not only to so that lingual diagnosis is more accurate by the combination that color of image alignment technique and data enhance, also there is under non-standard light source good applicability simultaneously, there is high-precision and real-time processing speed.

Description

A kind of lingual diagnosis method, apparatus, system, computer equipment and storage medium
Technical field
The invention belongs to technical field of image processing more particularly to a kind of lingual diagnosis method, apparatus, system, computer equipment And storage medium.
Background technique
Lingual diagnosis is one of Chinese medicine four methods of diagnosis, and under standard illumination, doctor judges according to the features such as patient's tongue body shape and color Patient, but since tongue characteristic variation is very fast, patient checks that frequency is higher, and doctor's workload is huge, while by Discrimination is not high between different tongue characteristics, and tongue color coating colour etc. is visually difficult to differentiate, and doctor is easy to happen erroneous judgement.
In recent years, Chinese medicine intelligent diagnosis system constantly comes out, and carries out disease by the color and structure feature that identify tongue body Diagnosis, but this kind of identification technology is higher generally for the quality requirement of image, mostly uses the target detection of harsh standard And image classification algorithms, network are often crossed and are parameterized, the network architecture is huge, there are the network structure of bulk redundancy and calculates ginseng Number, calculating speed is slower, and tongue body has entirely different tongue color and coating colour feature under different light sources, so that lingual diagnosis result Accuracy can not ensure.
It can be seen that the lingual diagnosis technical application condition of the prior art is harsh, diagnostic result is easy to be influenced by picture quality.
Summary of the invention
The embodiment of the present invention is designed to provide a kind of lingual diagnosis method, it is intended to solve prior art diagnostic accuracy and be easy The problem of constraint by picture quality.
The embodiments of the present invention are implemented as follows, a kind of lingual diagnosis method, which comprises
The tongue body original image for obtaining user carries out color correction to the tongue body original image, obtains tongue body correction figure Picture;
The tongue body correcting image is subjected to image parameter transformation, obtains tongue body changing image;
The tongue body changing image is split and micronization processes, obtains tongue body segmented image;
The tongue body segmented image is inputted preset identification neural network to identify, obtain and exports tongue body diagnosis knot Fruit.
The another object of the embodiment of the present invention is to provide a kind of lingual diagnosis device, and described device includes:
Image flame detection module carries out color school to the tongue body original image for obtaining the tongue body original image of user Just, tongue body correcting image is obtained;
Image transform module obtains tongue body changing image for the tongue body correcting image to be carried out image parameter transformation;
Image segmentation module obtains tongue body segmentation figure for being split to the tongue body changing image and micronization processes Picture;
Identification module is diagnosed, identifies, obtains for the tongue body segmented image to be inputted preset identification neural network To tongue body deagnostic structure.
The another object of the embodiment of the present invention is to provide a kind of lingual diagnosis system, the system comprises:
Image collecting device, for acquiring patient's tongue body original image;And
Lingual diagnosis device described above is known for obtaining the tongue body original image, and to the tongue body original image It does not diagnose, obtain and exports tongue body diagnostic result.
The another object of the embodiment of the present invention is to provide a kind of computer equipment, including memory and processor, described Computer program is stored in memory, when the computer program is executed by the processor, so that the processor executes The step of above-mentioned lingual diagnosis method.
The another object of the embodiment of the present invention is to provide a kind of computer readable storage medium, described computer-readable to deposit Computer program is stored on storage media, when the computer program is executed by processor, so that described in processor execution The step of lingual diagnosis method.
A kind of lingual diagnosis method provided in an embodiment of the present invention, the combination enhanced by color of image alignment technique and data, So that lingual diagnosis is more accurate, it is applicable not only to professional environment, while also there is good applicability under non-standard light source, is had High-precision and real-time processing speed.
Detailed description of the invention
Fig. 1 is the applied environment figure of lingual diagnosis method provided in an embodiment of the present invention;
Fig. 2 is the flow chart of lingual diagnosis method provided in an embodiment of the present invention;
Fig. 3 is the flow chart of tongue body correcting image parameter transformation provided in an embodiment of the present invention;
Fig. 4 is the flow chart of image segmentation micronization processes provided in an embodiment of the present invention;
Fig. 5 is the flow chart of identification model provided in an embodiment of the present invention training;
Fig. 6 is the structural block diagram of lingual diagnosis device provided in an embodiment of the present invention;
Fig. 7 is the structural block diagram of image transform module provided in an embodiment of the present invention;
Fig. 8 is the structural block diagram of image segmentation module provided in an embodiment of the present invention;
Fig. 9 is the structural block diagram of diagnosis identification module provided in an embodiment of the present invention;
Figure 10 is the structural block diagram of lingual diagnosis system provided in an embodiment of the present invention;
Figure 11 is the internal structure block diagram of computer equipment in one embodiment.
Specific embodiment
In order to make the objectives, technical solutions, and advantages of the present invention clearer, with reference to the accompanying drawings and embodiments, right The present invention is further elaborated.It should be appreciated that the specific embodiments described herein are merely illustrative of the present invention, and It is not used in the restriction present invention.
It is appreciated that term " first " used in this application, " second " etc. can be used to describe various elements herein, But unless stated otherwise, these elements should not be limited by these terms.These terms are only used to by first element and another yuan Part is distinguished.For example, in the case where not departing from scope of the present application, the first xx script can be known as the 2nd xx script, And similarly, the 2nd xx script can be known as the first xx script.
Fig. 1 be a kind of applied environment figure of lingual diagnosis method provided in an embodiment of the present invention, as shown in Figure 1, this apply ring In border, including image capture device 110 and computer equipment 120.
Computer equipment 120 can be independent physical server or terminal, is also possible to multiple physical servers and constitutes Server cluster, the cloud service of the basic cloud computing service such as Cloud Server, cloud database, cloud storage and CDN can be to provide Device.
Image capture device 110 is the equipment with image collecting function, can be video camera, camera, smart phone, Tablet computer, laptop etc., however, it is not limited to this.Image capture device 110 and computer equipment 120 can pass through Network is attached, and the present invention is herein with no restrictions.
Embodiment one
As shown in Fig. 2, in embodiments of the present invention, proposing a kind of lingual diagnosis method, the present embodiment is mainly answered in this way It is illustrated for the computer equipment 120 in above-mentioned Fig. 1.A kind of lingual diagnosis method, can specifically include following steps:
Step S202 obtains the tongue body original image of user, carries out color correction to tongue body original image, obtains tongue body and rectifys Positive image;
Tongue body correcting image is carried out image parameter transformation, obtains tongue body changing image by step S204;
Step S206, is split tongue body changing image and micronization processes, obtains tongue body segmented image;
Tongue body segmented image is inputted preset identification neural network and identified, obtained and export tongue body by step S208 Diagnostic result.
In embodiments of the present invention, common polynomial regression can be taken by carrying out color correction to tongue body original image The common color correction algorithm such as method, backward Internet communication algorithm or support vector regression algorithm, in addition to this, the present invention is real It applies in example and color correction is preferably carried out to image using color constancy algorithm.Color constancy algorithm is mainly according to color constancy Derivative algorithm, color constancy refer to that people are to the object table face when the color of light for irradiating body surface changes The consciousness of color still maintains constant perceptual properties.The principle of color constancy algorithm is based on the specific rule of Beer-Lambert, and content is The image formed by two different illumination can convert (diagonal model) by diagonal matrix, need to only search out the light in original image According to original picture being converted into the picture at standard white light (R=G=B=1) through diagonal matrix.The tool of color constancy algorithm Body executes and use process is quite mature, and the present invention is not further described and explains, those skilled in the art Can the description according to the present invention in example realized.
Be corrected in the embodiment of the present invention by the color to image, can to the tongue body picture under non-standard light source into Row correction restores color character of the tongue body under standard sources, and then improves the accuracy of diagnosis identification.
In embodiments of the present invention, as shown in figure 3, step S204 can specifically include following steps:
Tongue body correction image is carried out equal proportion scaling and filling, obtains the zoomed image of pre-set dimension by step S302.
Zoomed image is carried out data enhancing by step S304, obtains enhancing image.
In embodiments of the present invention, the mode of data enhancing may include carrying out geometric transformation, color picture to zoomed image Element transformation and non-tongue body image pattern training etc. modes, wherein carry out geometric transformation mainly include tongue body picture direction rotate, tongue Body picture mirror image, tongue body image scaling, tongue body image cut, the transformation of tongue body image aspects, tongue body image blocks at random and tongue body The operations such as image random cropping scaling, tongue body inclination that may be present, distance change, camera shooting when to adjust shooting tongue body picture Situations such as head mirror picture and camera non-standard visual angle;Color pixel transformation includes mainly tongue body color jitter, adds Gauss at random The operations such as noise, tongue body image pixel be fuzzy, tongue color and shooting when being conveniently adjusted shooting tongue body picture under difference light conditions When camera shake situations such as;The training of non-tongue body image pattern refer to portrait picture without tongue body of random selection in training, its Its item pictures, random indoor scene and random outdoor scene are mixed as non-tongue body image pattern with tongue body picture at random Training is closed, to deepen differentiation of the recognizer model to the identification of tongue characteristic and to non-tongue body picture, enhances algorithm model Shandong Stick.
Enhancing image is normalized in step S306, and is carried out mean value except variance operates, and obtains tongue body Changing image.
In embodiments of the present invention, it is normalized and maximum pixel normalization is carried out to image first, then according to pre- The tongue body image element mean value and variance counted on the tongue body image data set of statistics is first collected, mean value is carried out except variance to image Operation, to enhance the robustness of partitioning algorithm, removal mean variance be can be formulated as:
Pix in above formula(rgb)To enhance image pixel, pix '(rgb)For the pixel after normalized, mean (r, g, b) and Var (r, g, b) is respectively the RGB channel mean value and variance counted on tongue body image data set.
In embodiments of the present invention, step S302 specifically:
First opposite side of the tongue body correcting image is subjected to equal proportion scaling, can be formulated as:
Wherein, w is original image pixels width, and h is original image pixels height, and w ' is the image pixel after uniform zoom Width, h ' are the image pixel height after uniform zoom, KaFor the width of the pre-set dimension image;
Second opposite side of the tongue body correcting image after equal proportion is scaled carries out pixel filling, can be formulated Are as follows:
Wherein, w ' is the image pixel width after uniform zoom, and h ' is the image pixel height after uniform zoom, KbFor institute The height of pre-set dimension image is stated, P is the pixel value filled needed for the second opposite side.
In embodiments of the present invention, since the tongue body picture of high pixel will increase extra calculation amount, and low pixel is crossed Tongue body picture can lose tongue characteristic, and the present invention is based on a large amount of experiment, it is good that discovery tongue body dimension of picture, which is 512*512, Equalization point, therefore pre-set dimension is preferably uniformly adjusted to 512*512 standard pixel dimensions, i.e., by above-mentioned Ka、KbIt is set as 512, It is improved so that obtained tongue body changing image carries out processing speed when subsequent processing.
In embodiments of the present invention, as shown in figure 4, step S206 can specifically include following steps:
Tongue body changing image is carried out image segmentation, and extracts the tongue characteristic on tongue body by step S402, tongue characteristic packet Include tongue body body feature and tongue body edge features.
In embodiments of the present invention, it when extracting feature, in encoder stage, carries out feature extraction and obtains tongue body minutia With high-level semantics feature, high-level semantics feature is subjected to multiple dimensioned convolution sum pondization processing and attention scales, obtains encoder The tongue body high-level semantics information of extraction.Due to the mainly high-level semantics feature that encoder obtains, the thin of tongue body edge can be lost Feature is saved, so the details spy that encoder high-level semantics feature is carried out deconvolution and is extracted with backbone network in decoder stage Sign is connected, and by process of convolution and up-sampling, finally obtains fine tongue body segmentation result.
Step S304 carries out profile processing to tongue characteristic, and profile is handled including at contours extract, Optimal Polygon Approximation Of Planar The combination of reason and one or more of algorithm of convex hull processing, obtains tongue body segmented image.
In embodiments of the present invention, affected by environment, the tongue body picture after segmentation can have the interference spot of irregular shape Point, but this also spot small volume and is not connected to tongue body, the present invention uses morphological profiles extraction algorithm, utilizes tongue body body Product is much larger than interference spot and is not mutually connected to this characteristic, only retains the connected region of maximum volume, removes other connected regions, Obtain tongue body segmentation result;In addition, often there is jagged edge in the result after segmentation, using Optimal Polygon Approximation Of Planar to tongue body Edge is smoothed, so that the result of tongue body segmentation is more mellow and fuller smooth;Meanwhile in order to increase Optimal Polygon Approximation Of Planar Robustness increases algorithm of convex hull after Optimal Polygon Approximation Of Planar, prevents polygon from carrying out algorithm and tongue body edge separation is gone out.
In embodiments of the present invention, know as shown in figure 5, tongue body segmented image is inputted preset identification neural network Before not, further includes:
Step S502 obtains the tongue body sample image of preset quantity, and carries out to the tongue characteristic on tongue body sample image Mark, obtains tongue characteristic sample image.
In embodiments of the present invention, tongue characteristic includes morphological feature and color characteristic, and wherein color characteristic may include Whole tongue color, totaglossa coating colour, tongue side color, in tongue the positions such as coating colour and the tip of the tongue color color, morphological feature includes indentation, tongue Features, the present invention such as shape, totaglossa crackle, crack site, stripping tongue fur do not enumerate further.
Step S504 adds tongue characteristic label to tongue characteristic sample image, and tongue characteristic label is used to indicate and tongue The physical condition of the corresponding user of body characteristics sample image;For example lingual diagnosis is normal or abnormal.
Tongue characteristic sample image and corresponding tongue characteristic label are input to neural network and are trained by step S506 Obtain identification neural network.
In embodiments of the present invention, tongue characteristic sample image and corresponding tongue characteristic label are input to neural network It further include using knowledge distillation coaching method, neural networks pruning algorithm to the knowledge when being trained to obtain identification neural network Other neural network optimizes.Specifically, knowledge distillation coaching method is specifically referred to using catenet as tutor model, training High-precision model is obtained, object module and tutor model are subjected to joint training, allows object module to extract from tutor model and knows Know, reach with the approximate precision of tutor model, while speed is fast still as classroom model, so as to improve trained speed and Reduce load;In practical application, in order to improve computational accuracy, integrated model technology is often used, it is general with the mistake for reducing lingual diagnosis Rate is similar to voting mechanism, and multiple models are less likely to make a mistake in the same place, so that precision is improved, but this algorithm Speed needs repeatedly to calculate, speed is slower, and weighted average can also be used in the embodiment of the present invention due to using multiple models SWA technology, the multiple mutually isostructural object modules of training carry out parameter and are averaged, and reduce model errors rate;In addition, due to nerve net There are the calculating parameter of many redundancies in network, model technology of prunning branches has been used to optimize network structure in the embodiment of the present invention Design, to obtain the specially web results suitable for tongue body classification, detailed process is first to carry out model training, then carries out beta pruning, Training fine tuning again, constantly repeats this process, finally obtains high speed and high-accuracy network structure suitable for tongue body identification.
A kind of lingual diagnosis method provided in an embodiment of the present invention, the combination enhanced by color of image alignment technique and data, So that lingual diagnosis is more accurate, it is applicable not only to professional environment, while also there is good applicability under non-standard light source, is had High-precision and real-time processing speed.
Embodiment two
As shown in fig. 6, in embodiments of the present invention, providing a kind of lingual diagnosis device, device includes:
Image flame detection module 601 carries out color school to tongue body original image for obtaining the tongue body original image of user Just, tongue body correcting image is obtained;
Image transform module 602 obtains tongue body changing image for tongue body correcting image to be carried out image parameter transformation;
Image segmentation module 603 obtains tongue body segmentation figure for being split to tongue body changing image and micronization processes Picture;
Identification module 604 is diagnosed, identifies, obtains for tongue body segmented image to be inputted preset identification neural network Tongue body deagnostic structure.
In embodiments of the present invention, common polynomial regression can be taken by carrying out color correction to tongue body original image The common color correction algorithm such as method, backward Internet communication algorithm or support vector regression algorithm, in addition to this, the present invention is real It applies in example and color correction is preferably carried out to image using color constancy algorithm.Color constancy algorithm is mainly according to color constancy Derivative algorithm, color constancy refer to that people are to the object table face when the color of light for irradiating body surface changes The consciousness of color still maintains constant perceptual properties.The principle of color constancy algorithm is based on the specific rule of Beer-Lambert, and content is The image formed by two different illumination can convert (diagonal model) by diagonal matrix, need to only search out the light in original image According to original picture being converted into the picture at standard white light (R=G=B=1) through diagonal matrix.The tool of color constancy algorithm Body executes and use process is quite mature, and the present invention is not further described and explains, those skilled in the art Can the description according to the present invention in example realized.
Be corrected in the embodiment of the present invention by the color to image, can to the tongue body picture under non-standard light source into Row correction restores color character of the tongue body under standard sources, and then improves the accuracy of diagnosis identification.
In embodiments of the present invention, as shown in fig. 7, image transform module 602 can specifically include:
Image scaling unit 701 obtains pre-set dimension for tongue body correction image to be carried out equal proportion scaling and filling Zoomed image.
Image enhancing unit 702 obtains enhancing image for zoomed image to be carried out data enhancing.
In embodiments of the present invention, the mode of data enhancing may include carrying out geometric transformation, color picture to zoomed image Element transformation and non-tongue body image pattern training etc. modes, wherein carry out geometric transformation mainly include tongue body picture direction rotate, tongue Body picture mirror image, tongue body image scaling, tongue body image cut, the transformation of tongue body image aspects, tongue body image blocks at random and tongue body The operations such as image random cropping scaling, tongue body inclination that may be present, distance change, camera shooting when to adjust shooting tongue body picture Situations such as head mirror picture and camera non-standard visual angle;Color pixel transformation includes mainly tongue body color jitter, adds Gauss at random The operations such as noise, tongue body image pixel be fuzzy, tongue color and shooting when being conveniently adjusted shooting tongue body picture under difference light conditions When camera shake situations such as;The training of non-tongue body image pattern refer to random selection in training do not conform to tongue body portrait picture, its Its item pictures, random indoor scene and random outdoor scene are mixed as non-tongue body image pattern with tongue body picture at random Training is closed, to deepen differentiation of the recognizer model to the identification of tongue characteristic and to non-tongue body picture, enhances algorithm model Shandong Stick.
Normalized unit 703 for enhancing image to be normalized, and is carried out mean value except variance Operation, obtains tongue body changing image.
In embodiments of the present invention, it is normalized and maximum pixel normalization is carried out to image first, then according to pre- The tongue body image element mean value and variance counted on the tongue body image data set of statistics is first collected, mean value is carried out except variance to image Operation, to enhance the robustness of partitioning algorithm, removal mean variance be can be formulated as:
Pix in above formula(rgb)To enhance image pixel, pix '(rgb)For the pixel after normalized, mean (r, g, b) and Var (r, g, b) is respectively the RGB channel mean value and variance counted on tongue body image data set.
In embodiments of the present invention, when unit for scaling 701 calculates specifically:
First opposite side of the tongue body correcting image is subjected to equal proportion scaling, can be formulated as:
Wherein, w is original image pixels width, and h is original image pixels height, and w ' is the image pixel after uniform zoom Width, h ' are the image pixel height after uniform zoom, KaFor the width of the pre-set dimension image;
Second opposite side of the tongue body correcting image after equal proportion is scaled carries out pixel filling, can be formulated Are as follows:
Wherein, w ' is the image pixel width after uniform zoom, and h ' is the image pixel height after uniform zoom, KbFor institute The height of pre-set dimension image is stated, P is the pixel value filled needed for the second opposite side.
In embodiments of the present invention, since the tongue body picture of high pixel will increase extra calculation amount, and low pixel is crossed Tongue body picture can lose tongue characteristic, and the present invention is based on a large amount of experiment, it is good that discovery tongue body dimension of picture, which is 512*512, Equalization point, therefore pre-set dimension is preferably uniformly adjusted to 512*512 standard pixel dimensions, i.e., by above-mentioned Ka、KbIt is set as 512, It is improved so that obtained tongue body changing image carries out processing speed when subsequent processing.
In embodiments of the present invention, as shown in figure 8, image segmentation module 603 can specifically include:
Feature extraction unit 801 for tongue body changing image to be carried out image segmentation, and extracts the spy of the tongue body on tongue body Sign, tongue characteristic includes tongue body body feature and tongue body edge features.
In embodiments of the present invention, it when extracting feature, in encoder stage, carries out feature extraction and obtains tongue body minutia With high-level semantics feature, high-level semantics feature is subjected to multiple dimensioned convolution sum pondization processing and attention scales, obtains encoder The tongue body high-level semantics information of extraction.Due to the mainly high-level semantics feature that encoder obtains, the thin of tongue body edge can be lost Feature is saved, so the details spy that encoder high-level semantics feature is carried out deconvolution and is extracted with backbone network in decoder stage Sign is connected, and by process of convolution and up-sampling, finally obtains fine tongue body segmentation result.
Profile processing unit 802, for carrying out profile processing to tongue characteristic, it includes contours extract that profile, which is handled, polygon The combination of the processing of shape approximate algorithm and one or more of algorithm of convex hull processing, obtains tongue body segmented image.
In embodiments of the present invention, affected by environment, the tongue body picture after segmentation can have the interference spot of irregular shape Point, but this also spot small volume and is not connected to tongue body, the present invention uses morphological profiles extraction algorithm, utilizes tongue body body Product is much larger than interference spot and is not mutually connected to this characteristic, only retains the connected region of maximum volume, removes other connected regions, Obtain tongue body segmentation result;In addition, often there is jagged edge in the result after segmentation, using Optimal Polygon Approximation Of Planar to tongue body Edge is smoothed, so that the result of tongue body segmentation is more mellow and fuller smooth;Meanwhile in order to increase Optimal Polygon Approximation Of Planar Robustness increases algorithm of convex hull after Optimal Polygon Approximation Of Planar, prevents polygon from carrying out algorithm and tongue body edge separation is gone out.
In embodiments of the present invention, as shown in figure 9, diagnosis identification module 604 further include:
Sample acquisition unit 901, for obtaining the tongue body sample image of preset quantity, and to the tongue on tongue body sample image Body characteristics are labeled, and obtain tongue characteristic sample image.
In embodiments of the present invention, tongue characteristic includes morphological feature and color characteristic, and wherein color characteristic may include Whole tongue color, totaglossa coating colour, tongue side color, in tongue the positions such as coating colour and the tip of the tongue color color, morphological feature includes indentation, tongue Features, the present invention such as shape, totaglossa crackle, crack site, stripping tongue fur do not enumerate further.
Label adding unit 902, for adding tongue characteristic label to tongue characteristic sample image, tongue characteristic label is used In the physical condition for indicating user corresponding with tongue characteristic sample image;For example lingual diagnosis is normal or abnormal.
Recognition training unit 903, for tongue characteristic sample image and corresponding tongue characteristic label to be input to nerve Network is trained to obtain identification neural network.
In embodiments of the present invention, tongue characteristic sample image and corresponding tongue characteristic label are input to neural network It further include using knowledge distillation coaching method, neural networks pruning algorithm to the knowledge when being trained to obtain identification neural network Other neural network optimizes.Specifically, knowledge distillation coaching method is specifically referred to using catenet as tutor model, training High-precision model is obtained, object module and tutor model are subjected to joint training, allows object module to extract from tutor model and knows Know, reach with the approximate precision of tutor model, while speed is fast still as classroom model, so as to improve trained speed and Reduce load;In practical application, in order to improve computational accuracy, integrated model technology is often used, it is general with the mistake for reducing lingual diagnosis Rate is similar to voting mechanism, and multiple models are less likely to make a mistake in the same place, so that precision is improved, but this algorithm Speed needs repeatedly to calculate, speed is slower, and weighted average can also be used in the embodiment of the present invention due to using multiple models SWA technology, the multiple mutually isostructural object modules of training carry out parameter and are averaged, and reduce model errors rate;In addition, due to nerve net There are the calculating parameter of many redundancies in network, model technology of prunning branches has been used to optimize network structure in the embodiment of the present invention Design, to obtain the specially web results suitable for tongue body classification, detailed process is first to carry out model training, then carries out beta pruning, Training fine tuning again, constantly repeats this process, finally obtains high speed and high-accuracy network structure suitable for tongue body identification.
A kind of lingual diagnosis device provided in an embodiment of the present invention, the combination enhanced by color of image alignment technique and data, So that lingual diagnosis is more accurate, it is applicable not only to professional environment, while also there is good applicability under non-standard light source, is had High-precision and real-time processing speed.
Embodiment three
As shown in Figure 10, in embodiments of the present invention, a kind of lingual diagnosis system is provided, system includes:
Image collecting device 1001, for acquiring patient's tongue body original image;And
Such as the lingual diagnosis device 1002 in the embodiment of the present invention two, for obtaining tongue body original image, and to tongue body original graph As carrying out identifying and diagnosing, obtains and export tongue body diagnostic result.
A kind of lingual diagnosis system provided in an embodiment of the present invention, the combination enhanced by color of image alignment technique and data, So that lingual diagnosis is more accurate, it is applicable not only to professional environment, while also there is good applicability under non-standard light source, is had High-precision and real-time processing speed.
Example IV
Figure 11 shows the internal structure chart of computer equipment in one embodiment.As shown in figure 11, the computer equipment It include processor, memory, network interface, input unit and the display connected by system bus including the computer equipment Screen.Wherein, memory includes non-volatile memory medium and built-in storage.The non-volatile memory medium of the computer equipment is deposited Operating system is contained, computer program can be also stored with, when which is executed by processor, processor may make to realize Lingual diagnosis method.Computer program can also be stored in the built-in storage, when which is executed by processor, may make place It manages device and executes lingual diagnosis method.The display screen of computer equipment can be liquid crystal display or electric ink display screen, computer The input unit of equipment can be the touch layer covered on display screen, be also possible to the key being arranged on computer equipment shell, Trace ball or Trackpad can also be external keyboard, Trackpad or mouse etc..
It will be understood by those skilled in the art that structure shown in Figure 11, only part relevant to application scheme The block diagram of structure, does not constitute the restriction for the computer equipment being applied thereon to application scheme, and specific computer is set Standby may include perhaps combining certain components or with different component layouts than more or fewer components as shown in the figure.
In embodiments of the present invention, lingual diagnosis device provided by the present application can be implemented as a kind of form of computer program, Computer program can be run in computer equipment as shown in figure 11.It can be stored in the memory of computer equipment and form the tongue Examine each program module of device.The computer program that each program module is constituted executes processor in this specification to describe The embodiment of the present application lingual diagnosis method in step.
Embodiment five
In embodiments of the present invention, a kind of computer readable storage medium is provided, is stored on computer readable storage medium There is computer program, when computer program is executed by processor, so that processor executes following steps:
The tongue body original image for obtaining user carries out color correction to tongue body original image, obtains tongue body correcting image;
Tongue body correcting image is subjected to image parameter transformation, obtains tongue body changing image;
Tongue body changing image is split and micronization processes, obtains tongue body segmented image;
Tongue body segmented image is inputted preset identification neural network to identify, obtains and exports tongue body diagnostic result.
Although should be understood that various embodiments of the present invention flow chart in each step according to arrow instruction successively It has been shown that, but these steps are not that the inevitable sequence according to arrow instruction successively executes.Unless expressly state otherwise herein, There is no stringent sequences to limit for the execution of these steps, these steps can execute in other order.Moreover, each embodiment In at least part step may include that perhaps these sub-steps of multiple stages or stage are not necessarily multiple sub-steps Completion is executed in synchronization, but can be executed at different times, the execution in these sub-steps or stage sequence is not yet Necessarily successively carry out, but can be at least part of the sub-step or stage of other steps or other steps in turn Or it alternately executes.
Those of ordinary skill in the art will appreciate that realizing all or part of the process in above-described embodiment method, being can be with Relevant hardware is instructed to complete by computer program, the program can be stored in a non-volatile computer and can be read In storage medium, the program is when being executed, it may include such as the process of the embodiment of above-mentioned each method.Wherein, provided herein Each embodiment used in any reference to memory, storage, database or other media, may each comprise non-volatile And/or volatile memory.Nonvolatile memory may include that read-only memory (ROM), programming ROM (PROM), electricity can be compiled Journey ROM (EPROM), electrically erasable ROM (EEPROM) or flash memory.Volatile memory may include random access memory (RAM) or external cache.By way of illustration and not limitation, RAM is available in many forms, such as static state RAM (SRAM), dynamic ram (DRAM), synchronous dram (SDRAM), double data rate sdram (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronization link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) directly RAM (RDRAM), straight Connect memory bus dynamic ram (DRDRAM) and memory bus dynamic ram (RDRAM) etc..
Each technical characteristic of embodiment described above can be combined arbitrarily, for simplicity of description, not to above-mentioned reality It applies all possible combination of each technical characteristic in example to be all described, as long as however, the combination of these technical characteristics is not deposited In contradiction, all should be considered as described in this specification.
The embodiments described above only express several embodiments of the present invention, and the description thereof is more specific and detailed, but simultaneously Limitations on the scope of the patent of the present invention therefore cannot be interpreted as.It should be pointed out that for those of ordinary skill in the art For, without departing from the inventive concept of the premise, various modifications and improvements can be made, these belong to guarantor of the invention Protect range.Therefore, the scope of protection of the patent of the invention shall be subject to the appended claims.

Claims (10)

1. a kind of lingual diagnosis method, which is characterized in that the described method includes:
The tongue body original image for obtaining user carries out color correction to the tongue body original image, obtains tongue body correcting image;
The tongue body correcting image is subjected to image parameter transformation, obtains tongue body changing image;
The tongue body changing image is split and micronization processes, obtains tongue body segmented image;
The tongue body segmented image is inputted preset identification neural network to identify, obtains and exports tongue body diagnostic result.
2. the method according to claim 1, wherein it is described by the tongue body correcting image carry out parameter transformation, Tongue body changing image is obtained, is specifically included:
Tongue body correction image is subjected to equal proportion scaling and filling, obtains the zoomed image of pre-set dimension;
The zoomed image is subjected to data enhancing, obtains enhancing image;
The enhancing image is normalized, and is carried out mean value except variance operates, obtains tongue body changing image.
3. according to the method described in claim 2, it is characterized in that, the tongue body correcting image be rectangle, it is described by the tongue Sports school's positive image carries out equal proportion scaling and filling, obtains the zoomed image of pre-set dimension, specifically:
First opposite side of the tongue body correcting image is subjected to equal proportion scaling, can be formulated as:
Wherein, w is original image pixels width, and h is original image pixels height, and w ' is that the image pixel after uniform zoom is wide Degree, h ' are the image pixel height after uniform zoom, KaFor the width of the pre-set dimension image;
Second opposite side of the tongue body correcting image after equal proportion is scaled carries out pixel filling, can be formulated as:
Wherein, w ' is the image pixel width after uniform zoom, and h ' is the image pixel height after uniform zoom, KbIt is described pre- If the height of sized image, P is the pixel value filled needed for the second opposite side.
4. the method according to claim 1, wherein described be split and refine to the tongue body changing image Processing, obtains tongue body segmented image, specifically includes:
The tongue body changing image is subjected to image segmentation, and extracts the tongue characteristic on tongue body, the tongue characteristic includes tongue Phosphor bodies feature and tongue body edge features;
Profile processing carried out to the tongue characteristic, profile processing include contours extract, Optimal Polygon Approximation Of Planar processing and The combination of one or more of algorithm of convex hull processing, obtains tongue body segmented image.
5. the method according to claim 1, wherein described input preset identification for the tongue body segmented image Before neural network is identified, further includes:
The tongue body sample image of preset quantity is obtained, and the tongue characteristic on the tongue body sample image is labeled, is obtained Tongue characteristic sample image;
Tongue characteristic label is added to the tongue characteristic sample image, the tongue characteristic label is used to indicate and the tongue body The physical condition of the corresponding user of feature samples image;
The tongue characteristic sample image and the corresponding tongue characteristic label are input to neural network and are trained to obtain Identify neural network.
6. according to the method described in claim 5, it is characterized in that, described by the tongue characteristic sample image and corresponding institute It further include using knowledge distillation training when stating tongue characteristic label and being input to neural network and be trained to obtain identification neural network Method, neural networks pruning algorithm optimize the identification neural network.
7. a kind of lingual diagnosis device, which is characterized in that described device includes:
Image flame detection module carries out color correction to the tongue body original image, obtains for obtaining the tongue body original image of user To tongue body correcting image;
Image transform module obtains tongue body changing image for the tongue body correcting image to be carried out image parameter transformation;
Image segmentation module obtains tongue body segmented image for being split to the tongue body changing image and micronization processes;
Identification module is diagnosed, is identified for the tongue body segmented image to be inputted preset identification neural network, obtains tongue Body deagnostic structure.
8. a kind of lingual diagnosis system, which is characterized in that the system comprises:
Image collecting device, for acquiring patient's tongue body original image;And
Lingual diagnosis device as claimed in claim 7 is carried out for obtaining the tongue body original image, and to the tongue body original image Identifying and diagnosing obtains and exports tongue body diagnostic result.
9. a kind of computer equipment, which is characterized in that including memory and processor, computer journey is stored in the memory Sequence, when the computer program is executed by the processor, so that the processor perform claim requires any one of 1 to 6 power Benefit requires the step of lingual diagnosis method.
10. a kind of computer readable storage medium, which is characterized in that be stored with computer on the computer readable storage medium Program, when the computer program is executed by processor, so that the processor perform claim requires any one of 1 to 6 right It is required that the step of lingual diagnosis method.
CN201910534520.3A 2019-06-19 2019-06-19 A kind of lingual diagnosis method, apparatus, system, computer equipment and storage medium Pending CN110298829A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910534520.3A CN110298829A (en) 2019-06-19 2019-06-19 A kind of lingual diagnosis method, apparatus, system, computer equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910534520.3A CN110298829A (en) 2019-06-19 2019-06-19 A kind of lingual diagnosis method, apparatus, system, computer equipment and storage medium

Publications (1)

Publication Number Publication Date
CN110298829A true CN110298829A (en) 2019-10-01

Family

ID=68028284

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910534520.3A Pending CN110298829A (en) 2019-06-19 2019-06-19 A kind of lingual diagnosis method, apparatus, system, computer equipment and storage medium

Country Status (1)

Country Link
CN (1) CN110298829A (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110826565A (en) * 2019-11-01 2020-02-21 北京中科芯健医疗科技有限公司 Cross-connection-based convolutional neural network tooth mark tongue picture classification method and system
CN112233194A (en) * 2020-10-15 2021-01-15 平安科技(深圳)有限公司 Medical picture optimization method, device and equipment and computer-readable storage medium
CN112806964A (en) * 2021-01-28 2021-05-18 清华大学 Tongue picture analysis method and system
CN113706515A (en) * 2021-08-31 2021-11-26 平安科技(深圳)有限公司 Tongue image abnormality determination method, tongue image abnormality determination device, computer device, and storage medium
CN115147372A (en) * 2022-07-04 2022-10-04 海南榕树家信息科技有限公司 Traditional Chinese medicine tongue image intelligent identification and treatment method and system based on medical image segmentation

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102419861A (en) * 2010-09-27 2012-04-18 上海中医药大学 Color image correcting method based on topology subdivision of uniform color space
CN106295139A (en) * 2016-07-29 2017-01-04 姹ゅ钩 A kind of tongue body autodiagnosis health cloud service system based on degree of depth convolutional neural networks
CN106683087A (en) * 2016-12-26 2017-05-17 华南理工大学 Coated tongue constitution distinguishing method based on depth neural network
CN107977671A (en) * 2017-10-27 2018-05-01 浙江工业大学 A kind of tongue picture sorting technique based on multitask convolutional neural networks
US10119927B2 (en) * 2010-12-23 2018-11-06 Crc Care Pty Ltd Analyte ion detection method and device
CN109637660A (en) * 2018-12-19 2019-04-16 新绎健康科技有限公司 A kind of lingual diagnosis analysis method and system based on depth convolutional neural networks
CN109636864A (en) * 2018-12-19 2019-04-16 新绎健康科技有限公司 A kind of tongue dividing method and system based on color correction Yu depth convolutional neural networks
CN109785311A (en) * 2019-01-14 2019-05-21 深圳和而泰数据资源与云技术有限公司 A kind of methods for the diagnosis of diseases and relevant device

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102419861A (en) * 2010-09-27 2012-04-18 上海中医药大学 Color image correcting method based on topology subdivision of uniform color space
US10119927B2 (en) * 2010-12-23 2018-11-06 Crc Care Pty Ltd Analyte ion detection method and device
CN106295139A (en) * 2016-07-29 2017-01-04 姹ゅ钩 A kind of tongue body autodiagnosis health cloud service system based on degree of depth convolutional neural networks
CN106683087A (en) * 2016-12-26 2017-05-17 华南理工大学 Coated tongue constitution distinguishing method based on depth neural network
CN107977671A (en) * 2017-10-27 2018-05-01 浙江工业大学 A kind of tongue picture sorting technique based on multitask convolutional neural networks
CN109637660A (en) * 2018-12-19 2019-04-16 新绎健康科技有限公司 A kind of lingual diagnosis analysis method and system based on depth convolutional neural networks
CN109636864A (en) * 2018-12-19 2019-04-16 新绎健康科技有限公司 A kind of tongue dividing method and system based on color correction Yu depth convolutional neural networks
CN109785311A (en) * 2019-01-14 2019-05-21 深圳和而泰数据资源与云技术有限公司 A kind of methods for the diagnosis of diseases and relevant device

Cited By (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110826565A (en) * 2019-11-01 2020-02-21 北京中科芯健医疗科技有限公司 Cross-connection-based convolutional neural network tooth mark tongue picture classification method and system
CN112233194A (en) * 2020-10-15 2021-01-15 平安科技(深圳)有限公司 Medical picture optimization method, device and equipment and computer-readable storage medium
WO2022077914A1 (en) * 2020-10-15 2022-04-21 平安科技(深圳)有限公司 Medical image optimization method and apparatus, device, computer readable storage medium
CN112233194B (en) * 2020-10-15 2023-06-02 平安科技(深圳)有限公司 Medical picture optimization method, device, equipment and computer readable storage medium
CN112806964A (en) * 2021-01-28 2021-05-18 清华大学 Tongue picture analysis method and system
CN113706515A (en) * 2021-08-31 2021-11-26 平安科技(深圳)有限公司 Tongue image abnormality determination method, tongue image abnormality determination device, computer device, and storage medium
CN113706515B (en) * 2021-08-31 2023-07-18 平安科技(深圳)有限公司 Tongue image anomaly determination method, tongue image anomaly determination device, computer equipment and storage medium
CN115147372A (en) * 2022-07-04 2022-10-04 海南榕树家信息科技有限公司 Traditional Chinese medicine tongue image intelligent identification and treatment method and system based on medical image segmentation
CN115147372B (en) * 2022-07-04 2024-05-03 海南榕树家信息科技有限公司 Intelligent Chinese medicine tongue image identification and treatment method and system based on medical image segmentation

Similar Documents

Publication Publication Date Title
CN111612763B (en) Mobile phone screen defect detection method, device and system, computer equipment and medium
CN110298829A (en) A kind of lingual diagnosis method, apparatus, system, computer equipment and storage medium
US20220092882A1 (en) Living body detection method based on facial recognition, and electronic device and storage medium
Jiang et al. Face super-resolution via multilayer locality-constrained iterative neighbor embedding and intermediate dictionary learning
CN111445459B (en) Image defect detection method and system based on depth twin network
Zhang et al. Multiple-level feature-based measure for retargeted image quality
WO2020253127A1 (en) Facial feature extraction model training method and apparatus, facial feature extraction method and apparatus, device, and storage medium
CN112115783A (en) Human face characteristic point detection method, device and equipment based on deep knowledge migration
CN109871845B (en) Certificate image extraction method and terminal equipment
CN112784810B (en) Gesture recognition method, gesture recognition device, computer equipment and storage medium
CN112528969B (en) Face image authenticity detection method and system, computer equipment and storage medium
Tian et al. A multi-order derivative feature-based quality assessment model for light field image
WO2014187223A1 (en) Method and apparatus for identifying facial features
CN110807139A (en) Picture identification method and device, computer readable storage medium and computer equipment
Zhang et al. Marn: multi-scale attention retinex network for low-light image enhancement
CN112633221A (en) Face direction detection method and related device
Yue et al. Semi-supervised authentically distorted image quality assessment with consistency-preserving dual-branch convolutional neural network
CN111047618B (en) Multi-scale-based non-reference screen content image quality evaluation method
Sun et al. Image adaptation and dynamic browsing based on two-layer saliency combination
CN113781468A (en) Tongue image segmentation method based on lightweight convolutional neural network
Zheng et al. Overwater image dehazing via cycle-consistent generative adversarial network
Fu et al. Screen content image quality assessment using Euclidean distance
CN115115552B (en) Image correction model training method, image correction device and computer equipment
CN111695464A (en) Modeling method for linear coring feature space grouping based on fusion kernel
CN116469172A (en) Bone behavior recognition video frame extraction method and system under multiple time scales

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication

Application publication date: 20191001

RJ01 Rejection of invention patent application after publication