Bug 389549

Summary: "Clear all faces on this image" Does Not Remove All People Tags
Product: [Applications] digikam Reporter: hardy.public
Component: Faces-WorkflowAssignee: Digikam Developers <digikam-bugs-null>
Status: RESOLVED FIXED    
Severity: normal CC: caulier.gilles, metzpinguin
Priority: NOR    
Version: 6.1.0   
Target Milestone: ---   
Platform: Microsoft Windows   
OS: Microsoft Windows   
Latest Commit: Version Fixed In: 6.1.0
Attachments: Before the problem where faces Test4, 5 and 6 are present.
After clear. Test 6 People tag remains.
Another attempt. Test 5 & 6 remain.
Test image
Face Boxes but only in metadata.
Video showing problem.
OK Metadata
Not OK Metadata

Description hardy.public 2018-01-28 11:29:26 UTC
Created attachment 110174 [details]
Before the problem where faces Test4, 5 and 6 are present.

Using this function on the attached image (with Test4,5 and 6 faces) removes the face regions but leaves some People tags embedded.

However it's not always reproducible, say 50%, and the number of People tags removed varies. See both after pictures.

Executing Clear again does not remove the remaining tag. It has to be removed by Remove Tag -> People / TestX
Remove Tag -> People / TestY
Remove Tag -> People / TestZ
etc.
Comment 1 hardy.public 2018-01-28 11:29:59 UTC
Created attachment 110175 [details]
After clear. Test 6 People tag remains.
Comment 2 hardy.public 2018-01-28 11:30:32 UTC
Created attachment 110176 [details]
Another attempt. Test 5 & 6 remain.
Comment 3 hardy.public 2018-01-28 11:34:35 UTC
Created attachment 110177 [details]
Test image
Comment 4 Maik Qualmann 2018-01-28 18:17:18 UTC
Currently I have tested it under Linux and could not reproduce the problem under SQLite or MySQL.

Maik
Comment 5 hardy.public 2018-01-30 19:37:23 UTC
Agreed, there's no problem under Linux. 

I previously reported that the face region remains embedded but I look again and just seems to be a database problem. The face boxes are present but there's no XMP region info embedded in the image. See attached.

I view the same image in Linux and the face boxes are there.
Comment 6 hardy.public 2018-01-30 19:38:04 UTC
Created attachment 110229 [details]
Face Boxes but only in metadata.
Comment 7 hardy.public 2018-01-30 19:47:04 UTC
Further to my previous comment I would have thought reread metadata fixes it but it doesn't.

Is it possible to examine the database tables to confirm that these faces and tags  are present?
Comment 8 caulier.gilles 2019-03-15 10:39:05 UTC
Hardy,

The 6.1.0 pre-release installer have been updated this morning. Please test and
report to see if you can reproduce the dysfunction:

https://files.kde.org/digikam/

Note : reading database table is possible and very simple with SQlite and SqliteBrowser :

https://sqlitebrowser.org/

Gilles Caulier
Comment 9 hardy.public 2019-03-15 18:24:24 UTC
Created attachment 118825 [details]
Video showing problem.

The problem still there unfortunately. I attach a video with ten 10 identical images and "clear faces" on each in turn. Image 5.jpg and 7.jpg have a lingering tag so it's a problem about 20% of the time. Sometimes it's more often. Sometimes it's less.
Comment 10 hardy.public 2019-03-15 18:48:35 UTC
More info: I did the same trial with the same images but in a local collection. Again 3/10 images had lingering Test6 tag. So I guess this eliminates NAS collections as a causal factor.
Comment 11 hardy.public 2019-03-15 18:58:05 UTC
Created attachment 118826 [details]
OK Metadata

Yet more info: Also confirmed this is not a database problem because I confirmed the XMP metadata is definitely present using another tool.
Comment 12 hardy.public 2019-03-15 18:58:29 UTC
Created attachment 118827 [details]
Not OK Metadata
Comment 13 Maik Qualmann 2019-03-25 21:22:19 UTC
Git commit 38641a8cf4693399f32a89c49afd1fd26a8b9538 by Maik Qualmann.
Committed on 25/03/2019 at 21:21.
Pushed by mqualmann into branch 'master'.

remove all face tags with a write operation
If the re-scan option was enabled,
the tags were added again.
FIXED-IN: 6.1.0

M  +2    -1    NEWS
M  +7    -6    core/utilities/facemanagement/facegroup.cpp

https://commits.kde.org/digikam/38641a8cf4693399f32a89c49afd1fd26a8b9538