How to determine if skin colour on a photo is correct or not?
16 views (last 30 days)
Show older comments
Hello all,
Often when taking a photo of people, due to a failure during white balance or significant exposure problems, the tones of people faces are somewhat red or too dark or...
Basically what I am trying to do is to determine if skin colour on a detected face is good or not.
Lets make it simple and do this analysis for one race only - i.e. white people.
I will train algorithm (i.e. SVM) with colour features characteristic for bad and good faces. For face detection I will use Viola Jones algorithm, which will give me face bounding box.
What to do next? Maybe to search for a dominant colour inside a face bounding box and to represent it in a LUV color space?
I guess that way I will (ideally) get two clusters in a 2D space, one representing "good" coloured faces and other representing "bad" coloured faces.
Best regards, Matija.
1 Comment
Jurgen
on 27 Feb 2013
If you want to correct for whitebalance or exposure, testing face color seems a bit roundabout? But I think your initial idea is a good one. Although you might need to cluster in 3D space if wrong exposure also affects brightness.
Answers (2)
Jan
on 27 Feb 2013
Edited: Jan
on 27 Feb 2013
I do not think that there is something like a "white race". Even "white" people have very different skin colors. See:
- http://www.jaffamood.com/img/funny/faces/faces05.jpg
- http://www.simonhoegsberg.com/faces_of_new_york/images/01_faces.jpg
- http://www.straitpinkie.com/wp-content/uploads/2009/10/Gemma-Atkinson-face-980.jpg
Look at: Google Images: "face". There will neither be a safe distinction between "good" and "bad" face colors, not between "white" and "non-white" races.
To get a good white balance, concentrate on a white object. Fortunately the white area of eyes is visible frequently and it is very reliable, because only a few diseases change this color noticably. From a scientific point of view, using white objects for a white balance is much more direct, than to classify the quality of a color based on different colors.
3 Comments
Jan
on 28 Feb 2013
Moved: DGM
on 29 Dec 2023
Please post comments in the comment section and not as an answer. Thanks.
I still think, that it will be impossible to solve your problem, because the natural inter-person variance will conceal the variance caused by white-balance and exposure settings of the image acquisition system. A red skin can be real (too high blood pressure, sunburn, red ambient light) or the result of a bad white balance.
But a cause for the difference between our opinions can be the exact definition of:
the tones of people faces are somewhat red or too dark or...
What problem do you want to solve? Are you looking for pictures, which contain faces with a color inside a certain range, or for pictures, whose colors are near to the real color of the persons faces? While the first problem can be solved by an automatic classification, I have strong doubts that the second problem can be solved, because you do not have information about the real colors. It is like a measurement of the value 171 and the knowledge, that this can be too high or too low - then there is no chance to estimate the quality of the measurement. Of course you can train the classification such that values near to 180 are assumed as "good", but this is a measurement of your preferences only, and the relation to the real face colors is very weak.
Image Analyst
on 28 Feb 2013
A paper on this was presented at the last Color Imaging Conference: http://www.imaging.org/IST/store/epub.cfm?abstrid=46635. Abstract, in part, says "....Through the experimental results, the proposed method achieves preferred skin color reproduction for each race....."
8 Comments
Image Analyst
on 21 Apr 2013
Moved: DGM
on 29 Dec 2023
You could try that if you want, as long as you have enough pixels there to get a representative sample.
Image Analyst
on 21 Apr 2013
The colors were not sampled manually. If I'm remembering the right paper they used a slight variation of a skin color detection algorithm proposed by someone else.
See Also
Categories
Find more on Recognition, Object Detection, and Semantic Segmentation in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!