[Bug 271030] New: Windows Live Photo Gallery people tagging Compatibility

classic Classic list List threaded Threaded
35 messages Options
12
Reply | Threaded
Open this post in threaded view
|

[Bug 271030] Windows Live Photo Gallery people tagging Compatibility [patch]

Bugzilla from leif@dkstat.com
https://bugs.kde.org/show_bug.cgi?id=271030


Leif Huhn <[hidden email]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
  Attachment #61766|0                           |1
        is obsolete|                            |




--- Comment #19 from Leif Huhn <leif dkstat com>  2011-07-12 05:32:08 ---
Created an attachment (id=61791)
 --> (http://bugs.kde.org/attachment.cgi?id=61791)
Revision 3

--
Configure bugmail: https://bugs.kde.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[Bug 271030] Windows Live Photo Gallery people tagging Compatibility [patch]

Bugzilla from leif@dkstat.com
In reply to this post by harry
https://bugs.kde.org/show_bug.cgi?id=271030





--- Comment #20 from Leif Huhn <leif dkstat com>  2011-07-12 05:33:15 ---
Created an attachment (id=61792)
 --> (http://bugs.kde.org/attachment.cgi?id=61792)
Revision 2 to 3 interdiff

--
Configure bugmail: https://bugs.kde.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[Bug 271030] Windows Live Photo Gallery people tagging Compatibility [patch]

Bugzilla from leif@dkstat.com
In reply to this post by harry
https://bugs.kde.org/show_bug.cgi?id=271030





--- Comment #21 from Leif Huhn <leif dkstat com>  2011-07-12 15:07:17 ---
I have looked at bug 268688 (DigiKam won't delete tags in metadata).  Until
that bug is resolved, I suppose I could implement the same logic for faces as
we have for tags now.  The downside is that it would be impossible to delete a
face from the tags.  For tags there is a workaround (bug 268688 comment #8).  I
don't believe the workaround would work for faces because there is no panel for
editing face tag data.

Also, faces are more complicated.  What do we do in this situation?

1. User adds a file to DigiKam that already has a face Person/Alice.  DigiKam
imports the face data.
2. Close DigiKam.  Open WLPG.  Move Alice's rectangle.
3. Close WLPG.  Open DigiKam.  DigiKam still has the old rectangle.  Save
Metadata.
   Do we overwrite the metadata?
4. Change the rectangle inside DigiKam.  Save metadata.
   Do we overwrite the metadata?

Metadatahub doesn't have enough information to know to not overwrite the
metadata in #3 but to make a change in #4.

I have proposed a fix in bug 268688 for the issue with tags.  We could do
something similar for faces.

I propose that for right now, we import faces from WLPG, but only read/write a
DigiKam specific face tag.  I think telling the user that DigiKam can't write
WLPG faces (but can import them) is easier to understand than DigiKam being
able to add WLPG faces (but not delete or rename them).

--
Configure bugmail: https://bugs.kde.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[Bug 271030] Windows Live Photo Gallery people tagging Compatibility [patch]

Marcel Wiesweg
In reply to this post by harry
https://bugs.kde.org/show_bug.cgi?id=271030





--- Comment #22 from Marcel Wiesweg <marcel wiesweg gmx de>  2011-07-12 18:13:38 ---

> I spent most of today reading the code trying to understand how it all fits
> together.  I am confused about what situations MetadataHub::load is called.
> When I click "Reread metadata" it seems to call ImageScanner::rescan.  In what
> situation is MetadataHub::load called?

MetadataHub was written to support loading multiple images in the right
sidebar, which is mostly complicated for tags. You load one or multiple images,
have a merged result, and write it back. In more places it is used for simple
load one - write one.

> I used QRectF for passing the image info and I have merged FaceIface and
> FaceIfacePriv (moving the methods from FaceIfacePriv into private methods in
> FaceIFace).  I think that is what you wanted.  What methods should be broken
> off?  Only the ones that use MetadataManager?

The problem is that using MetadataManager cannot be moved to the
libdigikamdatabase library, where we need to put FaceIface when used from
ImageScanner.
MetadataManager is asynchronous, has UI progress feedback, and writes to
database and metadata, which we do not want at all when reading from metadata.

I believe would be sufficient to move the calls to a virtual method, the
default implementation calling directly ImageInfo.setTag etc, and a subclass at
higher level using MetadataManager (asynchronous, with UI progress etc.)

Further on, we should see to replace most of the code you have in
ImageScanner::scanFaces() with calls to FaceIface. Something like
int tagid = iface.getOrCreateTagForPerson(i.key())
iface.add(m_scanInfo.id, tagId, TagRegion(rect), false);

--
Configure bugmail: https://bugs.kde.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[Bug 271030] Windows Live Photo Gallery people tagging Compatibility [patch]

Bugzilla from leif@dkstat.com
In reply to this post by harry
https://bugs.kde.org/show_bug.cgi?id=271030





--- Comment #23 from Leif Huhn <leif dkstat com>  2011-07-13 20:22:49 ---
I'm still working on writing a patch for exiv2.  This page gives a schema
definition:

http://metability.editme.com/mmf-scavenger-xmp-schemaex-MSPeopleTagging

I'm figuring out how to translate that into the data structure for exiv2.

--
Configure bugmail: https://bugs.kde.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[Bug 271030] Windows Live Photo Gallery people tagging Compatibility [patch]

Bugzilla from leif@dkstat.com
In reply to this post by harry
https://bugs.kde.org/show_bug.cgi?id=271030





--- Comment #24 from Leif Huhn <leif dkstat com>  2011-07-13 20:26:04 ---
Actually, nevermind.  That post just contains information from

http://msdn.microsoft.com/en-us/library/ee719905%28VS.85%29.aspx

in the original post.  I'll just go there.

--
Configure bugmail: https://bugs.kde.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[Bug 271030] Windows Live Photo Gallery people tagging Compatibility [patch]

Gilles Caulier-4
In reply to this post by harry
https://bugs.kde.org/show_bug.cgi?id=271030





--- Comment #25 from Gilles Caulier <caulier gilles gmail com>  2011-07-13 20:34:16 ---
Leif,

Andreas Huggel is in CC of this file. He is the Exiv2 lead developer. He can
guide you in to implement Microsoft MP schema support in XMP.

Gilles Caulier

--
Configure bugmail: https://bugs.kde.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[Bug 271030] Windows Live Photo Gallery people tagging Compatibility [patch]

Bugzilla from leif@dkstat.com
In reply to this post by harry
https://bugs.kde.org/show_bug.cgi?id=271030





--- Comment #26 from Leif Huhn <leif dkstat com>  2011-07-13 22:10:38 ---
Oh, I didn't make the connection.  I just added a bug under exiv2:

http://dev.exiv2.org/issues/778

--
Configure bugmail: https://bugs.kde.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[Bug 271030] Windows Live Photo Gallery people tagging Compatibility [patch]

Bugzilla from leif@dkstat.com
In reply to this post by harry
https://bugs.kde.org/show_bug.cgi?id=271030





--- Comment #27 from Leif Huhn <leif dkstat com>  2011-07-16 18:09:12 ---
In order to write the faces to the metadata, I need to specifically know the id
of the image, in order to look up the ImageTagProperties (or use FaceIface).
Writing the data happens in MetadataHub::write.  That class was designed to be
used in the case of multiple images (so it doesn't know the image id for what
it's being used for, because it might be used for multiple images).

Without changing the way things are called, I can't add logic to
MetadataHub::write to write the image tags.

How should we resolve this?

--
Configure bugmail: https://bugs.kde.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[Bug 271030] Windows Live Photo Gallery people tagging Compatibility [patch]

Marcel Wiesweg
In reply to this post by harry
https://bugs.kde.org/show_bug.cgi?id=271030





--- Comment #28 from Marcel Wiesweg <marcel wiesweg gmx de>  2011-07-23 13:57:32 ---
Sorry for late answer.

We do not need and cannot do conflict resolution/multiple file merging for
faces. So the way to go is the same as for the comment: Provide a
QList<DatabaseFace>, a status field, and load with loadSingleValue().

For loading from ImageInfo, FaceIFace::databaseFaces(info.id()) load the faces
for you. Omit the implementation in MetadataHub::load(DMetadata) because that
method is unused nowadays as I just checked.

Note: As soon as 2.0 is released, we should apply your patch as it is by then
and work on it together in git.

--
Configure bugmail: https://bugs.kde.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[Bug 271030] Windows Live Photo Gallery people tagging Compatibility [patch]

Marcel Wiesweg
In reply to this post by harry
https://bugs.kde.org/show_bug.cgi?id=271030





--- Comment #29 from Marcel Wiesweg <marcel wiesweg gmx de>  2011-08-08 17:39:35 ---
Git commit 1f389e3556758a50fd0171a28856b48f8029710d by Marcel Wiesweg.
Committed on 08/08/2011 at 18:49.
Pushed by mwiesweg into branch 'master'.

Split the FaceIface class in three parts

1) FaceTags in libs/database/faces: Contains utility code to find or create
face tags
   with TagsCache help
2) FaceTagsEditor: Code to add, remove or confirm face entries in the database.
   Strictly only database dependency, no libkface
DatabaseFace is moved to libs/database/faces as well
3) FaceIface: Code to detect and recognize with libkface, and merge the
results.
   Inherits FaceTagsEditor and reimplements the methods for normal tags
   using MetadataManager

CCBUG: 271030

M  +4    -5    utilities/facedetection/facegroup.cpp
M  +0    -2    utilities/facedetection/facepipeline.h
R  +2    -2    libs/database/faces/databaseface.h [from:
utilities/facedetection/databaseface.h - 097% similarity]
M  +32   -30   utilities/facedetection/facepipeline.cpp
A  +109  -0    libs/database/faces/facetags.h     [License: GPL (v2+)]
R  +0    -0    libs/database/faces/databaseface.cpp [from:
utilities/facedetection/databaseface.cpp - 100% similarity]
A  +327  -0    libs/database/faces/facetags.cpp     [License: GPL (v2+)]
M  +1    -1    digikam/items/assignnameoverlay.cpp
M  +27   -1032 utilities/facedetection/faceiface.cpp
M  +42   -202  utilities/facedetection/faceiface.h
M  +4    -1    CMakeLists.txt
A  +411  -0    libs/database/faces/facetagseditor.cpp     [License: GPL (v2+)]
M  +0    -1    utilities/facedetection/facepipeline_p.h
A  +160  -0    libs/database/faces/facetagseditor.h     [License: GPL (v2+)]

http://commits.kde.org/digikam/1f389e3556758a50fd0171a28856b48f8029710d

--
Configure bugmail: https://bugs.kde.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[Bug 271030] Windows Live Photo Gallery people tagging Compatibility [patch]

Marcel Wiesweg
In reply to this post by harry
https://bugs.kde.org/show_bug.cgi?id=271030


Marcel Wiesweg <[hidden email]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|                            |FIXED




--- Comment #29 from Marcel Wiesweg <marcel wiesweg gmx de>  2011-08-08 17:39:35 ---
Git commit 1f389e3556758a50fd0171a28856b48f8029710d by Marcel Wiesweg.
Committed on 08/08/2011 at 18:49.
Pushed by mwiesweg into branch 'master'.

Split the FaceIface class in three parts

1) FaceTags in libs/database/faces: Contains utility code to find or create
face tags
   with TagsCache help
2) FaceTagsEditor: Code to add, remove or confirm face entries in the database.
   Strictly only database dependency, no libkface
DatabaseFace is moved to libs/database/faces as well
3) FaceIface: Code to detect and recognize with libkface, and merge the
results.
   Inherits FaceTagsEditor and reimplements the methods for normal tags
   using MetadataManager

CCBUG: 271030

M  +4    -5    utilities/facedetection/facegroup.cpp
M  +0    -2    utilities/facedetection/facepipeline.h
R  +2    -2    libs/database/faces/databaseface.h [from:
utilities/facedetection/databaseface.h - 097% similarity]
M  +32   -30   utilities/facedetection/facepipeline.cpp
A  +109  -0    libs/database/faces/facetags.h     [License: GPL (v2+)]
R  +0    -0    libs/database/faces/databaseface.cpp [from:
utilities/facedetection/databaseface.cpp - 100% similarity]
A  +327  -0    libs/database/faces/facetags.cpp     [License: GPL (v2+)]
M  +1    -1    digikam/items/assignnameoverlay.cpp
M  +27   -1032 utilities/facedetection/faceiface.cpp
M  +42   -202  utilities/facedetection/faceiface.h
M  +4    -1    CMakeLists.txt
A  +411  -0    libs/database/faces/facetagseditor.cpp     [License: GPL (v2+)]
M  +0    -1    utilities/facedetection/facepipeline_p.h
A  +160  -0    libs/database/faces/facetagseditor.h     [License: GPL (v2+)]

http://commits.kde.org/digikam/1f389e3556758a50fd0171a28856b48f8029710d

--- Comment #30 from Marcel Wiesweg <marcel wiesweg gmx de>  2011-08-08 17:39:35 ---
Git commit ea30232a07d2e1e2a788035da53cbf9806d3c01b by Marcel Wiesweg.
Committed on 08/08/2011 at 19:38.
Pushed by mwiesweg into branch 'master'.

Add scanning of XMP face tags to the ImageScanner

Part 3 of Leif Huhn's patch, rewritten to reuse code
as much as possible.
Test image provided in bug report is correctly parsed.

BUG: 271030

M  +2    -1    NEWS
M  +1    -0    libs/database/imagescanner.h
M  +42   -0    libs/database/imagescanner.cpp
M  +8    -0    libs/database/tagregion.cpp
M  +3    -0    libs/database/tagregion.h

http://commits.kde.org/digikam/ea30232a07d2e1e2a788035da53cbf9806d3c01b

--
Configure bugmail: https://bugs.kde.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[Bug 271030] Windows Live Photo Gallery people tagging Compatibility [patch]

Marcel Wiesweg
In reply to this post by harry
https://bugs.kde.org/show_bug.cgi?id=271030


Marcel Wiesweg <[hidden email]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |UNCONFIRMED
         Resolution|FIXED                       |




--- Comment #31 from Marcel Wiesweg <marcel wiesweg gmx de>  2011-08-08 17:40:28 ---
commit 1ccda1b93daa5e1ea47cfe1f82db1fa2e6bf4388
Author: Marcel Wiesweg <[hidden email]>
Date:   Mon Aug 8 19:36:19 2011 +0200

    Add parsing of WLPG face tags in XMP to DMetadata

    Part 2 of Leif Huhn's patch. Parses the metadata and returns a map
    name -> relative rectangle.

    CCBUG: 217030

--
Configure bugmail: https://bugs.kde.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[Bug 271030] Windows Live Photo Gallery people tagging Compatibility [patch]

Marcel Wiesweg
In reply to this post by harry
https://bugs.kde.org/show_bug.cgi?id=271030


Marcel Wiesweg <[hidden email]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|                            |FIXED




--
Configure bugmail: https://bugs.kde.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
Reply | Threaded
Open this post in threaded view
|

[Bug 271030] Windows Live Photo Gallery people tagging Compatibility [patch]

Gilles Caulier-4
In reply to this post by harry
https://bugs.kde.org/show_bug.cgi?id=271030

Gilles Caulier <[hidden email]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Version Fixed In|                            |2.1.0

--
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Digikam-devel mailing list
[hidden email]
https://mail.kde.org/mailman/listinfo/digikam-devel
12