views:

781

answers:

6

I'm quite curious about this since it's quite a leap in image processing.

In a broad way, how would one do face recognition on a bitmap?

Edit: My intention is a brief description on how a face is recognized. Not for comparison. Just how to recognize that there is a face in a bitmap.

The Wikipedia article is sparse on algorithm explanation.

A: 

Look at it and see if you spot someone familiar. Then start zooming in, significantly enhancing the resolution on the fly by hammering on random keys on your keyboard. That's how it works on CSI.

steffenj
i know, not helpful, but i couldn't resist :) (i'm sorry, sometimes you just have to do these posts on the Internets)
steffenj
rather non-sense answer, but made my day :)
OregonGhost
In terms of humour, yeap great answer. I'm just to focused on the Crack Overflow and gave you a down...
Gustavo Carreno
@Gustavo: Don't be a jerk.
@Mike F: I'm not being a jerk, I'm just sticking to the "rules". I really liked his answer in terms of humour, I DID !!! It even made me laugh :D
Gustavo Carreno
No offense taken. This question was just sooo set up for this answer. I don't care about the negative votes, it's worth it. ;)
steffenj
+2  A: 

Wikipedia covers this quite well.

Edit: If that's insufficient, try Google.

A: 

Probably detecting parts of someone's face, like nose, eyes, mouth, and comparing to a known picture using some statistic model.

Edit: To know that there's face in a bitmap, I'd say you need to use something like an edge detection algorithm, which would, very basically speaking, look for great differences in adjacent pixels, and if the difference formed a shape. Then it would check if the shape resembled a face. Also, a face is most likely accompanied by a body, so it should look for it aswell.

jmissao
+1  A: 

As this is quite a hot topic at present I suspect companies will keep their precise workings secret.

An image is like a big array of color values that you will need to process.

I guess a face recognition model would have to look for: Key features Distance between features e.g the mouth and eyes will always be a certain range of distance apart Range of colors and grouping of colors together

You could also process the image against a database of known face signatures

When processing an image you could never be 100% sure that you have recognised a face so you would calculate a certainty score based on the finding of a number of factors e.g feature found, distance between eyes nose etc.

It would be worth taking a look at fuzzy logic e.g. http://en.wikipedia.org/wiki/Fuzzy_logic

alexmac
Fuzzy logic is maybe interesting background reading, but it's not very relevant.
dmazzoni
Hmm I disagree using Fuzzy logic would be one approach to this issue its also connected to another of other AI type topics which would be useful reading.
alexmac
+3  A: 

Depends on your application.
Simple fast algorithms built into digital cameras use hought transforms to find a pair of circles (eyes) in the top half of a roughly circular shape (face) - it's surprisngly effective if you just want to autofocus on the correct area of the scene.

More complex applications generally use genetic algorithms and a training set ofimages combined with a background removal.

The free OpenCV library has a bunch of samples.

Martin Beckett
+2  A: 

Face recognition is an active area of research in computer science. Unlike simpler image processing tasks like resizing, sharpening, or adjusting colors in an image, where the basic algorithms are well-known, there are many different approaches for face recognition. Today, there are lots of approaches that seem promising, but most ideas are still rather new, and none of them are anywhere close to perfect, so it's harder to find a good tutorial on any one.

If you want to write or implement a face recognition algorithm, one thing you will definitely need is a collection of face images that are already labeled. If you're just trying to detect faces, you'll want images labeled with the location and size of all actual faces in each image. If you're trying to recognize specific faces, you'll want a database with thousands of people and all of the different pictures of the same person clearly labeled as such. You'll need these images both to train your system and to test it to see how well it works.

Luckily some free databases like this are available online, but some commercial companies are able to get an edge over competition not just with a better algorithm, but with a larger and more extensive collection of training data.

In any case, face recognition is very complicated and there aren't any short, simple algorithms that work very well at all. Most approaches require advanced signal processing and linear algebra, for example.

You will need to study textbooks on signal processing, linear algebra, pattern recognition, machine learning, and computer vision just in order to understand the latest research in this field. Once you are comfortable with the basics, you can use a website like http://www.face-rec.org/ as a starting point to start reading some of the more influential papers.

dmazzoni