Hacker Newsnew | past | comments | ask | show | jobs | submitlogin
Chernoff face (wikipedia.org)
221 points by Pete_D on March 23, 2018 | hide | past | favorite | 36 comments


I worked with Chernoff faces long time back and love how this is an interesting way to visualize how discriminative your features are.

The idea is that you take features of your dataset, and use those to represent a face. Say for example, you want to classify 100 people based on different features. And let's say you've collected 15 features for each person (e.g., height, weight, shoulder width, length of first name, length of last name, type of car driven, etc.). Now try mapping each of these features to Chernoff faces. You'd map it in the following manner: height->area of face, weight->shape of face, shoulder width->length of nose, length of first name->location of mouth, length of last name->curve of smile, type of car driven->width of mouth, etc.

Once you've mapped in that fashion and visualize the faces, you can observe how discriminative your features are. How do you interpret this? If your Chernoff faces tend to show a lot of variation in expression (e.g., smiling vs. sad), you say the length of last name is more discriminative. On the other hand, if the faces all appear to have same area, your first feature (i.e., height) is not very discriminative.

Other features used for Chernoff faces could be: location, separation, angle, shape, and width of eyes; location, and width of pupil; location, angle, and width of eyebrow, etc.

One drawback (as listed in the Wikipedia page) is that we humans perceive the importance of these faces by the way in which variables are mapped to the Chernoff facial features. If the feature mapping is not carefully chosen, your largest varying feature may be ignored because we appreciated the change in expression more than the change in eyebrow length.


> this is an interesting way to visualize how discriminative your features are.

I don't get why that is easier or more revealing than doing a principal component analysis (?)


Because recognising faces is an innate human ability while calculating eigenvectors is not.


That's why we get computers to calculate eigenvectors and plot the result in a nice graph that humans are fine at interpreting.


I agree. I don't think this isn't any more revealing. Just a different way of visualizing. And there is also the drawback of a whole new interpretation when you re-map your input features to Chernoff facial features.


That's what I'm struggling with. Take the example on the Wikipedia page: I don't know what the faces mean for each judge. Is the judge a jerk? Does the judge take too long with their arraignments? Is this a value, er, judgment on the legal sufficiency of their determinations?

If the primary utility is to be able to quickly visually discriminate values once you know how they're encoded into facial features, then I can see the value, but again you'd have to know the encoding. Or have I missed the point completely?


Yes, the primary utility is to understand how discriminative your features are. There is no meaning of what each face represents.

Checkout the Chernoff Fish demo posted below by the user meagher here: https://news.ycombinator.com/item?id=16664051. Play with different features, say for example, 'performance'. When you change the value of 'performance', the eye size changes. However, the eye size doesn't mean anything except for you to visually understand variations in data. If 'performance' was mapped to, say, fin size, it doesn't change its meaning.


I wonder how this affects pattern recognition.

Would people more readily recognize that say, "Large Spiky Orange Fish" strategies lead to greater returns, compared to if the strategies were presented as "Short | Value Investment | Large Market Capitalization"?

This could also be an interesting way of eliminating inherent bias while leveraging human pattern recognition abilities. Represent values pictorially, and hide data labels.


Thanks, I think I understand its utility a bit better now.


It's not meant for professional data analysis use. It's a gimmick for kids or for printing in a magazine article.


Because humans are naturally good at recognizing faces and the differences between them.


The Wikipedia example (Chernoff faces for lawyers' ratings of twelve judges) would make a whole lot more sense if they mentioned what properties of the judges were being mapped to which facial features.

Here are the Lawyers' Ratings of State Judges in the US Superior Court:

https://www.rdocumentation.org/packages/datasets/versions/3....

And here is the R code:

  library(TeachingDemos)
  svg("Chernoff faces for evaluations of US judges.svg", height=6, width=8)
  faces2(USJudgeRatings[1:12,c(2:11,2:9)]/5-1, scale="none")
  dev.off()
Could someone who knows R and where to find the faces2() function give us a legend (i.e., a table of judge's property to facial feature)? Maybe we can add that into Wikipedia afterward too.


Thanks for finding this, the lack of explanation in the Wikipedia article was driving me crazy. Here’s what the `TeachingDemos::faces2` documentation says about the feature mapping:

> The features are: 1 Width of center 2 Top vs. Bottom width (height of split) 3 Height of Face 4 Width of top half of face 5 Width of bottom half of face 6 Length of Nose 7 Height of Mouth 8 Curvature of Mouth (abs < 9) 9 Width of Mouth 10 Height of Eyes 11 Distance between Eyes (.5-.9) 12 Angle of Eyes/Eyebrows 13 Circle/Ellipse of Eyes 14 Size of Eyes 15 Position Left/Right of Eyeballs/Eyebrows 16 Height of Eyebrows 17 Angle of Eyebrows 18 Width of Eyebrows

So there are 18 visually distinguishable features, and the code maps the columns 2–9 redundantly to two features each, and columns 10–11 to one feature each. I don’t understand how the scaling was chosen — the function requires the values to be in the interval [0, 1] but since the original scores appear to be in [0, 10], a more natural transformation would be to just divide by 10 instead of `x / 5 - 1`. Obviously these two transformations result in markedly different faces.

If I find time later I’ll upload an updated plot that includes a legend. Unfortunately that’s not easy since the `faces2` function overrides R’s plot layout so there’s no space to fit the legend.


I’ve found some time to add the mapping as a table to the Wikimedia image [1]. Not sure how to best refer to this inside the article. Having it inside the image itself proved problematic (the resulting plot became too big to be readable inside the article) so I ended up not doing that in the end.

[1] https://commons.wikimedia.org/wiki/File:Chernoff_faces_for_e...


I made a Chernoff Fish generator with D3 & React a while back: http://tmm-archive.github.io/chernoff-fish/

All the code is on GitHub: https://github.com/tmm-archive/chernoff-fish


I suggest reading "Ross-Chernoff Glyphs Or: How Do We Kill Bad Ideas in Visualization?" (https://research.tableau.com/sites/default/files/altCHI-prep...), a paper on why Chernoff faces are bad by taking them to the extreme with Bob Ross.


Great recommendation. It's snarky, but entertaining and raises some good questions.

> Using a neural net... would be a useful way of generating custom Ross-Chernoff plots, and also allows me to include “deep learning” in the author keywords.


A great read, thank you!


Just read about this in Blindsight.

A vampire had hologram faces of tortured humans as graphs


Quoting from Peter Watts' book: http://www.rifters.com/real/Blindsight.htm

A sea of tortured faces, rotating in slow orbits around my vampire commander.

"My God, what is this?"

"Statistics." Sarasti seemed focused on a flayed Asian child. "Rorschach's growth allometry over a two-week period."

"They're faces…"

He nodded, turning his attention to a woman with no eyes. "Skull diameter scales to total mass. Mandible length scales to EM transparency at one Angstrom. One hundred thirteen facial dimensions, each presenting a different variable. Principle-component combinations present as multifeature aspect ratios." He turned to face me, his naked gleaming eyes just slightly sidecast. "You'd be surprised how much gray matter is dedicated to the analysis of facial imagery. Shame to waste it on anything as—counterintuitive as residual plots or contingency tables."

I felt my jaw clenching. "And the expressions? What do they represent?"

"Software customizes output for user."


Such an excellent book, so many out-there ideas. My favourite is the idea that, since it takes resources to process information, an alien species might construe our ceaseless blathering into the void as aggressive action, a sort of lame DOS attack.


Reminds me of the Doom status bar face. Pretty straightforward when you're visualizing one value. [http://doom.wikia.com/wiki/Status_bar_face]


Chernoff faces are pretty fun to play with too! A while back, I played with it[1], and they do seem useful. I wonder if more realistic faces lead to better utility as a at-a-glance data visualization tool?

[1]: https://gnarmis.github.io/chernoff-faces/ -- a simple toy


This is brilliant, can be better than pie charts in some cases.

For example, here are Chernoff Faces of some Turkish Universities: https://ibb.co/nFAoC7

The size of the eyes represents the number of projects submitted to TUBITAK(Govt science body that coordinates and provides funding), the size of the nose represents the number of projects that are accepted. The size of the face is the number of professors in the institution and the size of the mouth is the number of publications.

So, if you are looking for Turkish Universities that have lot's of accepted projects look for a big nose. Big eyes and small nose will be an indicator for a large number of failed applications and a face that has a huge mouth but small nose and eyes is an indicator for an institution with lot's of publishing going on without seeking funding to projects.


Why would you not use a series of bar charts for that?


As a prosopagnosiac, this is sort of like a feature in a firmware I don’t have the license key to unlock.


Chernoff Faces are one of those HCI ideas that seem clever but have never really worked great in practice. See also: pie menus, zoomable user interfaces. At least those latter two show up occasionally in real products, I don't think I've ever seen Chernoff Faces used in a final product.


Can someone post examples? Most of the Wikipedia links are dead.


All of the links should be in the Internet Archive. (I wrote OP and the links would've been included in my archive queue at the time.)

FWIW, as much as I liked the idea of Chernoff faces after running into them in _Blindsight_, I was never able to find a productive use for them where they were really all that much a better visualization than, say, a bunch of scatterplots or fancier techniques like t-SNE.


I think they could be good to detect small changes.



Here's a few in a bad Imgur gallery. This is taken from Computers, Pattern, Chaos, and Beauty (Clifford Pickover. Published in 1990.)

https://news.ycombinator.com/item?id=16667787


The book Computers, Pattern, Chaos, and Beauty has some nice examples of Chernoff faces used to represent DNA sequences or characteristics of sound.

It's still available, and there are pirate versions if you want to try it before buying it. It's a great book, it's chock full of odd ways to visualise data.


Here's an Imgur gallery from the book with a lot more info about these faces.

Chernoff Faces https://imgur.com/gallery/ES3in


What does it mean that the second faces in the top two rows are indistinguishable? I guess maybe Burns is smiling a little more?


Their data are very similar, to the extent your brain can tell.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: