Program for determining the attractiveness of the face. Criteria for professional photo evaluation or how to evaluate your photo

“My light, mirror! tell
Yes, tell the whole truth:
Am I the sweetest in the world,
All blush and whiter?

A.S. Pushkin

Magical things from fairy tales are gradually being realized in real reality through the use of new technologies and scientific discoveries. Already implemented and actively used are such devices as a flying carpet (aviation), walking boots (cars), an apple on a silver platter (netbook with Internet), a ball that shows the way (GPS navigator) and other necessary things. We tried to implement the system of assessing the beauty of a person’s face mentioned in the “Tale of the Dead Princess and the Seven Bogatyrs” using methods artificial intelligence and machine vision, since we believe that the author of the epigraph actually meant a tablet with a front camera and special installed software.

The question of what exactly makes a person's face attractive is the subject of research by physiologists, biologists, philosophers, art historians, and specialists in plastic surgery for a long time. It is now considered an established fact that people other than individual preferences, and the general biologically motivated principles of beauty assessment also influence. Among the possible candidates for typical signs physiologists distinguish the symmetry of facial features, the difference between the image of the face and the average image of the faces of a large number of people, the correspondence of the proportions of the face to the "golden ratio", etc. such facial features are more resistant to mutations and diseases, and on the other hand, people with more symmetrical facial features receive higher beauty ratings when assessing their photos by experts.

AT last years Several pioneering works have appeared on beauty recognition computer systems based on the use of machine vision systems and trainable classifiers. These works can be considered as an attempt to endow robotic systems with the ability to "see the beautiful". In as signs, the proportions of facial features are used, while the key points on the face were selected manually. In addition to proportions, the principal component method was applied to extract features. In the task of recognizing beauty, deep neural networks were used.

We have developed an automatic beauty assessment system based on the method of highlighting key points on the face using the OpenCV machine vision library and neural network, trained on the target task based on expert assessment data, and conducted an experimental assessment of the quality of its work.

Image database for training

We have collected our own image database, consisting of 180 photographs of the faces of young women, the images were taken from open sources. Photographs of faces were selected in the frontal projection with a neutral facial expression, without glasses and jewelry. To make the sample representative, we tried to include examples of both beautiful and ugly faces in the database (Fig. 1).

Rice. 1. An example of a photo of faces from the image database

Unlike the work, the collected database includes photographs of women of different races, skin colors, and their age ranges from 18 to 35 years. After the images were collected, a panel of experts were asked to rate the subjective aesthetic appeal of each of the photographs on a scale of 1 to 7. A total of 8 experts, 4 men and 4 women, aged 16 to 63, were involved in labeling the photographs. scores were given independently. Under the terms of the experiment, before the start of the scoring process, each expert was presented with all the photos for initial review. To check the consistency of the sample, a correlation analysis was carried out, its results are presented in Table. one.

Table 1. Pairwise correlations of assessments of various experts

The average sample correlation turned out to be at the level of 0.7, which makes it possible to train a neural network on such data and roughly corresponds to the results of other researchers.

General scheme of the algorithm

The beauty recognition system receives as input an image containing a frontal photo of a person's face (Fig. 2).

Rice. 2. Scheme of operation of the face beauty recognition algorithm

Before starting the algorithm, we assume that the face in the image has already been selected earlier and occupies most of the image area. Next, using the standard Viola-Jones boosting classifier, which is part of the OpenCV machine vision library, areas on the face are selected corresponding to the right and left eyes, nose and mouth.
Based on these coordinates, the main proportions of the face are calculated, which are then used as a feature vector for the neural network. The neural network is first trained on these inputs, using expert estimates as the target sample, and then can be used for recognition on new data not previously seen by the network.

Feature Extraction

We conditionally divided the features we identified into two groups: the ratio of the distances between the selected key points and the ratios of the found face sizes.

Feature group 1 is shown in fig. 3, left: AB/CD, AC/BC, AD/BD, EC/ED, EC/AB, AC/AD, BC/BD. Feature group 2 is shown in Fig. 3, right: L/R, Mw/Mh, Nw/Nh, Mw/Nw, Mh/Nh. The final feature vector consists of the combined features of both groups. Before being fed into the neural network, the data was scaled to .

Rice. 3. Calculation of feature vectors from selected key points on the face

Training of neural networks

As a trainable neural network, we used a standard multilayer perceptron with one hidden layer containing 5 neurons in the hidden layer. The hyperbolic tangent function was used as the activation functions of neurons in the hidden and output layers. The neural network was trained by the extended Kalman filter method , , which is one of the most effective methods second-order learning for neural networks. Before training, the sample was divided into 2 parts: training (110 examples, 60% of the sample) and examination (70 examples, 40% of the sample). The learning outcomes are presented in Table. 2.

Table 2. The results of neural network training on the problem of beauty recognition

We believe that the result of the correlation of 0.5 on the examination sample that was not used in training is very good for the small amount of information supplied to the neural network as features. In fact, the neural network makes a decision based on the analysis of the structure of the bones of the skull, ignoring other data that a person takes into account when solving a similar problem.
In the future, we plan to improve the algorithm by expanding the image base for training, extracting new key points on the face, and including a skin smoothness detector in it.

Original article (ours): Chernodub A.N., Pashchenko Yu.A., Golovchenko K.A. Neural network system for determining the attractiveness of a person's face // XV All-Russian scientific and technical conference "Neuroinformatics-2013", Moscow, January 21-25, 2013, p. 254 - 259.

Bibliography

  1. Kovach, F. J. Philosophy of beauty//Norman: University of Oklahoma Press. 1974.
  2. Grammer K, Thornhill R. Human (Homo sapiens) facial attractiveness and sexual selection: the role of symmetry and averageness. // J Comp Psychol, 1994. V. 108. No. 3. P. 233-242.
  3. Rhodes G. The Evolutionary Psychology of Facial Beauty // Annu. Rev. Psychol. 2006. V. 57. P. 199-226.
  4. Sheib J.E., Gangestad S. W., Thornhill R. Facial attractiveness, symmetry and cues of good genes // Proc Biol Sci. 1999 September 22; 266(1431). R. 1913-1917.
  5. Holland E. Marquardt’s Phi Mask: Pitfalls of Relying on Fashion Models and the Golden Ratio to Describe a Beautiful Face // Aesthetic Plastic Surgery, 2008. V. 32, No. 2. P. 200-208.
  6. Aarabi, P., Hughes, D., Mohajer, K., Emami, M. The automatic measurement of facial beauty // IEEE International Conference on Systems, Man, and Cybernetics, 710 October 2001, Tucson, USA. V. 4. P. 2644-2647.
  7. Eisenthal Y., Dror G., Ruppin E. Facial Attractiveness: Beauty and the Machine // Neural Computation, 2006. V. 18. No. 1. P. 119-142.
  8. Gan J., Li L., Zhai Y. Deep self-taught learning for facial beauty prediction // Neurocomputing. DOI: 10.1016/j.neucom.2014.05.028
  9. Gray D., Yu K., Xu W., Gong Y. Predicting Facial Beauty without Landmarks // Computer Vision - ECCV 2010, Lecture Notes in Computer Science, 2010, V. 6316/2010. P. 434-447.
  10. Khaikin S. Neural networks: a complete course. M.: Williams, 2006.
  11. Chernodub A.N. Training Neural Networks for classification using the Extended Kalman Filter: A comparative study // Optical Memory and Neural Networks, 2014. Vol. 23, Issue 2, pp. 96-103.

It is clear that every person is beautiful. Especially girls. Especially some. Especially the soul. However, the question is how much? What is the measure of beauty? Grams? Liters? Kilograms? 90-60-90? The new service, created by a team of Swiss scientists and programmers from the laboratory, will analyze the photo in a few seconds and give the result: “Crazy charming!”. If you're lucky.

These guys from the facial recognition lab did a great job of training artificial intelligence and developing criteria for beauty, as we understand it. That is, they taught a machine that, looking at Cindy Crawford, clearly understands that she is a beauty. And when you look at Baba Yaga, he will say - "Well, so-so." In general, the task seems not difficult, but how can we distinguish Cindy Crawford from Baba Yaga? Yes Easy. But to teach this computer was not so easy.

Nevertheless, what has been done deserves high praise. The developers themselves say that the accuracy of the program is 76%.

I tested a bit how it works, and you know what? It really works.

For example, I have always known to myself that I am not handsome. I don't have a pretty face, I mean. The program said so. Like, your way to the podium is ordered, but in general, you are pretty good! Charm!

On the main page of the service, it is proposed to try to evaluate other people's photos or upload your own.

The system will evaluate the photo on a six-point scale and issue approximate age faces in the photo.

And it is right! And you never know, the service is lying! You must first try someone else's, and then entrust your own, dear.

The ratings are located on the scale under the photo and look like this:

  1. Hmm ... - well, so-so, can you make up? 🙂
  2. OK - everything is OK, norms, it will go, a strong middle peasant.
  3. Nice - quite nicho so, even buzzing.
  4. Hot - well, wow, quite even very much!
  5. Stunning - nevermind, super!
  6. Godlike - stunning, godlike, model, in short!

I won Hot, my wife is Godlike. A trifle - but nice)

Let's test Baba Yaga.

Well, you see, OK. In a sense, so-so. You can't really call her ugly, can you? The eyes are tinted and in general, the correct features and all that.

So that people do not get upset, the developers warn that beauty is a purely evaluative and vague matter, and in different countries has different criteria. Therefore, do not worry if your personal assessment goes to the left and gives a little blue.

In any case, we are on the verge of universal digitization and the complete penetration of technology into our lives. Whether this is good or bad is up to you.

Download for iPhone and Android:

The first thing we pay attention to is silhouette and proportions.
Perhaps this is the most important thing in building an image.
Each person has a different type of figure, and each type has its own silhouettes.
A silhouette is an outline of a figure with clothes.
Accordingly, knowing the advantages and disadvantages of his figure,
we can adjust it with the silhouette of clothes.
Inextricably linked with the silhouette and proportions -
this is the ratio of the lengths of horizontal divisions in clothes
to each other and to the overall growth.
The law of the "golden section" applies here, i.e. harmonious combinations perceived by our eyes.
"Golden Ratio" golden ratio, division in the extreme and average ratio) -
division of a continuous quantity into two parts in such a ratio that
the smaller part is to the larger, as the larger is to the whole.

To make it clearer, let's look at an example.

In the left picture, the total length of the blouse to the length of the trousers is related as 1 to 1,
those. The length of the blouse is approximately equal to the length of the trousers.
AT this example this perception is smoothed out due to the same color of the blouse and
trousers. Visually, this is perceived by the eye as insufficient leg length.
How can this be fixed? Add a heel and accentuate the waist with a belt.
On right picture the proportions are harmonious.

So, back to the algorithm for assessing appearance.
The second is legs, or rather, its lower part: shoes, its color and shape.

The shape should be harmonious to the overall silhouette.
The color of the shoes should somehow “put an end” to general way,
to be its harmonious completion.
If it's summer outside, and the shoes open the legs,
then we will definitely pay attention to the well-groomed skin and nails.

The third is head, haircut, hair.

kare-bob haircut


Needless to say, the most best hairstyle is a clean head.
It is also important to note the length of the hair here.
It should be proportional to the overall height of the person, including the height of the heel. Why do so many people ignore this fact?
Here we return to the first point about proportions.

The fourth is face.

First of all, others notice the condition of the skin,
and then everything else. The main thing is the general impression of well-groomed,
and not the make-up itself and its subtleties.

And finally, we come to the fifth point in assessing appearance - this is hands.
Hands betray our age in the first place
and the condition of the skin is much more important here than trendy color varnish in our
manicure. Of course, their general well-groomedness and cleanliness are also important.
It should be noted that optimal length regrown nail - 3-4 mm,
and the sexiest nail polish color is the one that matches the color of the clothes.
And remember that not only you evaluate others, but they also evaluate you.
And these five simple tips help you always look 100%.

The English say: “Hands are what distinguishes true lady from a simple woman

Regardless of whether a man is married or leads a wild life, he always appreciates the women around him. Such is nature - he loves with his eyes. You probably heard, being in men's companies, phrases like: “Here is our new employee, nothing like that, a solid seven”, “Vanka’s wife, of course, is a three”

You can guess roughly what is meant, but the attractiveness scale from 1 to 10 has a certain meaning. Note that every man has his own ideals and ideas of beauty. For one it is “by 9”, for the other it is “by 4”.

They say that this scale went from pick-up artists (men who are interested in the quantitative indicator of women lured into bed), and among normal men has a softer decoding. Editorial "So simple!" decided to tell what is meant by these scores. You should not be offended by men for this, because women also evaluate representatives of the opposite sex. But more about that another time.

Beauty assessment

1 to 3 - ugly

It means a woman who has either serious physical defects or serious mental disorders. Such women tend to excess weight, skin problems, rare hair and bad teeth. This may be due to genetics or be the result of injuries and health problems, excessive smoking and alcohol consumption.

But we'll fix it. If the appearance cannot be corrected in any way without serious investments and plastic surgery, you need to work on your character and personality. Such women also have many successful marriages, because a man should not only see the label, but also feel spiritual comfort.

©DepositPhotos

4 - simpleton

According to men, such a woman cannot be called ugly, but also beautiful or cute too. She has simple appearance without any outstanding features. However, if such a girl is quite smart and interesting, she may well become a conqueror. male hearts. You just need to work on your presentation and style. Perhaps one detail is missing to reach a new level.

©DepositPhotos

5 - average

This is a woman who looks like everyone else. For example, he wears the same haircut and clothes as most, does not really bother with style and the manifestation of individuality. She may have good body and face, but she does not stand out from the crowd. But at proper care for herself, she can have good success with men. It’s not a shame to seduce such a woman, but there’s nothing to boast about either.

©DepositPhotos

6 - well-groomed, sweet

In terms of natural beauty, these women are not written beauties. But they know how to highlight their virtues, which captivates men. Smiling, pretty, she knows what a man wants to see and hear. He himself understands that there is better, but it's nice to spend time with her. Such women are usually docile and willing long term relationship. Very often, men who led a wild life and changed beauties one after another marry such unpretentious, but lovely women.

©DepositPhotos

7 - cute

These are girls with good natural data. Under certain circumstances, they can look beautiful or even hot. We can say that these are women whose bodies men rate as an eight, and their face as a six. With good makeup and nice dress These women can turn a man's head. Representatives of the stronger sex are greedy for their charms and are not averse to showing off such a thing in front of their friends.

©DepositPhotos

8 - really beautiful

This is the woman that most men like. She has a certain charm, you want to look at her, it's nice to look at her. But she doesn't put much effort into it. In other words, these are women who, in addition to right traits face and a good figure, there is also a zest that captivates men so much. They always have a lot of fans, which further fuels the desire of men to meet.

©DepositPhotos

9 - dazzlingly beautiful

This is a woman with bright external data, which even without makeup stands out among other representatives of the fair sex. They are often referred to as sexy. Among them are many famous women: Monica Bellucci, Ornella Muti, Angelina Jolie ... Men admire such beauty and they are not at all concerned about the inner content of these young ladies, their past and outlook on life. They desire to possess them, dream about them and commit thoughtless acts.

But in such beauty there is back side. Very often, such women are unhappy, although they bathe in the attention of gentlemen. After all, they are regarded simply as a label, completely without listening to their desires.


Top