Faces inconsistently read from .jpg - only one of the three faces read

I have a photo that I face tagged with DigiKam, manually drawing squares and naming them.

There are three faces in the picture, and Mylio only reads and displays one.

exiftool sees the faces, it seems like:

$ exiftool '2015-02-02 19.27.22.jpg'

Region Type                     : Face, Face, Face
Region Area X                   : 0.485599, 0.654085, 0.426017
Region Area Y                   : 0.468541, 0.647256, 0.559237
Region Area W                   : 0.171498, 0.34695, 0.0523343
Region Area H                   : 0.24498, 0.698126, 0.0749665
Region Area Unit                : normalized, normalized, normalized
Region Rectangle                : 0.399849, 0.346051, 0.171498, 0.24498, 0.48061, 0.298193, 0.34695, 0.698126, 0.399849, 0.521754, 0.0523343, 0.0749665

What in Mylio would make it read only one of the faces?

I don’t know if “squishing” three face regions into a single Region entry - like your DigiKam example - complies with the MWG standard or not. Mylio normally would write these as a sequential list of three separate regions - which I know can be read by other apps:

<mwg-rs:RegionList>
 <rdf:Seq>
  <rdf:li>
   <rdf:Description
    mwg-rs:Type="Face"
    mwg-rs:Name="Bob Smith"
    mwg-rs:Description="mylio_face">
   <mwg-rs:Area
    stArea:x="0.903086"
    stArea:y="0.331402"
    stArea:w="0.266119"
    stArea:h="0.476983"
    stArea:unit="normalized"/>
   </rdf:Description>
  </rdf:li>
  <rdf:li>
   <rdf:Description
    mwg-rs:Type="Face"
    mwg-rs:Name="Alice Smith"
    mwg-rs:Description="mylio_face">
   <mwg-rs:Area
    stArea:x="0.172578"
    stArea:y="0.381961"
    stArea:w="0.359782"
    stArea:h="0.601873"
    stArea:unit="normalized"/>
   </rdf:Description>
  </rdf:li>

  etc...

 </rdf:Seq>
</mwg-rs:RegionList>

Does DigiKam offer any options for how it saves these?

EDIT: on further review, I think the “squishing” we’re seeing in your example is an artifact of how EXIFTOOL condenses its output to save space. We’d need to see the actual XMP to know if it’s something Mylio should be able to read or not.

Not as far as I can see. You did give me an idea, I created the XMP, and still only the one face appears:

exiftool -tagsfromfile '2015-02-02 19.27.22.jpg' '2015-02-02 19.27.22.xmp'

I cannot upload files yet, and this is what I see in there:

   <mwg-rs:RegionList>
    <rdf:Bag>
     <rdf:li rdf:parseType='Resource'>
      <mwg-rs:Area rdf:parseType='Resource'>
       <stArea:h>0.24498</stArea:h>
       <stArea:unit>normalized</stArea:unit>
       <stArea:w>0.171498</stArea:w>
       <stArea:x>0.485599</stArea:x>
       <stArea:y>0.468541</stArea:y>
      </mwg-rs:Area>
      <mwg-rs:Name>CD</mwg-rs:Name>
      <mwg-rs:Type>Face</mwg-rs:Type>
     </rdf:li>
     <rdf:li rdf:parseType='Resource'>
      <mwg-rs:Area rdf:parseType='Resource'>
       <stArea:h>0.698126</stArea:h>
       <stArea:unit>normalized</stArea:unit>
       <stArea:w>0.34695</stArea:w>
       <stArea:x>0.654085</stArea:x>
       <stArea:y>0.647256</stArea:y>
      </mwg-rs:Area>
      <mwg-rs:Name>DR</mwg-rs:Name>
      <mwg-rs:Type>Face</mwg-rs:Type>
     </rdf:li>
     <rdf:li rdf:parseType='Resource'>
      <mwg-rs:Area rdf:parseType='Resource'>
       <stArea:h>0.0749665</stArea:h>
       <stArea:unit>normalized</stArea:unit>
       <stArea:w>0.0523343</stArea:w>
       <stArea:x>0.426017</stArea:x>
       <stArea:y>0.559237</stArea:y>
      </mwg-rs:Area>
      <mwg-rs:Name>MR</mwg-rs:Name>
      <mwg-rs:Type>Face</mwg-rs:Type>
     </rdf:li>
    </rdf:Bag>
   </mwg-rs:RegionList>

It may just be that Mylio is better at SAVING face regions than it is on IMPORTING face regions. For example:

  • Face regions created in Mylio are read/imported just fine in Lightroom Classic.
  • Conversely, face regions created in Lightroom Classic do not seem to be recognized by Mylio at all (Lightroom also saves people as Keywords - and those are recognized by Mylio.

Does anyone have examples where Mylio successfully imports face regions created in another app? If so, does it create a new “Known Person” in Mylio upon import? Curious…

Hi danie,

Mylio doesn’t support overlapping face rectangles, which looks like is the case in this XMP.

Mylio does support reading Face Regions, but only on first import of an image–it won’t pick up changes made to Face Regions in an already-imported image/XMP.

thanks,
Sam

Hi Sam,

I have many photos with overlapping rectangles, because that is what Picasa did way back when. Is there a good reason for not supporting overlapping rectangles?

And then, what else does Mylio not pick up after first import? I am considering blowing away and reimporting regularly to ensure that everything is picked up consistently. That feels a bit excessive, and also seems to be the best option right now?

There a few reasons that we don’t support overlapping face rectangles. One is error rejection–many face detection algorithms over the years have relatively high rates of error, and overlapping face rectangles is one artifact of those errors. Another is that we want our face recognition algorithm to have (as much as possible) clear views of faces. Adding partially obstructed faces degrades our recognition quality.

I believe face rectangles are the only metadata that we only read on first import. The reason for this is that this data can be modified by Mylio in the background as we detect and tag new faces in images. This can cause problems with other software, where we will adjust a face rectangle based on our estimate of facial features, then some other program notices our changes, and adjusts the face rectangles back to where it thinks they should be, resulting in an endless XMP tug of war between two different facial recognition systems.

I’m not sure why you would remove and reimport your images, unless you are modifying face region data in your XMPs (external to Mylio) after they are imported into Mylio?

That. Yes.

I want to trust that I can manage my photo library with Mylio, without having to rely on it being around. Photos are a life long asset. Software is not. I understand this tug-of-war concern, and I am ok with that.

That one photo that Mylio is rejecting, is the very first photo of my girl, her mom, and me. It’s a manual tag, by me, years ago. It is a precious memory that Mylio does not honour.