MyMoustache.net Succeeds with Microsoft Project Oxford Face API

Posted by Ryan Galgon, Senior Program Manager in the Technology & Research group at Microsoft.

Last month we announced new features for Microsoft Project Oxford machine learning APIs, including the addition of emotion, video, spell check, speaker recognition, the Custom Recognition Intelligent Service and improvements to our existing Face APIs.

With Project Oxford, developers across different platforms can easily add intelligence into their applications without having to be AI experts. Project Oxford is just one instance of a broader class of work Microsoft is pursuing around artificial intelligence, and our vision for more personal computing experiences and enhanced productivity aided by systems that increasingly can see, hear, speak, understand and even begin to reason.

With all this interesting new technology at our fingertips, and inspired by our previous showcase sites How-Old.net and TwinsOrNot.net, we decided to have some fun. We used the facial hair detector – which allows developers to see hair length on the moustache, beard and sideburn regions of the face – to create MyMoustache.net. This site showcases the Face API and helps raise awareness for men’s health through our collaboration with the Movember Foundation.

The experience asks you to simply select a photo and returns a rating of your facial hair, pitting you against the rest of the players to see how your ‘stache stacks up against the world average. No ‘stache, no problem. With the Auto-stache feature you can instantly grow your own moustache which is placed directly on your upper lip using the 27-point face landmarks given by Face API.

Jokes aside, one might ask what it takes to train a new ML algorithm, specifically one that measures facial hair? We took it as a classification problem. Face hair normally grows on three face areas: moustache above lips, beard under lips, and sideburns in front of ears. “Density” is introduced to describe how bushy that facial hair is in those face areas – level ranges include clean-shaven (no facial hair) stubble, medium and bushy.

Based on an image by Roger Zenner and modified by Nordelch, sourced from Wikipedia. This file is licensed under the Creative Commons Attribution-Share Alike 3.0 Unported license.

Each category definition was discussed and clearly understood. Then we started data tagging and the first round of facial hair model training. As always, the first model was not quite satisfying. For example, it was not very stable on sideburns density. By carefully adding more training data and adjusting the model parameters and more training rounds we got a working facial hair model. Our approach simplifies the problem of classifying the type of facial hair, opting for flexibility of interpretation of our results. The resulting API returns a numerical value from 0.0 to 1.0 for each hair region, where 0.0 represents no facial hair and 1.0 represents “sufficiently long”.

With this length value and a month full of Movember data from MyMoustache.net, we can find interesting trends across the world. North America tops the charts for continent with highest average moustache length followed by South America, Europe, Oceania, Asia, and finally Africa. Out of the 145 countries that participated, Mauritius tops the charts for the highest average moustache length followed by Isle of Man, then Aruba.

From the countries participating, 39 countries reached “ultimate mo” status by achieving a perfect 1.0 moustache length. That’s 27 percent of all countries! The countries that achieved this honor are:

Argentina

 

Czech Republic

 

Latvia

 

South Africa

 

Australia

 

Denmark

 

Moldova

 

Spain

 

Austria

 

Germany

 

Netherlands

 

Sweden

 

Belarus

 

India

 

New Zealand

 

Taiwan

 

Brazil

 

Iran

 

Norway

 

Thailand

 

Bulgaria

 

Ireland

 

Pakistan

 

Turkey

 

Canada

 

Italy

 

Poland

 

Ukraine

 

China

 

Japan

 

Portugal

 

United Kingdom

 

Colombia

 

Jordan

 

Romania

 

United States

 

Croatia

 

Kazakhstan

 

Russia

 

 

Movember might be done, but you can still check out MyMoustache.net. Share your results with the rest of the world at #MyMoustacheRobot. Facial hair characteristics along with other improvements will be coming soon to Face APIs. Visit www.ProjectOxford.ai to try our Face APIs and other cool ML technology today.

Ryan
Subscribe to this blog