Bug 421023 - Face tagging quirky in digiKam 7.0.0-beta3
Summary: Face tagging quirky in digiKam 7.0.0-beta3
Status: RESOLVED FIXED
Alias: None
Product: digikam
Classification: Applications
Component: Faces-Engine (show other bugs)
Version: 7.0.0
Platform: Microsoft Windows Microsoft Windows
: NOR normal
Target Milestone: ---
Assignee: Digikam Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-05-04 21:04 UTC by Tom Cunningham
Modified: 2021-06-04 19:59 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In: 7.0.0
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tom Cunningham 2020-05-04 21:04:17 UTC
I usually tag faces in digiKam by clicking on the "Add a face tag" button, drawing a rectangle around the face, and filling in the name (which digiKam often completes for me).  In the latest beta3, after I draw the rectangle and fill in the name, the rectangle moves to the left and above the face and shrinks to about a tenth of the original size.  Also, the entire process of adding the tag seems a bit more sluggish than in previous versions.  It seems to work correctly when I repeat the process on the same face, but I don't want to be tagging the same face twice in the workflow.


STEPS TO REPRODUCE
1. Click the "Add a face tag" button on the preview window.
2. Draw a rectangle around a face and fill in the name.
3. Check the tag by moving the mouse over the face.

OBSERVED RESULT
The tag rectangle will not appear around the face, but may be elsewhere in the picture at a reduced size.


EXPECTED RESULT
Usually when moving the cursor over a face, the tag name and rectangle will appear framing the face.

SOFTWARE/OS VERSIONS
Windows: Windows 10 Pro Version 1909

ADDITIONAL INFORMATION
Comment 1 Maik Qualmann 2020-05-05 04:24:49 UTC
The problem cannot be reproduced here. At the moment I have no idea what the cause would be. Does it only occur with certain images? Can you test the current release candidate?

Maik
Comment 2 Tom Cunningham 2020-05-05 05:18:54 UTC
It happened with digiKam-7.0.0-beta3-20200422T165716-Win64-debug.exe, with all the images I was attempting to tag.  It has never happened with previous versions, including digiKam-7.0.0-beta2-Win64.exe.  Is there a particular version you'd like me to try?
Comment 3 Maik Qualmann 2020-05-05 05:38:12 UTC
Can you please try the release candidate from here:

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

Maik
Comment 4 Tom Cunningham 2020-05-05 14:07:30 UTC
Seems OK with digiKam-7.0.0-rc-20200504T215247-Win64.exe, although still uncharacteristically slow to confirm tag placement when mousing over face.  Will mark as RESOLVED.
Comment 5 Tom Cunningham 2020-05-10 21:28:09 UTC
Still happening with digiKam-7.0.0-rc-20200504T215247-Win64.exe.  Note that, since updating the face tag is noticeably slower (5-10 seconds), if I start tagging another face before the first one is "finished," that's when the bad behavior happens (e.g. the rectangle is not on the face but up and to the left and a lot smaller).  Also remember that this does not happen with beta2 and before.  The workaround for now is simply to wait: type in the name, click "confirm", wait until the accompanying thumbnail becomes a blue field for a few seconds, then returns, and I believe the tagging then remains correct.
Comment 6 Maik Qualmann 2020-05-11 06:35:14 UTC
We have introduced an additional event to update the tags view when face tags are changed. It could be related. I can temporarily undo it for testing. Do you have a lot of tags? Nevertheless, 5-10 seconds seem extremely long to me. SQLite or MySQL DB?

Maik
Comment 7 Tom Cunningham 2020-05-11 18:07:13 UTC
I have ~13,560 face tags, ~22,300 location tags, and I use SQLite for the database.
Comment 8 Maik Qualmann 2020-05-12 05:59:04 UTC
Git commit 1e88b3a88c20492705de121c13d06fce4b312262 by Maik Qualmann.
Committed on 12/05/2020 at 05:56.
Pushed by mqualmann into branch 'master'.

disable updating the tag list for a test

M  +2    -2    core/libs/database/coredb/coredb.cpp

https://invent.kde.org/kde/digikam/commit/1e88b3a88c20492705de121c13d06fce4b312262
Comment 9 Kristian Karl 2020-05-12 19:39:56 UTC
I have too experienced the sluggish behavior described here.
When I tested with https://invent.kde.org/kde/digikam/commit/1e88b3a88c20492705de121c13d06fce4b312262 in place, the performance is back to normal.
Comment 10 Maik Qualmann 2020-05-12 20:34:07 UTC
Git commit a4eb78aa70b6c8c0755ffae95335cb05ae55bc65 by Maik Qualmann.
Committed on 12/05/2020 at 20:32.
Pushed by mqualmann into branch 'master'.

fix slowdown when updating face tags counter
FIXED-IN: 7.0.0

M  +2    -1    NEWS
M  +3    -1    core/libs/album/manager/albummanager.h
M  +15   -1    core/libs/album/manager/albummanager_falbum.cpp
M  +2    -1    core/libs/album/manager/albummanager_p.h
M  +10   -7    core/libs/album/manager/albummanager_talbum.cpp
M  +0    -2    core/libs/database/coredb/coredb.cpp
M  +0    -1    core/libs/database/coredb/coredbchangesets.h
M  +10   -2    core/libs/models/albummodel.cpp

https://invent.kde.org/kde/digikam/commit/a4eb78aa70b6c8c0755ffae95335cb05ae55bc65
Comment 11 Maik Qualmann 2020-05-12 21:21:00 UTC
Git commit e4cd7b5fb4088cbfc286b5de5bf579fb063d3733 by Maik Qualmann.
Committed on 12/05/2020 at 21:19.
Pushed by mqualmann into branch 'master'.

polish the face tag counter update

M  +2    -2    core/libs/album/manager/albummanager.h
M  +2    -14   core/libs/album/manager/albummanager_falbum.cpp
M  +1    -1    core/libs/album/manager/albummanager_p.h
M  +2    -2    core/libs/album/manager/albummanager_talbum.cpp
M  +17   -4    core/libs/models/albummodel.cpp

https://invent.kde.org/kde/digikam/commit/e4cd7b5fb4088cbfc286b5de5bf579fb063d3733
Comment 12 Kristian Karl 2020-05-13 13:28:25 UTC
For me, it works as expected again.
Thanks for the fix :-)
Comment 13 Tom Cunningham 2021-06-04 19:59:34 UTC
Works well for me now in 7.2.0!