CN101299242A - Method and device for determining threshold value in human body skin tone detection - Google Patents

Method and device for determining threshold value in human body skin tone detection Download PDF

Info

Publication number
CN101299242A
CN101299242A CNA2008101108554A CN200810110855A CN101299242A CN 101299242 A CN101299242 A CN 101299242A CN A2008101108554 A CNA2008101108554 A CN A2008101108554A CN 200810110855 A CN200810110855 A CN 200810110855A CN 101299242 A CN101299242 A CN 101299242A
Authority
CN
China
Prior art keywords
skin color
color probability
valley point
threshold value
skin
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
CNA2008101108554A
Other languages
Chinese (zh)
Other versions
CN101299242B (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.)
Tencent Cloud Computing Beijing Co Ltd
Original Assignee
Tencent Technology Shenzhen 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 Tencent Technology Shenzhen Co Ltd filed Critical Tencent Technology Shenzhen Co Ltd
Priority to CN2008101108554A priority Critical patent/CN101299242B/en
Publication of CN101299242A publication Critical patent/CN101299242A/en
Application granted granted Critical
Publication of CN101299242B publication Critical patent/CN101299242B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Image Analysis (AREA)

Abstract

The invention discloses a threshold value determining method and apparatus in the human body skin tone testing, which acquires the corresponding skin tone probabilistic image of the image to be tested. The method includes: acquiring smooth skin tone probability distribution column diagram according to the skin tone probabilistic image; acquiring the peak point and valley point in the smooth skin tone probability distribution column diagram; determining the threshold value in the human body skin tone testing according to the acquired peak point and valley point. Adoption of the invention can improve human body skin tone testing accuracy.

Description

Threshold value determination method and device in a kind of human body skin tone testing
Technical field
The present invention relates to area of pattern recognition, relate in particular to threshold value determination method and device in a kind of human body skin tone testing.
Background technology
The target of human body skin tone testing is to orient the exposed skin area of human body from image automatically.Detect skin area exactly and in present stage human detection and image filtering are had very important significance, in addition, human body skin tone testing also has application in occasions such as fast face detection.
Existing Skin Detection mainly is the skin color probability modelling, promptly for an image to be detected, count respectively skin color probability that should image to be detected is distributed and the distribution of non-skin color probability, wherein, the form that skin color probability distributes and non-skin color probability distributes can have multiple version, as being the probability histogram that disperses, also can be the continuous probability density function (common has Gauss Gauss to distribute or mixed Gaussian Gauss distribution) of concluding; Then, utilizing above-mentioned two probability distribution can calculate each pixel is respectively the likelihood probability of the colour of skin and the likelihood probability of the non-colour of skin, calculates the posterior probability that this pixel is the colour of skin again, so just can obtain the width of cloth skin color probability image corresponding with original image.But how to obtain skin area figure from the skin color probability image is an image binaryzation problem, generally all adopt threshold method, with skin color probability greater than the pixel of certain threshold value T as skin pixel, otherwise as non-skin pixel, therefore the selection of threshold value T is very important to the result of Face Detection, below narration skin color detection method of the prior art.
In the prior art, Bayes (Bayes) decision-making is a basic skills in the statistical model identification, and its primitive rule is: the classification that sample is included into risk minimum (being that error rate is minimum).Wherein, use the prerequisite of Bayes decision-making technique to be: to treat that classification number that the branch sample can belong to, overall probability distribution (treating that perhaps the branch sample belongs to the likelihood probability of each classification) of all categories are all known.
Be categorized as example so that pixel x is carried out the colour of skin below, introduce the application process of Bayes decision-making technique in Face Detection.In Face Detection, treat that the classification that the branch sample can belong to comprises colour of skin classification and non-colour of skin classification two classes.For treating the branch sample, the color of supposing pixel x is color with pixel x, and the likelihood probability that x belongs to colour of skin classification is P (color|skin), and the likelihood probability that belongs to non-colour of skin classification is
Figure A20081011085500061
The prior probability of colour of skin classification is P (skin), and the prior probability of non-colour of skin classification is (suppose usually P (skin) and
Figure A20081011085500063
Equate), then the pixel x posterior probability that belongs to the colour of skin is expressed as by following formula:
Figure A20081011085500064
Figure A20081011085500065
Can obtain the posterior probability that pixel x belongs to the non-colour of skin equally
Figure A20081011085500066
When adopting the Bayes decision-making technique that pixel x is carried out Face Detection, if P (skin|color)>T, then pixel x is the colour of skin, otherwise pixel x is the non-colour of skin, and wherein, T is for judging that pixel is that the colour of skin also is the threshold value of the non-colour of skin.
In the Bayes decision-making technique, threshold value is a fixed value, can be 0.5, perhaps for being multiplied by a fixed value of risks and assumptions, wherein, the fixed threshold T of Bayes diagnostic method is average meaning optimum on the large sample collection, but for each image pattern individuality, this threshold value often is not optimum, such as, when the colour of skin posterior probability of background pixel is higher, resulting skin area figure just may contain too much non-skin area, and perhaps when the colour of skin posterior probability of skin pixels was on the low side, the skin area that skin area figure shows will be imperfect, like this, just reduced human body skin tone testing accuracy.
Summary of the invention
The invention provides threshold value determination method and device in a kind of human body skin tone testing, so that improve human body skin tone testing accuracy.
Threshold value determination method in a kind of human body skin tone testing provided by the present invention obtains the skin color probability image of image correspondence to be detected; This method comprises:
According to described skin color probability image, obtain level and smooth skin color probability distribution histogram;
Obtain peak dot and valley point in the described level and smooth skin color probability distribution histogram;
According to the described peak dot and the valley point that obtain, determine the threshold value in the human body skin tone testing.
Definite device of threshold value in a kind of human body skin tone testing provided by the present invention comprises that skin color probability image acquiring unit is used to obtain the skin color probability image of image correspondence to be detected; This device also comprises:
Skin color probability distribution histogram acquiring unit is used for the skin color probability image that obtains according to described skin color probability image acquiring unit, obtains level and smooth skin color probability distribution histogram;
Peak dot and valley point acquiring unit are used for obtaining the peak dot and the valley point of the level and smooth skin color probability distribution histogram that described skin color probability distribution histogram acquiring unit obtains;
The threshold value determining unit is used for determining the threshold value in the human body skin tone testing according to the described peak dot and the valley point that obtain.
From such scheme as can be seen, threshold value determination method and device in a kind of human body skin tone testing among the present invention obtain the skin color probability image of image correspondence to be detected; During specific implementation,, obtain level and smooth skin color probability distribution histogram by according to described skin color probability image; Afterwards, obtain peak dot and valley point in the described level and smooth skin color probability distribution histogram; According to the described peak dot and the valley point that obtain, determine the threshold value in the human body skin tone testing, can avoid the available technology adopting threshold value be fixed value to human body skin tone testing, and then improved human body skin tone testing accuracy.
Description of drawings
Fig. 1 is threshold value determination method process flow diagram in a kind of human body skin tone testing of embodiment of the invention proposition;
Fig. 2 is typical in the skin color probability distribution histogram after level and smooth in the embodiment of the invention;
Fig. 3 obtains the peak dot of level and smooth skin color probability distribution histogram and the process flow diagram of valley point in the embodiment of the invention;
Fig. 4 is peak dot and the valley point that utilizes in the embodiment of the invention after screening, and determines the threshold value process flow diagram in the human body skin tone testing;
Fig. 5 is definite structure drawing of device of threshold value in the human body skin tone testing in the embodiment of the invention.
Embodiment
For making the purpose, technical solutions and advantages of the present invention clearer, below in conjunction with embodiment and accompanying drawing, the present invention is described in more detail.
Referring to Fig. 1, Fig. 1 is threshold value determination method process flow diagram in a kind of human body skin tone testing of embodiment of the invention proposition, among this embodiment, at image to be detected, at first each pixel that can go out in the image to be detected by the skin color probability Model Calculation is the probability of the colour of skin, obtains the width of cloth skin color probability image corresponding with image to be detected, during specific implementation, can adopt and prior art similar operation step, repeat no more here.Then as shown in Figure 1, the threshold value determination method flow process can may further comprise the steps in this human body skin tone testing:
Step 101 according to above-mentioned skin color probability image, is obtained level and smooth skin color probability distribution histogram.
Here, according to the skin color probability image, obtaining level and smooth skin color probability distribution histogram can comprise: at first according to the skin color probability image, count the skin color probability distribution histogram of this skin color probability image correspondence, afterwards, again the skin color probability distribution histogram that counts is carried out smoothing processing, during specific implementation, can utilize the gauss kernel function that the skin color probability distribution histogram that counts is carried out smoothing processing, obtain level and smooth skin color probability distribution histogram.
Referring to Fig. 2, Fig. 2 is typical in the skin color probability distribution histogram after level and smooth in the embodiment of the invention.As shown in Figure 2, the above-mentioned level and smooth skin color probability distribution histogram that obtains has two coordinate axis, and one of them coordinate axis is abscissa axis (an x coordinate axis), be used to represent the skin color probability after the equidistant quantification, the numerical range of this abscissa axis is 0~1, and promptly high order end is 0, and low order end is 1.Another coordinate axis is axis of ordinates perpendicular to abscissa axis, is used to represent the number of pixels of each skin color probability correspondence.In addition, as can see from Figure 2, keep right more among this Fig. 2, skin color probability is big more, also promptly more near area of skin color.
Step 102 is obtained peak dot and valley point in the above-mentioned level and smooth skin color probability distribution histogram.
Here, above-mentioned peak dot and the valley point that obtains in the level and smooth skin color probability distribution histogram can be referring to step shown in Figure 3, and as shown in Figure 3, above-mentioned peak dot and the valley point that obtains in the level and smooth skin color probability distribution histogram can may further comprise the steps:
Step 301 is obtained all peak dots and valley point in the level and smooth skin color probability distribution histogram.
Here, from the low order end of level and smooth skin color probability distribution histogram, obtain peak dot and valley point in the level and smooth skin color probability distribution histogram successively.Wherein, when obtaining the peak dot in the level and smooth skin color probability distribution histogram, can obtain more than or equal to the principle of the ordinate of any one adjacent point according to the ordinate of peak dot.Correspondingly, when obtaining the valley point in the level and smooth skin color probability distribution histogram, can obtain smaller or equal to the principle of the ordinate of any one adjacent point according to the ordinate of valley point.Like this, in the skin color probability distribution histogram after process shown in Figure 2 is level and smooth, the peak dot that can obtain in the level and smooth skin color probability distribution histogram has 5, right-hand member the skin color probability distribution histogram of sequence number after level and smooth begins, correspond to 1 to 5 successively respectively, wherein, the abscissa value of the peak dot of sequence number 1 to 5 is respectively p1, p2, p3, p4 and p5, and the valley point in the level and smooth skin color probability distribution histogram has 4, right-hand member the skin color probability distribution histogram of sequence number after level and smooth begins, correspond to 1 successively respectively ' to 4 ', wherein, sequence number 1 ' be respectively v1 to the abscissa value of 4 ' valley point, v2, v3 and v4.As can be seen, in the level and smooth skin color probability distribution histogram shown in Figure 2, the number of peak dot is Duoed one than the number of valley point.In addition as can be seen, the horizontal ordinate of the 1st peak dot is bigger among this Fig. 2, and therefore, its ordinate can be thought corresponding the pixel of skin area.
Step 302 is screened peak dot and valley point after obtaining screening according to default rule to described all peak dots and the valley point that obtains.
Wherein, above-mentionedly described peak dot that obtains and valley point are screened according to default rule, peak dot after obtaining screening and valley point mainly are to get rid of inapparent peak dot and valley point, preferably, according to default rule described peak dot that obtains and valley point are screened in the present embodiment, in the following ways: at first, above-mentioned all peak dots that obtain and valley point are arranged according to the size of abscissa value.Then, whether the difference of abscissa value of judging any two adjacent peak dots is smaller or equal to first predetermined threshold value, if peak dot that one of them abscissa value is less and the valley point that is clipped between described two adjacent peak dots are got rid of; And/or whether the difference of abscissa value of judging any two adjacent valley points is smaller or equal to second predetermined threshold value, if valley point that one of them abscissa value is bigger and the peak dot that is clipped between described two adjacent valley points are got rid of; And/or, if the difference of the abscissa value of adjacent peak dot and valley point in the scope of the 3rd predetermined threshold value, judges then that whether the difference of ordinate value of described adjacent peak dot and valley point is less than the 4th predetermined threshold value, if described adjacent peak dot and valley point are got rid of.
In this enforcement,, then the described peak dot that obtains and valley point are arranged according to the size of abscissa value and can be p1, v1, p2, v2, p3, v3, p4, v4 and p5 if level and smooth skin color probability distribution histogram as shown in Figure 2.
And, whether the difference of the above-mentioned abscissa value of judging any two adjacent peak dots is smaller or equal to first predetermined threshold value, if, peak dot that one of them abscissa value is less and the valley point eliminating that is clipped between described two adjacent peak dots are: judge that p1 and p2's is poor, perhaps p2 and p3's is poor, perhaps p3 and p4's is poor, perhaps whether the difference of p4 and p5 is smaller or equal to first predetermined threshold value, if peak dot that one of them abscissa value is less and the valley point that is clipped between described two adjacent peak dots are got rid of.Such as, if the difference of p2 and p3 is less than first predetermined threshold value, and, by contrast, p3 is less than p2, is p3 because sequence number is the abscissa value of 3 peak dot, then gets rid of sequence number and be 3 peak dot, and sequence number is 2 ' the abscissa value of valley point between p2 and p3, then get rid of sequence number and be 2 ' the valley point.
Whether the difference of the above-mentioned abscissa value of judging any two adjacent valley points is smaller or equal to second predetermined threshold value, if, valley point that one of them abscissa value is bigger and the peak dot eliminating that is clipped between described two adjacent valley points are: judge that v1 and v2's is poor, v2 and v3's is poor, whether the difference of v3 and v4 is smaller or equal to second predetermined threshold value, if, valley point that abscissa value is bigger and the peak dot that is clipped between these two adjacent valley points are got rid of, such as, if the difference of v2 and v3 is less than second predetermined threshold value, and, by contrast, v3 is less than v2, then get rid of sequence number respectively and be 3 ' valley point and sequence number be 3 peak dot.
If the difference of the abscissa value of above-mentioned adjacent peak dot and valley point is in the scope of the 3rd predetermined threshold value the time, whether the difference of ordinate value of judging peak dot that this is adjacent and valley point is less than the 4th predetermined threshold value, if, with described adjacent peak dot and valley point deletion be: if p1 and v1, perhaps v1 and p2, perhaps p2 and v2, perhaps v2 and p3, perhaps p3 and v3, perhaps v3 and p4, perhaps p4 and v4, perhaps the difference of v4 and p5 is in the scope of the 3rd predetermined threshold value, whether the difference of ordinate value of then judging described adjacent peak dot and valley point is less than the 4th predetermined threshold value, if described adjacent peak dot and valley point are got rid of.
So far, realized described all peak dots and the valley point that obtains being screened peak dot and valley point after obtaining screening.Need to prove, in the present embodiment except the above-mentioned mode that the described peak dot that obtains and valley point are screened, during specific implementation, other modes can also be arranged, as direct the peak dot of the above-mentioned abscissa value minimum of obtaining and the valley point of abscissa value minimum are got rid of, perhaps directly with the peak dot of the above-mentioned abscissa value maximum of obtaining and the valley point eliminating of abscissa value minimum etc., concrete condition needs concrete analysis, repeats no more here.
Step 103 according to the described peak dot and the valley point that obtain, is determined the threshold value in the human body skin tone testing.
Here, peak dot that above-mentioned basis is obtained and valley point determine that the threshold value in the human body skin tone testing specifically can be: utilize peak dot and valley point after screening, determine the threshold value in the human body skin tone testing.
Here, be subjected to the influence of threshold value move left and right for the result who reduces image binaryzation, generally, can must be peak dot and valley point after the principle of the horizontal ordinate of certain valley point is utilized screening according to the optimal threshold in the human body skin tone testing, determine the threshold value in the human body skin tone testing.Like this, the horizontal ordinate of each valley point that obtains through above screening all may be the threshold value in the human body skin tone testing.Preferably, the right-hand member of the threshold value that this is determined should all be a skin pixels, promptly close color and close skin color probability should be arranged all; Correspondingly, the left end of the threshold value that this is determined is a background pixel, because the complicacy of background itself, so the left end of this threshold value of determining not necessarily has the homogeneity as the skin pixels.
Wherein, peak dot and valley point after the above-mentioned utilization screening determine that the threshold value in the human body skin tone testing can adopt operation shown in Figure 4.Fig. 4 is peak dot and the valley point that utilizes in the embodiment of the invention after screening, and determines the threshold value process flow diagram in the human body skin tone testing.As shown in Figure 4, this flow process can may further comprise the steps:
Step 401, the balance function E (t) that concerns between the area three of the skin color probability of equilibrium establishment skin area, consistency of colour and skin area.
Here, above-mentioned balance function E (t) can represent by following formula: E ( t ) = ( σ prob 2 ( t ) + λ σ color 2 ( t ) ) / N ( t ) ;
Wherein, t is the abscissa value of the valley point after screening, σ Prob 2(t) be the skin color probability variance of skin color probability greater than all pixels of t, σ is obtained in the operation that can utilize prior art to calculate variance Color 2(t) be skin color probability all color of pixel variances greater than t, N (t) is the number of skin color probability greater than all pixels of t, and λ is a quantity factor.
Step 402 as among the threshold value independent variable t substitution balance function E (t) in the human body skin tone testing, will make the abscissa value of balance function E (t) value valley point hour as the threshold value in the human body skin tone testing abscissa value of valley point after the screening.
Here, when execution in step 402, need to determine earlier skin color probability all color of pixel variances sigma greater than t Color 2(t) and skin color probability greater than the number N (t) of all pixels of t.General for ease of this embodiment, the t in the present embodiment is not the abscissa value at some valley points in the valley point after the screening.Specify below and determine skin color probability all color of pixel variances sigma in the embodiment of the invention greater than t Color 2(t) and skin color probability greater than the concrete grammar of the number N (t) of all pixels of t.
Need to prove, in the present embodiment, when carrying out above-mentioned steps 101, particularly, in step 101 count the skin color probability distribution histogram of skin color probability image correspondence the time, can further comprise: utilize the number of the pixel in each skin color probability interval of first accumulator computes, and utilize second totalizer and the 3rd totalizer calculate respectively the color of pixel value in each skin color probability interval and color value square.Promptly safeguard three totalizers, utilize the number of the pixel in each skin color probability interval of first accumulator computes, preferably, the number of the pixel in each skin color probability interval can exist with the form of array, and concrete formula can be: A 0[j ← A 0[j]+1.Wherein, for s, there is P (skin|color (s)) ∈ [p j, p J+1); And [p j, p J+1) be the interval of skin color probability.
Equally, utilize the color of pixel value in each skin color probability interval of second accumulator computes, preferably, the color of pixel value in each skin color probability interval can exist with the form of array, and concrete formula is: A 1[j] ← A 1[j]+(color (s)); Wherein, color (s) is the color value of pixel s, for s, has P (skin|color (s)) ∈ [p j, P J+1); [p j, p J+1) be the interval of skin color probability.
Utilize each skin color probability interval of the 3rd accumulator computes the color of pixel value square, preferably, square can existing with the form of array of the color of pixel value in each skin color probability interval specifically represented by following formula: A 2[j] ← A 2[j]+(color (s)) 2, wherein, color (s) is the color value of pixel s, for s, has P (skin|color (s)) ∈ [P j, p J+1); [p j, p J+1) be the interval of skin color probability.
Like this, just can calculate all color of pixel variances sigma greater than t Color 2(t), specifically can obtain, comprise by integral algorithm:
In the result of first accumulator computes, skin color probability is carried out integration greater than the number of pixels in all skin color probability intervals of t, obtain the number N (t) of skin color probability greater than all pixels of t, specifically can represent by following formula: N ( t ) = Σ k > = t A 0 [ k ] .
At second totalizer and the 3rd totalizer respectively in the result calculated, respectively to skin color probability greater than color of pixel value in all skin color probability intervals of t and color value square carry out integration, obtain B 1(t) and B 2(t); Wherein, B 1 ( t ) = Σ k > = t A 1 [ k ] , B 2 ( t ) = Σ k > = t A 2 [ k ] .
Utilize N (t) and B 1(t) calculate skin color probability all color of pixel averages, be specially: m[t greater than t]=B 1[t]/N (t).
Utilize described color average, N (t) and B 2(t), calculate skin color probability all color of pixel variances sigma greater than t Color 2(t).Be specially: σ 2[t]=B 2[t]/N (t)-(m (t)) 2
So far, realized calculating and decided skin color probability all color of pixel variances sigma greater than t Color 2(t) and skin color probability greater than the number N (t) of all pixels of t.
Afterwards, execution in step 402, the abscissa value that is about to the valley point after the screening be respectively among the substitution balance function E (t), will make the abscissa value of balance function E (t) value valley point hour as the threshold value in the human body skin tone testing.Such as level and smooth skin color probability distribution histogram as shown in Figure 2, wherein, the sequence number of the valley point after the screening is respectively 1 ', 2 ' and 4 ', its corresponding horizontal ordinate is respectively v1, v2 and v4, then with among v1, v2 and the v4 difference substitution E (t), obtains corresponding E as a result (v1), E (v2) and E (v4), afterwards, determine E (v1), the minimum value among E (v2) and the E (v4), if E (v2) minimum then is defined as v2 the threshold value in the human body skin tone testing.
So far, realized the method flow of the threshold value in definite human body skin tone testing.Like this, utilize the method flow of determining the threshold value in the human body skin tone testing in the embodiment of the invention to can be applicable to the detection technique that sensitive image filters, fast face detects and is used for other similar asymmetrical image binaryzation problem.
Need to prove, the above-mentioned consistance of utilizing the skin class the balance function E (t) that concerns between the area three of skin color probability, consistency of colour and skin area of the equilibrium establishment skin area in the execution in step 401 as criterion, and then the threshold value in definite human body skin tone testing, present embodiment also can adopt other criterions such as inter-class variance criterion and entropy criterion to determine threshold value in the human body skin tone testing, concrete condition needs concrete analysis, repeats no more here.
In order to realize threshold value determination method in the above-mentioned human body skin tone testing better, the embodiment of the invention also provides definite device of threshold value in a kind of human body skin tone testing, specifically can be referring to structure drawing of device shown in Figure 5.
Fig. 5 is definite structure drawing of device of threshold value in the human body skin tone testing in the embodiment of the invention, and as shown in Figure 5, this device comprises: skin color probability image acquiring unit 501 is used to obtain the skin color probability image of image correspondence to be detected; Crucially, this device also can comprise: skin color probability distribution histogram acquiring unit 502, peak dot and valley point acquiring unit 503 and threshold value determining unit 504.
Wherein, skin color probability distribution histogram acquiring unit 502 is used for the skin color probability image that obtains according to skin color probability image acquiring unit 401, obtains level and smooth skin color probability distribution histogram.
Peak dot and valley point acquiring unit 503 are used for obtaining the peak dot and the valley point of the level and smooth skin color probability distribution histogram that skin color probability distribution histogram acquiring unit 402 obtains.
Threshold value determining unit 504 is used for determining the threshold value in the human body skin tone testing according to the described peak dot and the valley point that obtain.
Preferably, skin color probability distribution histogram acquiring unit 502 can comprise: the skin color probability distribution histogram obtains subelement 5021 and level and smooth skin color probability distribution histogram obtains subelement 5022.
Wherein, the skin color probability distribution histogram obtains subelement 5021 and is used for according to the skin color probability image, counts the skin color probability distribution histogram of described skin color probability image correspondence.
Level and smooth skin color probability distribution histogram obtains subelement 5022 and is used for that the skin color probability distribution histogram is obtained the skin color probability distribution histogram that subelement 5022 counts and carries out smoothing processing, obtains level and smooth skin color probability distribution histogram.
Preferably, the coordinate axis that level and smooth skin color probability distribution histogram obtains the level and smooth skin color probability distribution histogram that subelement 5022 obtains is an abscissa axis, be used to represent the skin color probability after the equidistant quantification, another coordinate axis is an axis of ordinates, is used to represent the number of pixels of each skin color probability correspondence.
Preferably, peak dot and valley point acquiring unit 503 can comprise: peak dot and valley point obtain subelement 5031 and screening subelement 5032.
Wherein, peak dot and valley point obtain all peak dots and the valley point that subelement 5031 is used for obtaining level and smooth skin color probability distribution histogram.
Screening subelement 5032 is used for according to default rule peak dot and valley point being obtained all peak dots and the valley point that subelement 5031 obtains and screens peak dot and valley point after obtaining screening.
Like this, threshold value determining unit 504 is utilized peak dot and the valley point after the screening, determines the threshold value in the human body skin tone testing.
Need to prove, in the embodiment of the invention, the specific operation process of inner each unit of the definite device of threshold value can be consistent with the operation described in the method flow shown in Figure 1 in the human body skin tone testing, and each unit can be the physical function unit, also can be SFU software functional unit, and each unit also can segment or merge, during specific implementation, those of ordinary skills can handle according to actual conditions, enumerate no longer one by one herein.
As seen, threshold value determination method and device in the human body skin tone testing in the embodiment of the invention are after obtaining the skin color probability image of image correspondence to be detected; Can obtain level and smooth skin color probability distribution histogram by according to described skin color probability image; Obtain peak dot and valley point in the described level and smooth skin color probability distribution histogram; According to the described peak dot and the valley point that obtain, determine the threshold value in the human body skin tone testing, can improve in the prior art detection effect based on the skin color detection method of skin color probability model and threshold method, avoid the available technology adopting threshold value be fixed value to human body skin tone testing, and then improved human body skin tone testing accuracy.
Above-described specific embodiment; purpose of the present invention, technical scheme and beneficial effect are further described; institute is understood that; the above only is preferred embodiment of the present invention; be not to be used to limit protection scope of the present invention; within the spirit and principles in the present invention all, any modification of being done, be equal to replacement, improvement etc., all should be included within protection scope of the present invention.

Claims (10)

1, threshold value determination method in a kind of human body skin tone testing obtains the skin color probability image of image correspondence to be detected; It is characterized in that this method comprises:
According to described skin color probability image, obtain level and smooth skin color probability distribution histogram;
Obtain peak dot and valley point in the described level and smooth skin color probability distribution histogram;
According to the described peak dot and the valley point that obtain, determine the threshold value in the human body skin tone testing.
2, method according to claim 1 is characterized in that, described peak dot and the valley point that obtains in the level and smooth skin color probability distribution histogram comprises:
Obtain all peak dots and valley point in the level and smooth skin color probability distribution histogram;
Described all peak dots and the valley point that obtains screened peak dot and valley point after obtaining screening according to default rule;
Peak dot that described basis is obtained and valley point, determine that the threshold value in the human body skin tone testing comprises:
Utilize peak dot and valley point after screening, determine the threshold value in the human body skin tone testing.
3, method according to claim 2 is characterized in that, described all peak dots of obtaining and valley point screenings according to default rule comprises:
Described all peak dots that obtain and valley point are arranged according to the size of abscissa value;
Whether the difference of abscissa value of judging any two adjacent peak dots is smaller or equal to first predetermined threshold value, if peak dot that one of them abscissa value is less and the valley point that is clipped between described two adjacent peak dots are got rid of; And/or,
Whether the difference of abscissa value of judging any two adjacent valley points is smaller or equal to second predetermined threshold value, if valley point that one of them abscissa value is bigger and the peak dot that is clipped between described two adjacent valley points are got rid of; And/or,
If the difference of the abscissa value of adjacent peak dot and valley point in the scope of the 3rd predetermined threshold value, judges then that whether the difference of ordinate value of described adjacent peak dot and valley point is less than the 4th predetermined threshold value, if described adjacent peak dot and valley point are got rid of.
4, method according to claim 2 is characterized in that, peak dot and valley point after the described utilization screening determine that the threshold value in the human body skin tone testing comprises:
The balance function E (t) that concerns between the area three of equilibrium establishment skin color probability, consistency of colour and skin area;
As among the threshold value independent variable t substitution balance function E (t) in the human body skin tone testing, will make the abscissa value of balance function E (t) value valley point hour the abscissa value of valley point after the screening as the threshold value in the human body skin tone testing.
5, method according to claim 4 is characterized in that, described balance function E (t) is
E ( t ) = ( σ prob 2 ( t ) + λ σ color 2 ( t ) ) / N ( t ) ;
Wherein, σ Prob 2(t) be the skin color probability variance of skin color probability, σ greater than all pixels of t Color 2(t) be skin color probability all color of pixel variances greater than t, N (t) is the number of skin color probability greater than all pixels of t, and λ is a quantity factor.
6, method according to claim 5, it is characterized in that, described according to the skin color probability image, when obtaining level and smooth skin color probability distribution histogram, further comprise: utilize the number of the pixel in each skin color probability interval of first accumulator computes, and utilize second totalizer and the 3rd totalizer calculate respectively the color of pixel value in each skin color probability interval and color value square;
Described skin color probability is greater than all color of pixel variances sigma of t Color 2(t) obtain by integration, comprise: in the result of first accumulator computes, skin color probability is carried out integration greater than the number of pixels in all skin color probability intervals of t, obtain the number N (t) of skin color probability greater than all pixels of t, in second totalizer and the 3rd totalizer difference result calculated, respectively to skin color probability greater than color of pixel value in all skin color probability intervals of t and color value square carry out integration, obtain B 1(t) and B 2(t);
Utilize N (t) and B 1(t) calculate skin color probability all color of pixel averages greater than t;
Utilize described color average, N (t) and B 2(t), calculate skin color probability all color of pixel variances sigma greater than t Colir 2(t).
7, definite device of threshold value in a kind of human body skin tone testing comprises that skin color probability image acquiring unit is used to obtain the skin color probability image of image correspondence to be detected; It is characterized in that this device also comprises:
Skin color probability distribution histogram acquiring unit is used for the skin color probability image that obtains according to described skin color probability image acquiring unit, obtains level and smooth skin color probability distribution histogram;
Peak dot and valley point acquiring unit are used for obtaining the peak dot and the valley point of the level and smooth skin color probability distribution histogram that described skin color probability distribution histogram acquiring unit obtains;
The threshold value determining unit is used for determining the threshold value in the human body skin tone testing according to the described peak dot and the valley point that obtain.
8, device according to claim 7 is characterized in that, described skin color probability distribution histogram acquiring unit comprises:
The skin color probability distribution histogram obtains subelement, is used for according to the skin color probability image, counts the skin color probability distribution histogram of described skin color probability image correspondence;
Level and smooth skin color probability distribution histogram obtains subelement, is used for that described skin color probability distribution histogram is obtained the skin color probability distribution histogram that subelement counts and carries out smoothing processing, obtains level and smooth skin color probability distribution histogram.
9, device according to claim 8, it is characterized in that, the coordinate axis that described level and smooth skin color probability distribution histogram obtains the level and smooth skin color probability distribution histogram that subelement obtains is an abscissa axis, be used to represent the skin color probability after the equidistant quantification, another coordinate axis is an axis of ordinates, is used to represent the number of pixels of each skin color probability correspondence.
10, device according to claim 9 is characterized in that, described peak dot and valley point acquiring unit comprise:
Peak dot and valley point obtain subelement, are used for obtaining all peak dots and the valley point of level and smooth skin color probability distribution histogram;
The screening subelement is used for according to default rule described peak dot and valley point being obtained all peak dots and the valley point that subelement obtains and screens peak dot and valley point after obtaining screening;
The threshold value in the human body skin tone testing is determined in peak dot and valley point after the described threshold value determining unit utilization screening.
CN2008101108554A 2008-06-13 2008-06-13 Method and device for determining threshold value in human body skin tone detection Active CN101299242B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN2008101108554A CN101299242B (en) 2008-06-13 2008-06-13 Method and device for determining threshold value in human body skin tone detection

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN2008101108554A CN101299242B (en) 2008-06-13 2008-06-13 Method and device for determining threshold value in human body skin tone detection

Publications (2)

Publication Number Publication Date
CN101299242A true CN101299242A (en) 2008-11-05
CN101299242B CN101299242B (en) 2010-08-25

Family

ID=40079066

Family Applications (1)

Application Number Title Priority Date Filing Date
CN2008101108554A Active CN101299242B (en) 2008-06-13 2008-06-13 Method and device for determining threshold value in human body skin tone detection

Country Status (1)

Country Link
CN (1) CN101299242B (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103106386A (en) * 2011-11-10 2013-05-15 华为技术有限公司 Dynamic self-adaption skin color segmentation method and device
CN104734905A (en) * 2013-12-24 2015-06-24 华为技术有限公司 Data flow detection method and device
CN106355134A (en) * 2015-07-17 2017-01-25 台鉅企业股份有限公司 Human face image-based human face skin color detection and database establishment method
CN106570472A (en) * 2016-11-02 2017-04-19 华为技术有限公司 Skin color detecting method and device and terminal
CN115560878A (en) * 2022-12-05 2023-01-03 中科声龙科技发展(北京)有限公司 Equipment temperature detection method, device, equipment and storage medium

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP5993233B2 (en) * 2012-07-11 2016-09-14 オリンパス株式会社 Image processing apparatus and image processing method

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5848183A (en) * 1996-11-21 1998-12-08 Xerox Corporation System and method for generating and utilizing histogram data from a scanned image
CN100377177C (en) * 2004-12-24 2008-03-26 中国科学院计算技术研究所 Method for detecting area of skin color of human body in image compression domain

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103106386A (en) * 2011-11-10 2013-05-15 华为技术有限公司 Dynamic self-adaption skin color segmentation method and device
CN104734905A (en) * 2013-12-24 2015-06-24 华为技术有限公司 Data flow detection method and device
CN104734905B (en) * 2013-12-24 2018-05-11 华为技术有限公司 Detect the method and device of data flow
CN106355134A (en) * 2015-07-17 2017-01-25 台鉅企业股份有限公司 Human face image-based human face skin color detection and database establishment method
CN106570472A (en) * 2016-11-02 2017-04-19 华为技术有限公司 Skin color detecting method and device and terminal
CN106570472B (en) * 2016-11-02 2019-11-05 华为技术有限公司 A kind of skin color detection method, device and terminal
CN115560878A (en) * 2022-12-05 2023-01-03 中科声龙科技发展(北京)有限公司 Equipment temperature detection method, device, equipment and storage medium
CN115560878B (en) * 2022-12-05 2023-03-10 中科声龙科技发展(北京)有限公司 Equipment temperature detection method, device, equipment and storage medium

Also Published As

Publication number Publication date
CN101299242B (en) 2010-08-25

Similar Documents

Publication Publication Date Title
Levin et al. Patch complexity, finite pixel correlations and optimal denoising
CN101299242B (en) Method and device for determining threshold value in human body skin tone detection
EP3333768A1 (en) Method and apparatus for detecting target
CN103996195B (en) Image saliency detection method
CN100512374C (en) A method for image edge detection based on threshold sectioning
CN102496001B (en) Method of video monitor object automatic detection and system thereof
KR100957716B1 (en) Extraction Method of Skin-Colored Region using Variable Skin Color Model
CN108664840A (en) Image-recognizing method and device
CN107122777A (en) A kind of vehicle analysis system and analysis method based on video file
CN104408707A (en) Rapid digital imaging fuzzy identification and restored image quality assessment method
Li et al. Modified local entropy-based transition region extraction and thresholding
KR20070060496A (en) Method for classification of geological materials using image processing and apparatus thereof
CN106682473A (en) Method and device for identifying identity information of users
CN108876756A (en) The measure and device of image similarity
Nie et al. Two-dimensional extension of variance-based thresholding for image segmentation
CN108280480A (en) A kind of hidden image vector safety evaluation method based on residual error symbiosis probability
CN105405130A (en) Cluster-based license image highlight detection method and device
Hagwood et al. Evaluation of segmentation algorithms on cell populations using CDF curves
CN104952055B (en) A kind of pattern mask sharpens detection method and system
CN103279960A (en) Human body hidden thing image segmentation method based on X-ray back scattering image
Maity et al. Background modeling and foreground extraction in video data using spatio-temporal region persistence features
Qureshi et al. An information based framework for performance evaluation of image enhancement methods
CN110287752A (en) A kind of dot matrix code detection method and device
Genadot Averaging for some simple constrained Markov processes
Martens et al. Noise-and compression-robust biological features for texture classification

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
TR01 Transfer of patent right
TR01 Transfer of patent right

Effective date of registration: 20180907

Address after: 100090 Beijing Haidian District Zhichun Road 49 No. 3 West 309

Patentee after: Tencent cloud computing (Beijing) limited liability company

Address before: 518044 East 403 room, Sai Ge science and Technology Park, Futian District Zhenxing Road, Shenzhen, Guangdong, China, 2

Patentee before: Tencent Technology (Shenzhen) Co., Ltd.