[KPhotoAlbum] Face detection and face recognition

Tobias Leupold tobias.leupold at web.de
Wed Jul 9 16:42:15 BST 2014


Hi List!

Now that we can mark areas on an image and associate them with tags, we can go 
one nice step ahead. I added face detection and face recognition using 
Digikam's libkface.

Please have a look at:

	https://github.com/l3u/kphotoalbum/tree/facemanagement

This is quite a big patch. As there were changes and additions throughout the 
code, it was not really possible to split the changes in different independent 
patches. The current state is based on current git master as of the time of 
this writing. I'm pretty sure that all this is far from production quality, 
but it's usable. Of course, this is nothing for the upcoming release, as it 
has to be tested from end to end.

Please notice that you need the current git master of libkface ( 
http://quickgit.kde.org/libkface.git -- version 3.2.0) for this to work, as I 
also had to add a new function to libkface's API to be able to implement some 
database maintenance.

When there's no appropriate version of libkface at build time, KPA should 
build as ever, simply leaving out the new functionality. When we have it, a 
"Search for faces on the current image" button is added to the annotation 
dialog's image preview, along with some additional context menu entries for 
the areas and a new settings page.

Regarding face detection, it was no big deal to implement it and the results 
are quite okay. Face recognition is a bit more tricky, as we have to keep the 
recognition database in sync with KPA's database. The quality of the 
recognition was moderate to impressive -- depending on the image sets I used 
to test it (but it's the deal of the libkface guys to improve that ;-)

So ... please check out the code :-)

Yours, Tobias



More information about the Kphotoalbum mailing list