CN111242968A - Method and system for detecting tooth area in tongue sample - Google Patents

Method and system for detecting tooth area in tongue sample Download PDF

Info

Publication number
CN111242968A
CN111242968A CN201911370857.1A CN201911370857A CN111242968A CN 111242968 A CN111242968 A CN 111242968A CN 201911370857 A CN201911370857 A CN 201911370857A CN 111242968 A CN111242968 A CN 111242968A
Authority
CN
China
Prior art keywords
sample
tongue
pixel
pixel point
channel
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.)
Granted
Application number
CN201911370857.1A
Other languages
Chinese (zh)
Other versions
CN111242968B (en
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.)
Ennova Health Technology Co ltd
Original Assignee
Ennova 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 Ennova Health Technology Co ltd filed Critical Ennova Health Technology Co ltd
Priority to CN201911370857.1A priority Critical patent/CN111242968B/en
Publication of CN111242968A publication Critical patent/CN111242968A/en
Application granted granted Critical
Publication of CN111242968B publication Critical patent/CN111242968B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/10Segmentation; Edge detection
    • G06T7/136Segmentation; Edge detection involving thresholding
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods
    • G06T5/70
    • 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/11Region-based segmentation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/10Image acquisition modality
    • G06T2207/10024Color image
    • 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/20024Filtering details
    • G06T2207/20032Median filtering
    • 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/30Subject of image; Context of image processing
    • G06T2207/30004Biomedical image processing
    • G06T2207/30036Dental; Teeth

Abstract

The invention provides a method and a system for detecting tooth areas in a tongue sample. The method and the system collect a colorful tongue body image, generate a first tongue body sample, graying the first tongue body sample in an RGB color space to generate a second tongue body sample; then, processing the grayed image by utilizing local self-adaptive binarization to obtain a third tongue sample; denoising the image by adopting a median filtering method to obtain a fourth tongue sample; and finally, respectively carrying out threshold processing on the RGB three-channel images generated by separating the first tongue body sample by adopting a fourth tongue body sample to generate new RGB three-channel images, and finally combining the new RGB three-channel images to obtain the tongue body sample with the teeth filtered. According to the method and the system, the tongue body sample of the collected color image is subjected to gray processing, so that the calculation amount is reduced, the efficiency is high, the quality of the obtained tongue body sample is high, and a good foundation is laid for a tongue body feature analysis algorithm in the later period.

Description

Method and system for detecting tooth area in tongue sample
Technical Field
The present invention relates to the field of image processing, and more particularly, to a method and system for detecting tooth regions in a tongue sample.
Background
The traditional Chinese medicine tongue image diagnosis comprises the step of judging the characteristics of tongue color, tongue cracks, tongue pricks and the like so as to diagnose the physical condition of people. Because the color of the teeth in the tongue body is white on the whole, the color of the tongue body can have a large influence on the tongue color discrimination in the tongue image diagnosis, and therefore, the tongue body image sample is used as a training sample for deep learning model training of the tongue image diagnosis in the traditional Chinese medicine, when the tongue body image comprises the teeth, the quality of the training sample can be influenced inevitably, and the influence on the accuracy of the model is large. The method has great significance for preprocessing the tongue body sample in the tooth area, removing the tooth area in the sample, improving the quality of a training sample set and further improving the accuracy of a deep learning model of tongue image diagnosis in traditional Chinese medicine. However, the prior art lacks a method for detecting a tooth region in a tongue sample and removing the tooth region.
Disclosure of Invention
In order to solve the technical problem that the prior art lacks a method for detecting a tooth region in a tongue sample, the invention provides a method for detecting a tooth region in a tongue sample, which comprises the following steps:
collecting a colorful tongue body image to generate a first tongue body sample;
separating the color tongue image of the first tongue sample into R, G, B three-channel images, generating a first R-channel sample, a first G-channel sample and a first B-channel sample, respectively;
based on the pixel values of each pixel point in the first tongue body sample in a first R channel sample, a first G channel sample and a first B channel sample, carrying out graying processing on the first tongue body sample to generate a second tongue body sample;
calculating a threshold value of a target pixel point according to pixel values of all pixel points in the neighborhood including the target pixel point and pixel values of the target pixel point for each pixel point in a second tongue body sample according to the size of a preset pixel point neighborhood, and comparing the threshold value with the pixel values of the target pixel points to generate a third tongue body sample;
for each pixel point in the third tongue body sample, sorting the gray values of all pixel points in the filter template including the target pixel point according to the size of the preset filter template, and giving the median of the sorted array to the target pixel point to generate a fourth tongue body sample;
according to a preset position Threshold value Location, respectively taking the upper left corners of a first R channel sample, a first G channel sample, a first B channel sample and a fourth tongue body sample as coordinate origin points, traversing the area of X belonging to [0, Width ] and Y belonging to [0, Location ] of the abscissa in the sample, judging the pixel value M _ VAL of each pixel point in the area of the fourth tongue body sample and the preset operation Threshold value Threshold, resetting the value of the corresponding pixel point in the first R channel sample, the first G channel sample and the first B channel sample according to the judgment result to generate a second R channel sample, a second G channel sample and a second B channel sample, wherein Width is the Width value of the sample image;
and combining the second R channel sample, the second G channel sample and the second B channel sample to generate a color image, and obtaining a fifth tongue body sample without teeth as a training sample for performing deep learning training on the tongue body image.
Further, the graying the first tongue sample based on the pixel values of each pixel point in the first tongue sample in the first R channel sample, the first G channel sample, and the first B channel sample, and generating the second tongue sample includes:
step 1, selecting the ith pixel point I in the first tongue samplei(x, y) determining said pixel point Ii(x, y) pixel values R in first R-channel sample, first G-channel sample, and first B-channel samplei(x,y)、Gi(x,y)、Bi(x, y), wherein the initial value of i is 1;
step 2, calculating the pixel value Ri(x,y)、Gi(x,y)、BiAverage value m of (x, y)iThe calculation formula is as follows:
mi=[Ri(x,y)+Gi(x,y)+Bi(x,y)]/3;
step 3, the average value m is calculatediAssigned to pixel point Ii(x,y);
And 4, enabling I to be I +1, returning to the step 1 when I is not more than I, and generating an image of a second tongue body sample when I is more than I, wherein I is the total number of pixel points in the first tongue body sample.
Further, the calculating, according to the size of a preset pixel neighborhood, a threshold of the target pixel for each pixel in the second tongue sample according to pixel values of all pixels in the neighborhood including the target pixel, and comparing the threshold with the pixel value of the target pixel to generate a third tongue sample includes:
step 1, selecting the ith pixel point I in the second tongue samplei(x, y), determining to include a target pixel point I according to a preset pixel point neighborhood size blocksizei(x, y) the pixel values of all pixel points in a neighborhood of which the size is blocksize × blocksize, wherein the initial value of i is 1, and the blocksize is a natural number;
step 2, according to the target pixel point I included in the pairi(x, y) calculating the pixel values of all pixel points in the neighborhood with the size of blocksize × (blocksize) to obtain the target pixel point Ii(x, y) threshold value avgiThe calculation formula is as follows:
avgi=sumi/(blocksize*blocksize)
in the formula, sumiIs composed of a target pixel point Ii(x, y) the size is the sum of pixel values of all pixels in a blocksize x blocksize neighborhood;
step 3, comparing the target pixel points IiPixel value of (x, y)iAnd a threshold value avgiDetermining the size of the target pixel point IiNew pixel value of (x, y)i', its calculation formula is:
Figure BDA0002339621040000031
and 4, enabling I to be I +1, returning to the step 1 when I is not more than I, and generating an image of the second tongue body sample when I is more than I, wherein I is the total number of pixel points in the second tongue body sample.
Further, the step of sorting the gray values of all the pixel points in the filter template including the target pixel point according to the size of the preset filter template for each pixel point in the third tongue body sample, and the step of giving the median of the sorted array to the target pixel point to generate a fourth tongue body sample includes:
when the size of the filtering template is an odd number N, the [ (N +1)/2] bits of the sorted array are used as a median value and are given to a target pixel point;
and when the size of the filtering template is an even number N, taking the arithmetic mean value of the [ N/2] th bit and [ N/2+1] th bit in the sorted array as a median value, and giving the median value to the target pixel point.
Further, according to the preset position Threshold Location, respectively taking the upper left corners of the first R channel sample, the first G channel sample, the first B channel sample and the fourth tongue sample as origin of coordinates, traversing the area of X ∈ [0, Width ], Y ∈ [0, Location ] of the abscissa in the sample, determining the pixel value M _ VAL of each pixel point in the area of the fourth tongue sample and the preset operation Threshold, and resetting the value of the corresponding pixel point in the first R channel sample, the first G channel sample and the first B channel sample according to the determination result to generate the second R channel sample, the second G channel sample and the second B channel sample includes:
step 1, selecting the ith pixel point I in the fourth tongue sample operation areai(x, y) determining said pixel point IiPixel value of (x, y)iWherein, the initial value of i is 1, the operation area takes the upper left corner of the fourth tongue sample as the origin of coordinates, and the horizontal coordinate X belongs to [0, Width ∈]The ordinate Y belongs to [0, Location ]]The area of (a);
step 2, comparing the target pixel points IiPixel value of (x, y)iAnd in advanceSetting the size of a Threshold, when a pixel point I in the operation areaiPixel value of (x, y)iWhen the value is larger than a preset operation Threshold value, pixel points I in the first R channel sample, the first G channel sample and the first B channel sample are processedi(x, y) is set to 0, wherein the first R channel sample, the first G channel sample and the first B channel sample have the same operation region as the fourth tongue sample;
and 3, enabling I to be I +1, returning to the step 1 when I is not more than I, and generating images of a second R channel sample, a second G channel sample and a second B channel sample when I is more than I, wherein I is the total number of pixel points in the fourth tongue body sample operation area.
According to another aspect of the present invention, there is provided a system for detecting a tooth region in a tongue sample, the system comprising:
the sample acquisition unit is used for acquiring a colorful tongue body image and generating a first tongue body sample;
a sample separation unit for separating the color tongue image of the first tongue sample into R, G, B three-channel images, generating a first R-channel sample, a first G-channel sample, and a first B-channel sample, respectively;
the second sample unit is used for carrying out graying processing on the first tongue body sample based on the pixel values of each pixel point in the first tongue body sample in a first R channel sample, a first G channel sample and a first B channel sample to generate a second tongue body sample;
the third sample unit is used for calculating the threshold value of the target pixel point according to the pixel values of all pixel points in the neighborhood including the target pixel point and the pixel value of the target pixel point for each pixel point in the second tongue body sample according to the size of the preset pixel point neighborhood, and comparing the threshold value with the pixel value of the target pixel point to generate a third tongue body sample;
the fourth sample unit is used for sorting the gray values of all pixel points in the filter template including the target pixel point according to the size of the preset filter template for each pixel point in the third tongue body sample, and endowing the sorted array of median values to the target pixel point to generate a fourth tongue body sample;
a fifth sample unit, configured to traverse an area with X ∈ [0, Width ] and Y ∈ [0, Location ] in the horizontal coordinates and X ∈ [0, Width ] in the sample according to a preset position Threshold Location, and determine a pixel value M _ VAL of each pixel in the area of the fourth tongue sample and a preset operation Threshold, and reset values of corresponding pixels in the first R channel sample, the first G channel sample, and the first B channel sample according to the determination result to generate a second R channel sample, a second G channel sample, and a second B channel sample, where Width is a Width value of the sample image;
and the sample synthesis unit is used for combining the second R channel sample, the second G channel sample and the second B channel sample to generate a color image, and obtaining a fifth tongue body sample without teeth as a training sample for performing deep learning training on the tongue body image.
Further, the system further comprises a parameter setting unit, which is used for setting the size of the pixel point field in the third sample unit, the size of the filtering template in the fourth sample unit, and the position threshold and the operation threshold in the fifth sample unit.
Further, the second sample unit includes:
a target selecting unit for selecting the ith pixel point I in the first tongue samplei(x, y) determining said pixel point Ii(x, y) pixel values R in first R-channel sample, first G-channel sample, and first B-channel samplei(x,y)、Gi(x,y)、Bi(x,y);
A data calculation unit for calculating the pixel value Ri(x,y)、Gi(x,y)、BiAverage value m of (x, y)iAnd after the assignment unit assigns the target pixel point, making i equal to i +1, wherein the average value m isiThe calculation formula of (2) is as follows:
mi=[Ri(x,y)+Gi(x,y)+Bi(x,y)]/3;
an evaluation unit for evaluating the mean value miAssigned to pixel point Ii(x, y), and when the target pixel point in the first tongue sample is selected for the first time, making i equal to 1;
and the sample generating unit is used for returning to the target selecting unit when I is less than or equal to I, and generating an image of a second tongue body sample when I is more than I, wherein I is the total number of pixel points in the first tongue body sample.
Further, the third sample unit includes:
a target selecting unit for selecting the ith pixel point I in the second tongue samplei(x, y), determining to include a target pixel point I according to a preset pixel point neighborhood size blocksizei(x, y) the pixel values of all pixel points in a neighborhood of which the size is blocksize × blocksize, wherein the initial value of i is 1, and the blocksize is a natural number;
a data calculation unit for calculating a target pixel point Ii(x, y) calculating the pixel values of all pixel points in the neighborhood with the size of blocksize × (blocksize) to obtain the target pixel point Ii(x, y) threshold value avgiAnd after the assignment unit assigns the target pixel point, making i equal to i +1, wherein the threshold value avgiThe calculation formula of (2) is as follows:
avgi=sumi/(blocksize*blocksize)
in the formula, sumiIs composed of a target pixel point Ii(x, y) the size is the sum of pixel values of all pixels in a blocksize x blocksize neighborhood;
an assignment unit for comparing the target pixel points IiPixel value of (x, y)iAnd a threshold value avgiDetermining the size of the target pixel point IiNew pixel value of (x, y)i' and when a target pixel point in a second tongue sample is selected for the first time, making I equal to 1, wherein the target pixel point I is determinediNew pixel value of (x, y)iThe formula for calculation of' is:
Figure BDA0002339621040000071
and the sample generating unit is used for returning to the target selecting unit when I is less than or equal to I, and generating an image of a third tongue body sample when I is more than I, wherein I is the total number of pixel points in the second tongue body sample.
Further, the fourth sample unit sorts the gray values of all pixel points in the filter template including the target pixel point according to the size of the preset filter template for each pixel point in the third tongue sample, and endowing the sorted array median values to the target pixel points to generate a fourth tongue sample includes:
when the size of the filtering template is an odd number N, the [ (N +1)/2] bits of the sorted array are used as a median value and are given to a target pixel point;
and when the size of the filtering template is an even number N, taking the arithmetic mean value of the [ N/2] th bit and [ N/2+1] th bit in the sorted array as a median value, and giving the median value to the target pixel point.
Further, the fifth sample unit includes:
a target selecting unit for selecting the ith pixel point I in the fourth tongue sample operation regioni(x, y) determining said pixel point IiPixel value of (x, y)iWherein the operation area takes the upper left corner of the fourth tongue body sample as the origin of coordinates, and the X of the horizontal coordinate belongs to [0, Width ∈]The ordinate Y belongs to [0, Location ]]The area of (a);
an assignment unit for comparing the target pixel points IiPixel value of (x, y)iAnd the size of a preset operation Threshold value is compared with the size of the preset operation Threshold value, and when the pixel point I in the operation areaiPixel value of (x, y)iWhen the value is larger than a preset operation Threshold value, pixel points I in the first R channel sample, the first G channel sample and the first B channel sample are processedi(x, y) is set to 0, and when the target pixel in the fourth tongue sample is selected for the first time, i is set to 1, and the second time is selectedWhen a target pixel point in a fourth tongue sample is selected, i is equal to i +1 every time, wherein the first R channel sample, the first G channel sample and the first B channel sample have the same operation region as the fourth tongue sample;
and the sample generating unit is used for returning to the target selecting unit when I is less than or equal to I, and generating images of a second R channel sample, a second G channel sample and a second B channel sample when I is more than I, wherein I is the total number of pixel points in the fourth tongue body sample operation area.
According to the method and the system for detecting the tooth area in the tongue sample, provided by the technical scheme, the tooth area in the tongue is segmented based on the threshold value, firstly, a colorful tongue image is collected to generate a first tongue sample, the image is grayed in an RGB color space, and a second tongue sample is generated; then, processing the grayed image by utilizing local self-adaptive binarization to obtain a third tongue sample; denoising the image by adopting a median filtering method to obtain a fourth tongue sample; and finally, respectively carrying out threshold processing on a first R channel sample, a first G channel sample and a first B channel sample generated by separating the first tongue sample by adopting a fourth tongue sample to generate a second R channel sample, a second G channel sample and a second B channel sample, and finally combining the second R channel sample, the second G channel sample and the second B channel sample to obtain the tongue sample after the teeth are filtered. According to the method and the system for detecting the tooth area in the tongue sample, the acquired tongue sample of the color image is subjected to gray processing, so that the calculated amount is reduced, the efficiency is high, the quality of the obtained tongue sample is high, and a good foundation is laid for a later tongue feature analysis algorithm.
Drawings
A more complete understanding of exemplary embodiments of the present invention may be had by reference to the following drawings in which:
FIG. 1 is a flow chart of a method of detecting tooth regions in a tongue sample according to a preferred embodiment of the present invention;
fig. 2 is a schematic structural view of a system for detecting a tooth region in a tongue sample according to a preferred embodiment of the present invention.
Detailed Description
The exemplary embodiments of the present invention will now be described with reference to the accompanying drawings, however, the present invention may be embodied in many different forms and is not limited to the embodiments described herein, which are provided for complete and complete disclosure of the present invention and to fully convey the scope of the present invention to those skilled in the art. The terminology used in the exemplary embodiments illustrated in the accompanying drawings is not intended to be limiting of the invention. In the drawings, the same units/elements are denoted by the same reference numerals.
Unless otherwise defined, terms (including technical and scientific terms) used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this invention belongs. Further, it will be understood that terms, such as those defined in commonly used dictionaries, should be interpreted as having a meaning that is consistent with their meaning in the context of the relevant art and will not be interpreted in an idealized or overly formal sense.
FIG. 1 is a flow chart of a method of detecting a tooth region in a tongue sample according to a preferred embodiment of the present invention. As shown in FIG. 1, the method 100 for detecting a tooth region in a tongue sample according to the preferred embodiment begins at step 101.
In step 101, a color tongue image is acquired, and a first tongue sample is generated.
At step 102, the color tongue image of the first tongue sample is separated into R, G, B three-channel images, yielding a first R-channel sample, a first G-channel sample, and a first B-channel sample, respectively.
In step 103, based on the pixel values of each pixel point in the first tongue sample in the first R channel sample, the first G channel sample, and the first B channel sample, the first tongue sample is grayed to generate a second tongue sample.
The gray processing is carried out on the colored first tongue body sample, and the color image is converted into a gray image, so that the calculation amount of the method is greatly reduced.
In step 104, for each pixel point in the second tongue sample, according to the size of a preset pixel point neighborhood, calculating a threshold value of the target pixel point according to pixel values of all pixel points in the neighborhood including the target pixel point, and comparing the threshold value with the pixel value of the target pixel point to generate a third tongue sample.
Due to the influence of illumination, the gray scale of the image may not be uniformly distributed, and the effect obtained by the segmentation method using the single threshold is not good, so that the gray scale of the gray scale image can be more uniformly distributed by further processing the gray scale image using the adaptive threshold method in step 104.
In step 105, for each pixel point in the third tongue sample, the gray values of all pixel points in the filter template including the target pixel point are sorted according to the size of the preset filter template, and the median of the sorted array is assigned to the target pixel point to generate a fourth tongue sample.
Through median filtering, the pixel value around each pixel point can be closer to the true value, and therefore isolated noise points in the tongue sample are eliminated.
In step 106, according to a preset position Threshold Location, respectively taking the upper left corners of a first R channel sample, a first G channel sample, a first B channel sample and a fourth tongue sample as origin of coordinates, traversing the area of X ∈ [0, Width ] and Y ∈ [0, Location ] of the abscissa in the sample, judging the pixel value M _ VAL of each pixel point in the area of the fourth tongue sample and the size of a preset operation Threshold, and resetting the values of the corresponding pixel points in the first R channel sample, the first G channel sample and the first B channel sample according to the judgment result to generate a second R channel sample, a second G channel sample and a second B channel sample, wherein Width is the Width value of the sample image;
in step 107, the second R channel sample, the second G channel sample, and the second B channel sample are combined to generate a color image, and a fifth tongue sample without teeth is obtained as a training sample for performing deep learning training on the tongue image.
Preferably, the graying the first tongue sample based on the pixel values of each pixel point in the first tongue sample in the first R channel sample, the first G channel sample, and the first B channel sample, and generating the second tongue sample includes:
step 1, selecting the ith pixel point I in the first tongue samplei(x, y) determining said pixel point Ii(x, y) pixel values R in first R-channel sample, first G-channel sample, and first B-channel samplei(x,y)、Gi(x,y)、Bi(x, y), wherein the initial value of i is 1;
step 2, calculating the pixel value Ri(x,y)、Gi(x,y)、BiAverage value m of (x, y)iThe calculation formula is as follows:
mi=[Ri(x,y)+Gi(x,y)+Bi(x,y)]/3;
step 3, the average value m is calculatediAssigned to pixel point Ii(x,y);
And 4, enabling I to be I +1, returning to the step 1 when I is not more than I, and generating an image of a second tongue body sample when I is more than I, wherein I is the total number of pixel points in the first tongue body sample.
Preferably, the calculating, according to a preset size of a neighborhood of pixel points, a threshold of the target pixel point for each pixel point in the second tongue sample according to pixel values of all pixel points in the neighborhood including the target pixel point, and comparing the threshold with the pixel value of the target pixel point to generate a third tongue sample includes:
step 1, selecting the ith pixel point I in the second tongue samplei(x, y), determining to include a target pixel point I according to a preset pixel point neighborhood size blocksizei(x, y) the pixel values of all pixel points in a neighborhood of which the size is blocksize × blocksize, wherein the initial value of i is 1, and the blocksize is a natural number;
step 2, according to the target pixel point I included in the pairi(x, y) calculating the pixel values of all pixel points in the neighborhood with the size of blocksize × (blocksize) to obtain the target pixel point Ii(x, y) threshold value avgiThe calculation formula is as follows:
avgi=sumi/(blocksize*blocksize)
in the formula, sumiIs composed of a target pixel point Ii(x, y) the size is the sum of pixel values of all pixels in a blocksize x blocksize neighborhood;
step 3, comparing the target pixel points IiPixel value of (x, y)iAnd a threshold value avgiDetermining the size of the target pixel point IiNew pixel value of (x, y)'iThe calculation formula is as follows:
Figure BDA0002339621040000111
and 4, enabling I to be I +1, returning to the step 1 when I is not more than I, and generating an image of the second tongue body sample when I is more than I, wherein I is the total number of pixel points in the second tongue body sample.
In this embodiment, if blocksize is 3, the neighborhood of the pixel I (x, y) is as shown in table 1.
TABLE 1 Pixel Point fields
I(x-1,y-1) I(x-1,y) I(x-1,y+1)
I(x,y-1) I(x,y) I(x,y+1)
I(x+1,y-1) I(x+1,y) I(x+1,y+1)
Then there is
sum=I(x-1,y-1)+I(x-1,y)+…+I(x+1,y)+I(x+1,y+1)avg=sum/3*3。
Preferably, the sorting gray values of all pixel points in the filter template including the target pixel point according to the size of a preset filter template for each pixel point in the third tongue body sample, and assigning the median of the sorted array to the target pixel point to generate the fourth tongue body sample includes:
when the size of the filtering template is an odd number N, the [ (N +1)/2] bits of the sorted array are used as a median value and are given to a target pixel point;
and when the size of the filtering template is an even number N, taking the arithmetic mean value of the [ N/2] th bit and [ N/2+1] th bit in the sorted array as a median value, and giving the median value to the target pixel point.
Preferably, according to the preset position Threshold Location, respectively taking the upper left corners of the first R channel sample, the first G channel sample, the first B channel sample, and the fourth tongue sample as origin of coordinates, traversing the area of X ∈ [0, Width ] and Y ∈ [0, Location ] of the abscissa in the sample, determining the pixel value M _ VAL of each pixel point in the area of the fourth tongue sample and the size of the preset operation Threshold, and resetting the values of the corresponding pixel points in the first R channel sample, the first G channel sample, and the first B channel sample according to the determination result to generate the second R channel sample, the second G channel sample, and the second B channel sample includes:
step 1, selecting the ith pixel point I in the fourth tongue sample operation areai(x, y) determining said pixel point IiPixel value of (x, y)iWherein, the initial value of i is 1, the operation area takes the upper left corner of the fourth tongue sample as the origin of coordinates, and the horizontal coordinate X belongs to [0, Width ∈]The ordinate Y belongs to [0, Location ]]The area of (a);
step 2, comparing the target pixel points IiPixel value of (x, y)iAnd the size of a preset operation Threshold value is compared with the size of the preset operation Threshold value, and when the pixel point I in the operation areai(x, y) ofPixel valueiWhen the value is larger than a preset operation Threshold value, pixel points I in the first R channel sample, the first G channel sample and the first B channel sample are processedi(x, y) is set to 0, wherein the first R channel sample, the first G channel sample and the first B channel sample have the same operation region as the fourth tongue sample;
and 3, enabling I to be I +1, returning to the step 1 when I is not more than I, and generating images of a second R channel sample, a second G channel sample and a second B channel sample when I is more than I, wherein I is the total number of pixel points in the fourth tongue body sample operation area.
Fig. 2 is a schematic structural view of a system for detecting a tooth region in a tongue sample according to a preferred embodiment of the present invention. As shown in fig. 2, the system 200 for detecting a tooth region in a tongue sample according to the preferred embodiment includes:
and the parameter setting unit 201 is configured to set a pixel point domain size in the third sample unit, a filter template size in the fourth sample unit, and a position threshold and an operation threshold in the fifth sample unit.
And the sample acquisition unit 202 is used for acquiring a color tongue body image and generating a first tongue body sample.
A sample separation unit 203 for separating the color tongue image of the first tongue sample into R, G, B three-channel images, generating a first R-channel sample, a first G-channel sample, and a first B-channel sample, respectively.
A second sample unit 204, configured to perform graying processing on the first tongue sample based on pixel values of each pixel point in the first tongue sample in a first R channel sample, a first G channel sample, and a first B channel sample, so as to generate a second tongue sample.
A third sample unit 205, configured to calculate, for each pixel in the second tongue sample, a threshold of the target pixel according to pixel values of all pixels in a neighborhood including the target pixel according to a preset size of a pixel neighborhood, and compare the threshold with the pixel value of the target pixel to generate a third tongue sample;
a fourth sample unit 206, configured to sort, according to a preset size of a filter template, gray values of all pixel points in the filter template including a target pixel point for each pixel point in the third tongue sample, and assign a median value of the sorted array to the target pixel point to generate a fourth tongue sample;
a fifth sample unit 207, configured to use the upper left corners of the first R channel sample, the first G channel sample, the first B channel sample, and the fourth tongue sample as coordinate origins respectively according to a preset position Threshold Location, traverse an area of X ∈ [0, Width ], Y ∈ [0, Location ] of the abscissa in the sample, determine the size of the pixel value M _ VAL of each pixel point in the area of the fourth tongue sample and a preset operation Threshold, and reset the values of corresponding pixel points in the first R channel sample, the first G channel sample, and the first B channel sample according to the determination result to generate a second R channel sample, a second G channel sample, and a second B channel sample, where Width is a Width value of the sample image;
and a sample synthesis unit 208, configured to combine the second R channel sample, the second G channel sample, and the second B channel sample to generate a color image, and obtain a fifth tongue sample without teeth as a training sample for performing deep learning training on the tongue image.
Preferably, the second sample unit 204 comprises:
a target selecting unit 241 for selecting the ith pixel point I in the first tongue samplei(x, y) determining said pixel point Ii(x, y) pixel values R in first R-channel sample, first G-channel sample, and first B-channel samplei(x,y)、Gi(x,y)、Bi(x,y);
A data calculation unit 242 for calculating the pixel value Ri(x,y)、Gi(x,y)、BiAverage value m of (x, y)iAnd after the assignment unit assigns the target pixel point, making i equal to i +1, wherein the average value m isiThe calculation formula of (2) is as follows:
mi=[Ri(x,y)+Gi(x,y)+Bi(x,y)]/3;
an assigning unit 243 for assigning the average value miAssigned to pixel point Ii(x, y), and when the target pixel point in the first tongue sample is selected for the first time, making i equal to 1;
and the sample generating unit 244 is used for returning to the target selecting unit when I is less than or equal to I, and generating an image of the second tongue sample when I is greater than I, wherein I is the total number of the pixel points in the first tongue sample.
Preferably, the third sample unit 205 comprises:
a target selecting unit 251 for selecting the ith pixel point I in the second tongue samplei(x, y), determining to include a target pixel point I according to a preset pixel point neighborhood size blocksizei(x, y) the pixel values of all pixel points in a neighborhood of which the size is blocksize × blocksize, wherein the initial value of i is 1, and the blocksize is a natural number;
a data calculating unit 252 for calculating a target pixel point I according to the pixel pairi(x, y) calculating the pixel values of all pixel points in the neighborhood with the size of blocksize × (blocksize) to obtain the target pixel point Ii(x, y) threshold value avgiAnd after the assignment unit assigns the target pixel point, making i equal to i +1, wherein the threshold value avgiThe calculation formula of (2) is as follows:
avgi=sumi/(blocksize*blocksize)
in the formula, sumiIs composed of a target pixel point Ii(x, y) the size is the sum of pixel values of all pixels in a blocksize x blocksize neighborhood;
an assigning unit 253 for comparing the target pixel point IiPixel value of (x, y)iAnd a threshold value avgiDetermining the size of the target pixel point IiNew pixel value of (x, y)'iAnd when the target pixel point in the second tongue body sample is selected for the first time, making I equal to 1, wherein the target pixel point I is determinediNew pixel value of (x, y)'iThe calculation formula of (2) is as follows:
Figure BDA0002339621040000151
and the sample generating unit 254 is used for returning to the target selecting unit when I is less than or equal to I, and generating an image of a third tongue sample when I is greater than I, wherein I is the total number of pixel points in the second tongue sample.
Preferably, the fourth sample unit 206 ranks, according to a preset size of a filter template, the gray values of all pixel points in the filter template including the target pixel point for each pixel point in the third tongue sample, and assigns a median value of the ranked array to the target pixel point to generate the fourth tongue sample, where the ranking includes:
when the size of the filtering template is an odd number N, the [ (N +1)/2] bits of the sorted array are used as a median value and are given to a target pixel point;
and when the size of the filtering template is an even number N, taking the arithmetic mean value of the [ N/2] th bit and [ N/2+1] th bit in the sorted array as a median value, and giving the median value to the target pixel point.
Preferably, the fifth sample unit 207 includes:
a target selecting unit 271 for selecting the ith pixel point I in the fourth tongue sample operating regioni(x, y) determining said pixel point IiPixel value of (x, y)iWherein the operation area takes the upper left corner of the fourth tongue body sample as the origin of coordinates, and the X of the horizontal coordinate belongs to [0, Width ∈]The ordinate Y belongs to [0, Location ]]The area of (a);
an assignment unit 272 for comparing the target pixel points IiPixel value of (x, y)iAnd the size of a preset operation Threshold value is compared with the size of the preset operation Threshold value, and when the pixel point I in the operation areaiPixel value of (x, y)iWhen the value is larger than a preset operation Threshold value, pixel points I in the first R channel sample, the first G channel sample and the first B channel sample are processedi(x, y) is set to 0, and when the target pixel in the fourth tongue sample is selected for the first time, let i equal to 1, from the secondWhen a target pixel point in a fourth tongue sample is selected, i is made to be i +1 every time, wherein the first R channel sample, the first G channel sample and the first B channel sample have the same operation area as the fourth tongue sample;
and a sample generating unit 273, configured to return to the target selecting unit when I is not greater than I, and generate images of a second R channel sample, a second G channel sample, and a second B channel sample when I is greater than I, where I is the total number of pixels in the fourth tongue sample operation region.
The steps of detecting the tooth region in the tongue sample by the system for detecting the tooth region in the tongue sample are the same as the steps in the method for detecting the tooth region in the tongue sample, and the technical effects are the same, which are not described herein again.
The invention has been described with reference to a few embodiments. However, other embodiments of the invention than the one disclosed above are equally possible within the scope of the invention, as would be apparent to a person skilled in the art from the appended patent claims.
Generally, all terms used in the claims are to be interpreted according to their ordinary meaning in the technical field, unless explicitly defined otherwise herein. All references to "a/an/the [ device, component, etc ]" are to be interpreted openly as referring to at least one instance of said device, component, etc., unless explicitly stated otherwise. The steps of any method disclosed herein do not have to be performed in the exact order disclosed, unless explicitly stated.
As will be appreciated by one skilled in the art, embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The present application is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the application. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
Finally, it should be noted that: the above embodiments are only for illustrating the technical solutions of the present invention and not for limiting the same, and although the present invention is described in detail with reference to the above embodiments, those of ordinary skill in the art should understand that: modifications and equivalents may be made to the embodiments of the invention without departing from the spirit and scope of the invention, which is to be covered by the claims.

Claims (11)

1. A method of detecting a tooth region in a tongue sample, the method comprising:
collecting a colorful tongue body image to generate a first tongue body sample;
separating the color tongue image of the first tongue sample into R, G, B three-channel images, generating a first R-channel sample, a first G-channel sample and a first B-channel sample, respectively;
based on the pixel values of each pixel point in the first tongue body sample in a first R channel sample, a first G channel sample and a first B channel sample, carrying out graying processing on the first tongue body sample to generate a second tongue body sample;
calculating a threshold value of a target pixel point according to pixel values of all pixel points in the neighborhood including the target pixel point and pixel values of the target pixel point for each pixel point in a second tongue body sample according to the size of a preset pixel point neighborhood, and comparing the threshold value with the pixel values of the target pixel points to generate a third tongue body sample;
for each pixel point in the third tongue body sample, sorting the gray values of all pixel points in the filter template including the target pixel point according to the size of the preset filter template, and giving the median of the sorted array to the target pixel point to generate a fourth tongue body sample;
according to a preset position Threshold value Location, respectively taking the upper left corners of a first R channel sample, a first G channel sample, a first B channel sample and a fourth tongue body sample as coordinate origin points, traversing the area of X belonging to [0, Width ] and Y belonging to [0, Location ] of the abscissa in the sample, judging the pixel value M _ VAL of each pixel point in the area of the fourth tongue body sample and the preset operation Threshold value Threshold, resetting the value of the corresponding pixel point in the first R channel sample, the first G channel sample and the first B channel sample according to the judgment result to generate a second R channel sample, a second G channel sample and a second B channel sample, wherein Width is the Width value of the sample image;
and combining the second R channel sample, the second G channel sample and the second B channel sample to generate a color image, and obtaining a fifth tongue body sample without teeth as a training sample for performing deep learning training on the tongue body image.
2. The method of claim 1, wherein the graying the first tongue body sample based on the pixel values of each pixel point in the first tongue body sample in a first R channel sample, a first G channel sample, and a first B channel sample to generate a second tongue body sample comprises:
step 1, selecting the ith pixel point I in the first tongue samplei(x, y) determining said pixel point Ii(x, y) pixel values R in first R-channel sample, first G-channel sample, and first B-channel samplei(x,y)、Gi(x,y)、Bi(x, y), wherein the initial value of i is 1;
step 2, calculating the pixel value Ri(x,y)、Gi(x,y)、BiAverage value m of (x, y)iThe calculation formula is as follows:
mi=[Ri(x,y)+Gi(x,y)+Bi(x,y)]/3;
step 3, the average value m is calculatediAssigned to pixel point Ii(x,y);
And 4, enabling I to be I +1, returning to the step 1 when I is not more than I, and generating an image of a second tongue body sample when I is more than I, wherein I is the total number of pixel points in the first tongue body sample.
3. The method of claim 1, wherein the calculating, for each pixel in the second tongue sample, a threshold of the target pixel according to a preset size of a neighborhood of pixels, based on pixel values of all pixels in the neighborhood including the target pixel, and comparing the threshold with the pixel value of the target pixel to generate a third tongue sample comprises:
step 1, selecting the ith pixel point I in the second tongue samplei(x, y), determining to include the target image according to the preset pixel point neighborhood size blocksizePrime point Ii(x, y) the pixel values of all pixel points in a neighborhood of which the size is blocksize × blocksize, wherein the initial value of i is 1, and the blocksize is a natural number;
step 2, according to the target pixel point I included in the pairi(x, y) calculating the pixel values of all pixel points in the neighborhood with the size of blocksize × (blocksize) to obtain the target pixel point Ii(x, y) threshold value avgiThe calculation formula is as follows:
avgi=sumi/(blocksize*blocksize)
in the formula, sumiIs composed of a target pixel point Ii(x, y) the size is the sum of pixel values of all pixels in a blocksize x blocksize neighborhood;
step 3, comparing the target pixel points IiPixel value of (x, y)iAnd a threshold value avgiDetermining the size of the target pixel point IiNew pixel value of (x, y)'iThe calculation formula is as follows:
Figure FDA0002339621030000031
and 4, enabling I to be I +1, returning to the step 1 when I is not more than I, and generating an image of the second tongue body sample when I is more than I, wherein I is the total number of pixel points in the second tongue body sample.
4. The method according to claim 1, wherein the step of sorting the gray values of all the pixels in the filter template including the target pixel according to the preset size of the filter template for each pixel in the third tongue sample, and the step of assigning the sorted array of median values to the target pixel to generate the fourth tongue sample comprises:
when the size of the filtering template is an odd number N, the [ (N +1)/2] bits of the sorted array are used as a median value and are given to a target pixel point;
and when the size of the filtering template is an even number N, taking the arithmetic mean value of the [ N/2] th bit and [ N/2+1] th bit in the sorted array as a median value, and giving the median value to the target pixel point.
5. The method of claim 1, wherein the step of traversing a region of X e [0, Width ], Y e [0, Location ] and Y e [0, Location ] in the samples by using upper left corners of the first R channel sample, the first G channel sample, the first B channel sample and the fourth tongue sample as coordinate origins respectively according to a preset position Threshold Location, the step of judging the size of the pixel value M _ VAL of each pixel point in the region of the fourth tongue sample and a preset operation Threshold, and the step of resetting the values of the corresponding pixel points in the first R channel sample, the first G channel sample and the first B channel sample according to the judgment result to generate a second R channel sample, a second G channel sample and a second B channel sample comprises:
step 1, selecting the ith pixel point I in the fourth tongue sample operation areai(x, y) determining said pixel point IiPixel value of (x, y)iWherein, the initial value of i is 1, the operation area takes the upper left corner of the fourth tongue sample as the origin of coordinates, and the horizontal coordinate X belongs to [0, Width ∈]The ordinate Y belongs to [0, Location ]]The area of (a);
step 2, comparing the target pixel points IiPixel value of (x, y)iAnd the size of a preset operation Threshold value is compared with the size of the preset operation Threshold value, and when the pixel point I in the operation areaiPixel value of (x, y)iWhen the value is larger than a preset operation Threshold value, pixel points I in the first R channel sample, the first G channel sample and the first B channel sample are processedi(x, y) is set to 0, wherein the first R channel sample, the first G channel sample and the first B channel sample have the same operation region as the fourth tongue sample;
and 3, enabling I to be I +1, returning to the step 1 when I is not more than I, and generating images of a second R channel sample, a second G channel sample and a second B channel sample when I is more than I, wherein I is the total number of pixel points in the fourth tongue body sample operation area.
6. A system for detecting a tooth region in a tongue sample, the system comprising:
the sample acquisition unit is used for acquiring a colorful tongue body image and generating a first tongue body sample;
a sample separation unit for separating the color tongue image of the first tongue sample into R, G, B three-channel images, generating a first R-channel sample, a first G-channel sample, and a first B-channel sample, respectively;
the second sample unit is used for carrying out graying processing on the first tongue body sample based on the pixel values of each pixel point in the first tongue body sample in a first R channel sample, a first G channel sample and a first B channel sample to generate a second tongue body sample;
the third sample unit is used for calculating the threshold value of the target pixel point according to the pixel values of all pixel points in the neighborhood including the target pixel point and the pixel value of the target pixel point for each pixel point in the second tongue body sample according to the size of the preset pixel point neighborhood, and comparing the threshold value with the pixel value of the target pixel point to generate a third tongue body sample;
the fourth sample unit is used for sorting the gray values of all pixel points in the filter template including the target pixel point according to the size of the preset filter template for each pixel point in the third tongue body sample, and endowing the sorted array of median values to the target pixel point to generate a fourth tongue body sample;
a fifth sample unit, configured to traverse an area with X ∈ [0, Width ] and Y ∈ [0, Location ] in the horizontal coordinates and X ∈ [0, Width ] in the sample according to a preset position Threshold Location, and determine a pixel value M _ VAL of each pixel in the area of the fourth tongue sample and a preset operation Threshold, and reset values of corresponding pixels in the first R channel sample, the first G channel sample, and the first B channel sample according to the determination result to generate a second R channel sample, a second G channel sample, and a second B channel sample, where Width is a Width value of the sample image;
and the sample synthesis unit is used for combining the second R channel sample, the second G channel sample and the second B channel sample to generate a color image, and obtaining a fifth tongue body sample without teeth as a training sample for performing deep learning training on the tongue body image.
7. The system according to claim 6, further comprising a parameter setting unit for setting a pixel region size in a third sample unit, a filter template size in a fourth sample unit, and a position threshold and an operation threshold in a fifth sample unit.
8. The system of claim 7, wherein the second sample unit comprises:
a target selecting unit for selecting the ith pixel point I in the first tongue samplei(x, y) determining said pixel point Ii(x, y) pixel values R in first R-channel sample, first G-channel sample, and first B-channel samplei(x,y)、Gi(x,y)、Bi(x,y);
A data calculation unit for calculating the pixel value Ri(x,y)、Gi(x,y)、BiAverage value m of (x, y)iAnd after the assignment unit assigns the target pixel point, making i equal to i +1, wherein the average value m isiThe calculation formula of (2) is as follows:
mi=[Ri(x,y)+Gi(x,y)+Bi(x,y)]/3;
an evaluation unit for evaluating the mean value miAssigned to pixel point Ii(x, y), and when the target pixel point in the first tongue sample is selected for the first time, making i equal to 1;
and the sample generating unit is used for returning to the target selecting unit when I is less than or equal to I, and generating an image of a second tongue body sample when I is more than I, wherein I is the total number of pixel points in the first tongue body sample.
9. The method of claim 7, wherein the third sample unit comprises:
a target selecting unit for selecting the ith pixel point I in the second tongue samplei(x, y), determining to include a target pixel point I according to a preset pixel point neighborhood size blocksizei(x, y) the pixel values of all pixel points in a neighborhood of which the size is blocksize × blocksize, wherein the initial value of i is 1, and the blocksize is a natural number;
a data calculation unit for calculating a target pixel point Ii(x, y) calculating the pixel values of all pixel points in the neighborhood with the size of blocksize × (blocksize) to obtain the target pixel point Ii(x, y) threshold value avgiAnd after the assignment unit assigns the target pixel point, making i equal to i +1, wherein the threshold value avgiThe calculation formula of (2) is as follows:
avgi=sumi/(blocksize*blocksize)
in the formula, sumiIs composed of a target pixel point Ii(x, y) the size is the sum of pixel values of all pixels in a blocksize x blocksize neighborhood;
an assignment unit for comparing the target pixel points IiPixel value of (x, y)iAnd a threshold value avgiDetermining the size of the target pixel point IiNew pixel value of (x, y)'iAnd when the target pixel point in the second tongue body sample is selected for the first time, making I equal to 1, wherein the target pixel point I is determinediNew pixel value of (x, y)'iThe calculation formula of (2) is as follows:
Figure FDA0002339621030000071
and the sample generating unit is used for returning to the target selecting unit when I is less than or equal to I, and generating an image of a third tongue body sample when I is more than I, wherein I is the total number of pixel points in the second tongue body sample.
10. The system of claim 6, wherein the fourth sample unit sorts, according to a preset size of the filter template, the gray values of all the pixels in the filter template including the target pixel for each pixel in the third tongue sample, and assigns the median of the sorted array to the target pixel to generate the fourth tongue sample comprises:
when the size of the filtering template is an odd number N, the [ (N +1)/2] bits of the sorted array are used as a median value and are given to a target pixel point;
and when the size of the filtering template is an even number N, taking the arithmetic mean value of the [ N/2] th bit and [ N/2+1] th bit in the sorted array as a median value, and giving the median value to the target pixel point.
11. The system of claim 7, wherein the fifth sample cell comprises:
a target selecting unit for selecting the ith pixel point I in the fourth tongue sample operation regioni(x, y) determining said pixel point IiPixel value of (x, y)iWherein the operation area takes the upper left corner of the fourth tongue body sample as the origin of coordinates, and the X of the horizontal coordinate belongs to [0, Width ∈]The ordinate Y belongs to [0, Location ]]The area of (a);
an assignment unit for comparing the target pixel points IiPixel value of (x, y)iAnd the size of a preset operation Threshold value is compared with the size of the preset operation Threshold value, and when the pixel point I in the operation areaiPixel value of (x, y)iWhen the value is larger than a preset operation Threshold value, pixel points I in the first R channel sample, the first G channel sample and the first B channel sample are processediSetting the pixel value of (x, y) to 0, and when the target pixel point in the fourth tongue sample is selected for the first time, setting i to 1, and when the target pixel point in the fourth tongue sample is selected for the second time, setting i to i +1 every time, wherein the first R channel sample, the first G channel sample and the first B channel sample have the same operation area as the fourth tongue sample;
and the sample generating unit is used for returning to the target selecting unit when I is less than or equal to I, and generating images of a second R channel sample, a second G channel sample and a second B channel sample when I is more than I, wherein I is the total number of pixel points in the fourth tongue body sample operation area.
CN201911370857.1A 2019-12-26 2019-12-26 Method and system for detecting tooth area in tongue sample Active CN111242968B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201911370857.1A CN111242968B (en) 2019-12-26 2019-12-26 Method and system for detecting tooth area in tongue sample

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201911370857.1A CN111242968B (en) 2019-12-26 2019-12-26 Method and system for detecting tooth area in tongue sample

Publications (2)

Publication Number Publication Date
CN111242968A true CN111242968A (en) 2020-06-05
CN111242968B CN111242968B (en) 2024-03-26

Family

ID=70871546

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201911370857.1A Active CN111242968B (en) 2019-12-26 2019-12-26 Method and system for detecting tooth area in tongue sample

Country Status (1)

Country Link
CN (1) CN111242968B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112489053A (en) * 2020-11-26 2021-03-12 深圳市艾合芯科智慧医疗有限公司 Tongue image segmentation method and device and storage medium

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050244794A1 (en) * 2004-04-30 2005-11-03 Kemp James H Computer-implemented system and method for automated and highly accurate plaque analysis, reporting, and visualization
US20110212420A1 (en) * 2010-02-26 2011-09-01 Vuillemot William C Method for dental restoration and related kit
CN107679508A (en) * 2017-10-17 2018-02-09 广州汽车集团股份有限公司 Road traffic sign detection recognition methods, apparatus and system
CN109816629A (en) * 2018-12-20 2019-05-28 新绎健康科技有限公司 A kind of coating nature separation method and device based on k-means cluster
CN109886983A (en) * 2018-12-27 2019-06-14 新绎健康科技有限公司 A kind of image tongue body dividing method, device and computer equipment
CN110120042A (en) * 2019-05-13 2019-08-13 哈尔滨工业大学 A kind of crop map based on SLIC super-pixel and automatic threshold segmentation is as pest and disease damage method for extracting region

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050244794A1 (en) * 2004-04-30 2005-11-03 Kemp James H Computer-implemented system and method for automated and highly accurate plaque analysis, reporting, and visualization
US20110212420A1 (en) * 2010-02-26 2011-09-01 Vuillemot William C Method for dental restoration and related kit
CN107679508A (en) * 2017-10-17 2018-02-09 广州汽车集团股份有限公司 Road traffic sign detection recognition methods, apparatus and system
CN109816629A (en) * 2018-12-20 2019-05-28 新绎健康科技有限公司 A kind of coating nature separation method and device based on k-means cluster
CN109886983A (en) * 2018-12-27 2019-06-14 新绎健康科技有限公司 A kind of image tongue body dividing method, device and computer equipment
CN110120042A (en) * 2019-05-13 2019-08-13 哈尔滨工业大学 A kind of crop map based on SLIC super-pixel and automatic threshold segmentation is as pest and disease damage method for extracting region

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112489053A (en) * 2020-11-26 2021-03-12 深圳市艾合芯科智慧医疗有限公司 Tongue image segmentation method and device and storage medium
CN112489053B (en) * 2020-11-26 2021-07-13 深圳市艾合芯科智慧医疗有限公司 Tongue image segmentation method and device and storage medium

Also Published As

Publication number Publication date
CN111242968B (en) 2024-03-26

Similar Documents

Publication Publication Date Title
CN104990925B (en) One kind is based on gradient multi thresholds optimization defect inspection method
CN109344874A (en) A kind of automatic chromosome analysis method and system based on deep learning
CN108022233A (en) A kind of edge of work extracting method based on modified Canny operators
CN107292310A (en) A kind of circular pointer dial plate vision positioning and automatic reading method
CN107004265A (en) Information processor, the method for processing information, discriminator generating means, the method and program for generating discriminator
CN108447050A (en) A kind of Surface Flaw dividing method based on super-pixel
CN115345876B (en) Bolt thread defect detection method based on ultrasonic image
CN108648184A (en) A kind of detection method of remote sensing images high-altitude cirrus
CN103778611A (en) Switch weighting vector median filter method utilizing edge detection
CN111161237A (en) Fruit and vegetable surface quality detection method, storage medium and sorting device thereof
CN108090492B (en) Contour detection method based on scale clue suppression
CN114820625A (en) Automobile top block defect detection method
CN114332081B (en) Textile surface abnormity determination method based on image processing
CN106504261A (en) A kind of image partition method and device
CN111242968B (en) Method and system for detecting tooth area in tongue sample
CN111639555B (en) Finger vein image noise accurate extraction and adaptive filtering denoising method and device
CN115937085B (en) Nuclear cataract image processing method based on neural network learning
JPH07198714A (en) Method and device for discriminating activity of cell
CN104156956B (en) A kind of multicorner edge detection operator method recognized based on Gauss wavelet one-dimensional peak value
CN109902749A (en) A kind of print recognition methods of shoes and system
WO2019181072A1 (en) Image processing method, computer program, and recording medium
CN110634124A (en) Method and equipment for area detection
CN104063874A (en) Method for quantitatively evaluating gray level image binarization algorithms based on weight model
CN110570437B (en) Electric power channel automatic inspection data processing method based on boundary identification
JP2021156879A (en) Fracture surface analysis device, fracture surface analysis method, and machine learning data set generation method

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
GR01 Patent grant
GR01 Patent grant