| Summary: | Face tag subfolders get converted to backslash instead of forward slash when metadata reread | ||
|---|---|---|---|
| Product: | [Applications] digikam | Reporter: | deryk.lister |
| Component: | Metadata-Xmp | Assignee: | Digikam Developers <digikam-bugs-null> |
| Status: | RESOLVED FIXED | ||
| Severity: | normal | CC: | metzpinguin |
| Priority: | NOR | ||
| Version First Reported In: | 8.1.0 | ||
| Target Milestone: | --- | ||
| Platform: | Microsoft Windows | ||
| OS: | Microsoft Windows | ||
| Latest Commit: | https://invent.kde.org/graphics/digikam/-/commit/d4fa68a90e090d434ea33fe2b0c5889d6f68366c | Version Fixed/Implemented In: | 8.2.0 |
| Sentry Crash Report: | |||
|
Description
deryk.lister
2023-08-02 08:13:16 UTC
Tested latest weekly 8.2.0 build, same result This is not a bug, you can only enter names when assigning faces, not names with a path. "The entry "Famous/King Charles" is seen as a full name, in this case, since the slash is not allowed in names, we convert it to a backslash. Even if we manage names in a hierarchy in the People Tags Tree , this cannot be represented in metadata, it is a flat list of names. Maik As a fix, we will disallow the slash when entering people names. Maik That seems odd as the name works perfectly with a path internally and treats it, as expected, as a path inside "People" so that you can organise your people into groups. It's only when writing metadata to file and re-reading it again that your arbitrary rule seems to enforce itself and create a duplicate tag. Yes, we will fix it, we don't store the last part of the name in the face metadata. Maik A corresponding patch is in the works. But, don't create another face name like this with a slash. You must delete all face names created in this way. Even if it looks correct in the tags tree, a single name is created with slash. It's amazing that nobody has triggered this problem in years. Maik Thanks for the update. I think I understand now! From an end user perspective my main concern was just the end result: whether I was stuck trying to tag a few hundred people but have them all listed in one lump rather than be able to group them into "Staff", "Public Figure", etc. Having no structure to them would be a nightmare. As we're looking at it from different perspectives, your comment from your perspective of "that's not a bug" worried me that I was stuck having to completely rethink the structure. As it turns out, it seems what I want *is* achievable, I've just been creating the "Parent" tags (folders, so to speak) in an unexpected way that put a face tag of say "Famous\King Charles" into the database whilst the tag side of things sorted itself out and hid the problem. I uncovered the symptoms when wanting to copy face tags from one photo to another and hearing it was only possible via exiftool and doing that (so copying the metadata from photo A to photo B then loading it with the reload from file menu). To me my attempted usage makes sense, as it's how it can work throughout the UI - when creating a new tag directly on an image, the UI invites you to create a tags hierarchy like "Country/City/Paris" by typing it that way and it creates the whole structure if it's missing (sort of like a mkdir -p). So this is how I created my first staff tag - I typed in "Staff/Fred Smith" into the face tagging UI which "works" superficially (but breaks things underneath). When I was experimenting just now and pre-created my structure (including names) in Tag Manager first then just *selected* them when face tagging, I'm finding it works fine and still keeps the grouping. But selecting names that existed from when I did it "wrong", even without typing any slashes into the face tagging UI, pulls the incorrect backslashed-form from the backend somewhere. I have a lot of broken face tags in this way at the moment but it seems I have a workaround to fix them: 1. In the People UI, rename say "King Charles" to "King Charles II". In the metadata, "Region Name" and "Region Person Display Name" change from "Famous\King Charles" to "King Charles II". 2. Rename him back to "King Charles". In the metadata, "Region Name" and "Region Person Display Name" change from "King Charles II" to "King Charles" (so it's now corrected) So it looks like I can repair them all "fairly easily" by renaming them in the People UI and just adding a 1 on the end or something and then renaming them all back again, whilst retaining the hierarchical tag structure I wanted. The obvious flaw here in face data being flat whilst the associated tags can be hierarchical, is when you have a John Smith under "Famous" and a different John Smith under "Staff", it's the same name so seen as the same person. Luckily not a scenario I've had to deal with yet. Git commit d4fa68a90e090d434ea33fe2b0c5889d6f68366c by Maik Qualmann. Committed on 02/08/2023 at 22:42. Pushed by mqualmann into branch 'master'. allow to create face tags by path FIXED-IN: 8.2.0 M +1 -1 NEWS M +11 -1 core/app/items/overlays/assignnameoverlay.cpp M +3 -9 core/libs/database/tags/facetags.cpp M +11 -1 core/utilities/facemanagement/items/facegroup.cpp https://invent.kde.org/graphics/digikam/-/commit/d4fa68a90e090d434ea33fe2b0c5889d6f68366c |