Bug 457225

Summary: Make use of existing people tags
Product: [Applications] digikam Reporter: S. Burmeister <sven.burmeister>
Component: Faces-RecognitionAssignee: Digikam Developers <digikam-bugs-null>
Status: RESOLVED WORKSFORME    
Severity: wishlist CC: jose_oliver, metzpinguin
Priority: NOR    
Version First Reported In: 7.7.0   
Target Milestone: ---   
Platform: Microsoft Windows   
OS: Microsoft Windows   
Latest Commit: Version Fixed/Implemented In: 7.8.0
Sentry Crash Report:
Attachments: Filter option for people tags with no face regions.

Description S. Burmeister 2022-07-28 07:51:26 UTC
SUMMARY
If one has a collection which does already have people tags, digikam does not make any use of this information it for its face detection/recognition. That seems inefficient.

STEPS TO REPRODUCE
1. Add people tags to pictures (with digikam)
2. Start digikam from scratch and point it to the collection created above. The people tags are imported and shown in the tags tab.
3. Open the people tab

OBSERVED RESULT
1. no people are shown, although the tag tree features people. There is just unconfirmed, unknown and ignored.
2. starting a search for faces and link tags to faces afterwards, starts from scratch and does not re-use any information provided by the existing people tags

I assume this is because the information about the face location is missing and digikam only knows that there is a person on the picture but not where.

EXPECTED RESULT
1. Show all names from the people tag tree in the face recognition, empty. This saves having to type each people tag again.
2. If only one face is found on a picture and the picture has a people tag, put that picture in the "unconfirmed" section of the people tag - not in the "unknown" section. That way the user can quickly educate the engine with "pre-tagged" pictures one only has to confirm.
3. Add an option to only scan for faces on pictures with a people tag. This way the "unknown" and "unconfirmed" section is filled quicker and the user can educate the engine quicker.
Comment 1 Maik Qualmann 2022-07-28 09:01:13 UTC
The training database must first be built up, this does not happen automatically for reasons of speed. Go to Maintenance Tool, in the Face Recognition section select the Build training database checkbox and run the process.

Maik
Comment 2 S. Burmeister 2022-08-04 17:09:35 UTC
Sorry, but after a few thousand more clicks I have to disagree that this works. Simple example.

A picture has a people tag assigned but no confirmed face. Digikam finds one face on the picture. Which people tag should be suggested? Obviously the people tag which is already assigned to the picture, even if not to the found face. Digikam ignores this information and suggests some other tag. My guess is that digikam does not even try to use the information already available for the picture, i.e. does not check for people tags assigned to the picture but not to the one single identified face on the picture.

Another example I come across frequently: Digikam finds two or more faces on a picture. One face has already assigned a people tag, let's say "Peter". How likely is it that the same person is twice on the same picture? Anyhow, digikam frequently suggests the people tag for an unrecognised face which is already assigned to another face on the picture. Of course it is possible, i.e. a mirror, but unlikely.
Comment 3 Maik Qualmann 2022-08-04 20:12:15 UTC
I re-read the description of your bug. Rebuilding your collection assumes that your face regions have been written to the metadata. Otherwise the people tags cannot be rebuilt. The training database must also be rebuilt afterwards, but if there are no people tags/face regions, it makes little sense.

No, we don't look at which people tags are already set on the image. In most cases this doesn't make any sense. Yes, we have many bug reports to improve face recognition.

Keep in mind that the face engine "learns" when assigning faces. I'm getting close to 100% face recognition on some faces with my collection.

Maik
Comment 4 José Oliver-Didier 2022-09-04 14:02:04 UTC
Created attachment 151816 [details]
Filter option for people tags with no face regions.

I am guessing the aim with this reported issue is to utilize people tags with no face regions associated with them to improve the people tagging workflow. It seems to me that Digikam's Filter options are better suited for this. Adding a checkbox to filter for people tags with no confirmed face regions associated with them. Ref attached image.
Comment 5 Maik Qualmann 2022-09-04 16:37:20 UTC
In digiKam-8.0.0 in the advanced search it will be possible to search for a certain number of face regions or for images with no face region.

Maik