How can I export people tags with associated faces to the web?

Explorer ,
Nov 02, 2017 Nov 02, 2017

Copy link to clipboard

Copied

I have some vintage photos (taken at least 100 years ago) that I've carefully tagged using facial recognition in Lightroom Classic CC. I'd like to share these photos with each photo tag preserved above each face with family and genealogical societies. In some cases, I have class or sports team photos, and identification of the individuals in the photo holds a great deal of value for the people I'm sharing the photos with. Is there any way of exporting people tags with associated faces to the web?

Views

1.6K

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Nov 02, 2017 Nov 02, 2017

Copy link to clipboard

Copied

LR doesn't have this capability, and I don't know of any plugins that do. 

LR does export the tagged face rectangles in an industry-standard format defined by the Metadata Working Group, but not many services or programs know how to interpret that metadata.  (The now-dead Picasa does, any others?)

Perhaps someone else can make a suggestion?

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Jan 28, 2019 Jan 28, 2019

Copy link to clipboard

Copied

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Apr 12, 2020 Apr 12, 2020

Copy link to clipboard

Copied

I have the same issue - I tagged faces in old photos of my father and would like to share (or publish) them, with individual face tagging.

Is there any suggestion?

(original answer is from 2017)

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Apr 12, 2020 Apr 12, 2020

Copy link to clipboard

Copied

[This post contains embedded images that don't appear in email. View the post in your Web browser to see the images.]

 

"I have the same issue - I tagged faces in old photos of my father and would like to share (or publish) them, with individual face tagging. Is there any suggestion? (original answer is from 2017)"

 

Unfortunately, I think the answer remains the same. Neither LR, nor any third-party program I know of, will overlay the face rectangles and face names on exported/published photos.  (LR stores the rectangles and names in industry-standard metadata fields.)  I think the best you can do is (painfully) make screenshots of LR's Loupe view with the face rectangles enabled:

 

[Use the blue reply button under the first post to ensure replies sort properly.]

 

 

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Apr 12, 2020 Apr 12, 2020

Copy link to clipboard

Copied

Thanks, but its 1600 photos (from over 44 years), Scrrenshots is not the answer

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Jul 11, 2020 Jul 11, 2020

Copy link to clipboard

Copied

I have been searching on-and-off for this feature for years and not found it yet. I'd love to know if anyone else has a solution.

 

The best setup that I had was in combination with Picasa, which could at least help with the face thumbnails, people  management and thumbnail export.

From there however it was less than optimal, as I resorted to manually created & edited slide summaries (e.g. Powerpoint etc), where I pasted the main image, and dragged-in the various people face thumbnails and pasted-in the person details (e.g. <name> b<year>). I positioned the people details & thumbnails to align with where they were in the main photo to help with identification. It was quite tricky for photos of larger groups of people, but I always found a way in the end.

 

It did produce great results for family history summary documents, which I then shared online or sent off for printing & binding, and put out at family events, or gave as gifts. But it was very time-consuming and I would so like to find a more streamlined (i.e. automated) solution.

 

Does anyone have any better ways?

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jul 22, 2020 Jul 22, 2020

Copy link to clipboard

Copied

It drives me crazy that Adobe does not embed all of the metadata into the files.  The facial tagging all seems contained in the database, so after spending many hours tagging tons of faces in Adobe Elements, it was all lost when I moved my pictures to a new NAS device with a different path to the pictures.  Maybe there is a way around this, but I have not been able to find it.

I've instead starting looking for other software options.  So far, digiKam is the only one I've found that will embed the facial recognition information into the files.  It will also scan for faces, and will try to predict based on faces you have identified previously.  I'm not crazy about the interface though, and the geotagging feature seems unnecessarily difficult IMO.

I feel like the things I am looking for in photo organizing software are things that a lot of people would want, and yet, it seems impossible to find any software that does it all easily.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Jul 24, 2020 Jul 24, 2020

Copy link to clipboard

Copied

"It drives me crazy that Adobe does not embed all of the metadata into the files."

 

I don't know how Photoshop Elements handles face tagging, but LR does write all the face rectangles and names into a photo's metadata, following industry standards. (Unfortunately, only a few programs follow those standards, and one, Picasa, is long-defunct.)

 

[Use the blue reply button under the first post to ensure replies sort properly.]

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Aug 03, 2020 Aug 03, 2020

Copy link to clipboard

Copied

Further to my comment above (with different login) about previous face handling flow using Picasa, I am trying to 'bite the bullet' and set up a similar flow using Lightroom Classic. Since it appears there is no ready-made solution, I am having a go at creating one myself. Time will tell if I'm up to the task ...

 

My current proposal is:

1. Lightroom plugin for person face thumbnail export to image files

- reason: because I used face thumbnails (previously from Picasa) as the main person image on my family tree, which I felt looked good on Ancestry family tree view

- status: prototype Lightroom plugin working (at least on Mac) (using ExifTool under the hood)

- way forward: further development innevitably required; I probably ought to see if I can make it also Windows compatible

 

2. Lightroom plugin for multiple person face labelling (from exif data) and export to image files

- reason: to replace my previously nice looking but horribly manual flow of creating family history summary documents (or image uploads) with people labeled for easy identification

- status: working prototype implemented in python; reads the image and exif face region data (using ExifTool under the hood); has a go at finding 'best' locations & text-line-splits to annotate person information near the face region without overlapping any other face region or person label

- way forward: re-implement as Lightroom plugin; improve the optimisation of person labelling location & formatting; I probably ought to see if I can make it also Windows compatible

 

I haven't yet found a shared public domain repository of Lightroom plugins, which seems something of a missed opportunity if true. Ideally I'd like to make a plugin or two and put them somewhere others can pick them up and adapt them further if needed. My default proposal is to put them on github, though that does feel rather generic and harder to find than it would have been if Adobe had a community plugin sharing repository.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Aug 08, 2020 Aug 08, 2020

Copy link to clipboard

Copied

I have made a working multi-person labelling (using existing EXIF data) photo export plugin for Lightroom (Classic), but I fully expect that tidying it up and making it robust and deployable is likely to take rather more time & effort.

 

See a simple obfuscated (highly faded image and randomised label text & digits) output below as an example.

For this example I have left the face region outlines drawn (in blue) to help make sense of what it is doing since the obfuscated image is barely visible. Normally the boxes would not be drawn.

 

The plugin detects collisions between labels and face regions, and tries several levels of experiments (including label position and number of line-wraps) to try to find a working layout. It only knows about the overall image dimensions and the face regions, so it clearly can't be as sophisticated about label placement over the underlying image as a human would be doing the same thing manually, however I think this could be very useful for automatically labelling a large number of images for sharing.

 

It currently decides a single font size based on average face region size vs overall image size. It seems to do a reasonable job based on around 80 of my family history photos, but I am sure it will need further refinement.

 

This clearly isn't perfect yet, for example I don't really like the ragged label text background, it shouldn't really be leaving the spaces at the start of wrapped lines, and the label text does sometimes come out a bit small, thin and difficult to read ... but it's a start ...

 

I would be interested to know if this looks to be heading in the direction other people have invisaged?

 

Again, my overall concept is that I make a plugin that works for me and make it available for others to use and adapt further if required. My remaining concern is whether I would be able to make it sufficiently portable and robust to work across a reasonable rage of computer types, software versions, file formats, photos and exif parameters, however I think I'll give it a go.

 

obfuscated_label_test.jpg

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Aug 18, 2020 Aug 18, 2020

Copy link to clipboard

Copied

Ok, here we go ... a first (hopefully fit for initial sharing) face labelling export plug-in for Lightroom Classic:

https://github.com/colin0brass/FaceLabellingExportLrPlugin

 

Please be patient with it (and with me) ... I hadn't even used Lightroom until about 5wks ago, let alone looked at Lightroom plug-ins, or ever seen the Lua programming language. But I've done my research, implemented a few prototypes, and applied my learnings to this first plug-in development and publishing on GitHub.

 

It does need some helper apps installing. I have hopefully included a workable version of exiftool in the plug-in bundle, but it definitely needs ImageMagick separately installing (which on Mac also needs ghostscript separately installing, though it is easier on Windows).

 

I suggest that first trials are probably best suited to fairly computer-literate people who could help to work through any teething and portability issues.

 

Please let me know if you do give it a try, and especially if there are any things I could learn from and improve on.

 

Regards

Colin

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Feb 24, 2021 Feb 24, 2021

Copy link to clipboard

Copied

This is a terrific concept, as it appears I am not the only one that would like to do exactly what this plug-in provides.  I have downloaded and installed it with its helper apps and was able to see it export my selected photos.  Alas, the exported images did not show the annotations I was hoping for (the images seemed unaltered).  I would be willing to help figure this out to see what is not working.  What is the best way to do this?

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Feb 26, 2021 Feb 26, 2021

Copy link to clipboard

Copied

Thanks for the feedback. I /think/ that might be the same issue that was raised recently on my github project page under the following issue: https://github.com/colin0brass/FaceLabellingExportLrPlugin/issues/2

 

I have just answered it there, but in short I suspect it is metadata export disabled in the LrC Export dialogue box, and my plug-in currently does not sanity-check that setting, over-ride it, or give any warning.

 

If so, I think it should be an easy setting for you to change during export for now (see a bit more context in the above linked issue ticket), and I'll look into how to handle this more thoroughly in the plug-in.

 

Regards

Colin

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Feb 26, 2021 Feb 26, 2021

Copy link to clipboard

Copied

I got your latest release, it continues to improve!  But I'm still not obtaining the labels.  I think it is a problem in executing the exiftool.  In the Plugin Manager, I pointed it to my recently installed exiftool in usr/local/bin/exiftool.  After exporting I looked at the log file (how nice!) and found it reporting exiftool error 32256.  I then discovered that exiftool is embedded in the plugin and tried to point to it.  This time I got error 32512.  I'm not sure what these particular errors imply, but I suspect the path to exiftool is not right yet.  

Any suggestions?

Thanks,
Thor.

2021-02-26 14:33:40.0420000-06:00, TRACE	2 : processRenderedPhotos
2021-02-26 14:33:40.0430000-06:00, TRACE	2 : Starting exiftool session
2021-02-26 14:33:40.2290000-06:00, TRACE	1 : exiftool error: 32512
2021-02-26 14:33:40.2980000-06:00, TRACE	2 : Exporting to: '/Users/Thor 1/Documents/-Thor's/Genealogy/ScannedFamilyPhotos/FaceLabelled/FLE-0189-4.jpg'
2021-02-26 14:33:45.3020000-06:00, TRACE	2 : FLEExifToolAPI.getFaceRegionsList: exiftool execution failed
2021-02-26 14:33:45.3020000-06:00, TRACE	2 : Export labeled image
2021-02-26 14:33:45.3020000-06:00, TRACE	0 : get_labels: no people found
2021-02-26 14:33:45.4980000-06:00, TRACE	2 : Closing exiftool session

 

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Feb 26, 2021 Feb 26, 2021

Copy link to clipboard

Copied

Well, I finally got an annotated export!  I'm not sure what solved it.  I renamed my home directory to remove a space in it, thinking it might have interferred with the path to exiftool.  I updated Lightroom.  I found that the "Face Labelling Export" plugin could not be "removed", so I manually removed it from the Lightroom plugins folder, and then restarted Lightroom.  I then "added" the FLE plugin again, residing in a folder outside Applications.  This time my export test worked.

I think you have a valuable module here.  I encourage you to refine it.

Thor.

 

FLE-0189-9.jpg

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
LEGEND ,
Feb 26, 2021 Feb 26, 2021

Copy link to clipboard

Copied

That looks pretty slick. I can see where @Colin Osborne 's plugin will be very useful.  Keep refining Colin.  Great job.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Feb 27, 2021 Feb 27, 2021

Copy link to clipboard

Copied

Thanks Thor & Bob for the feedback.

@thoro72875955 , I will do some further testing to try and spot whatever fragility it was that got in your way.

I would also like to add some more control around the labelling ... hopefully you already spotted the box outlines can be turned-off (both for faces & name labels), however beyond that it is currently pretty limited. It has a built-in heuristic (formula) to try to decide a reasonable text size and line-wrapping vs the image size, aspect ratio and face proportions within the image. I ought to make that more user configurable.

It also then tries to avoid writing labels over adjacent faces. It currently defaults to labels below the face region, then if it detects overlaps, it does a couple of iterations of trying different N/S/E/W locations for each label before last resort of reducing the font size. I have a vague thought in mind that it could use a 'force field' algorithm (i.e. like magnetic repulsion) to self-optimise locations, but I haven't dared dive into that particular rabbit hole yet since I imagine it could be complicated and take (me) a very long time.

Anyway ... back to the basics it is. Wider usage was always going to show up my (plug-in's) limitations. I will take a closer look and try to make it more robust. Thanks again for the feedback.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Feb 27, 2021 Feb 27, 2021

Copy link to clipboard

Copied

Hi Colin,

Your strategy for placing the text labels seems good, at least for my purposes- I don’t have large dense groupings of people in my current project. I might suggest offering a font choice. I noticed the label formatting stripped out my parentheses, probably as part of finding the line breaks.

If you look at Lightroom's display of names, it seems they have a way of preventing the labels from overlapping themselves, but not the face rectangles. For some reason, they use an opaque background on the text, but their goal is a bit different than ours. There is probably some research on how to avoid block collisions; I may look into it.

Thanks again for this cool function. I’m impressed you put it together with such apparent ease!

Thor.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Feb 27, 2021 Feb 27, 2021

Copy link to clipboard

Copied

Here is a screen shot of Lightrooms face labels.  Note how Ida's label moved up to avoid interference from Carl, yet Tom's label covered Ida's face.  Your placement below the face and breaking the label into lines is an improvement (for my application).  It might be nice to be able to use a black/white box outline ala LR.
LRcFaceLabels.jpgAAx0044-FLE.jpg

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Mar 06, 2021 Mar 06, 2021

Copy link to clipboard

Copied

I've pushed release v1.4 on github, with several updates:

  • Improved label sizing
  • Exposed more config options through GUI
  • Sped-up label position optimisation
  • Added image crop option

 

https://github.com/colin0brass/FaceLabellingExportLrPlugin

 

I haven't yet looked into the fragility issues reported above (I'm guessing the spaces in folder names might have been at least part of it), but hope you find this a useful usability improvement anyway.

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Engaged ,
Feb 26, 2021 Feb 26, 2021

Copy link to clipboard

Copied

I've been looking around for information on your topic since I realize I may want to use the answer in pictures I will be scanning and/or my wife's genological work.

 

I did find a couple of things that I will leave with you:

 

So, disappointing that there is nothing more given the heighten interest in family tree research these days. You may get insights by Googling ' "Digital Asset Management" for genealogy '. 

 

For the moment, you may better just using LR Faces and naming. At least you will have the information centrally managed and availabile.

 

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Engaged ,
Feb 26, 2021 Feb 26, 2021

Copy link to clipboard

Copied

I think I misread some of the postings about what LRc will export in terms of people's name set up with Facial Recognition. It does export the names in both and XMP and IPTC metadata tags.

Now, back to the original question " Is there any way of exporting people tags with associated faces to the web?" this thread identifies that:

  • The FaceLabellingExportLrPlugin if you want the name in the picture
  • As metadata XMP:Subject and IPTC:Keywords. However, this does not identify the name with the face.

Here's what I found from playing around. I also changed names to see how things were affected.

$ exiftool -xmp:subject -iptc:keywords S-026-T-001.jpg
Subject                         : ?, Bill, Gail, LOW RES, Richard, Rose, SLIDE
Keywords                        : ?, Bill, Gail, LOW RES, Richard, Rose, SLIDE

$ REM Change Some Name Assgigned to Faces

$ exiftool -xmp:subject -iptc:keywords S-026-T-001.jpg
Subject                         : Betsy, Bill, LOW RES, Richard, SLIDE, Sally, Shella, Sue
Keywords                        : Betsy, Bill, LOW RES, Richard, SLIDE, Sally, Shella, Sue

 

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Mar 07, 2021 Mar 07, 2021

Copy link to clipboard

Copied

LATEST

Hi @DS256, for well labelled image files with exif data available, I suspect you should probably be able to find what you need in the exif metadata. 

Context

The way I read this thread, I interpreted there are 2 levels of detail ... firstly just /having/ the person metadata, and secondly /visually/ showing that on an image. The second point is where I started with the LRc plug-in concept, since I had lots of carefully labelled images with person metadata in EXIF, and there are plenty of programs and online platforms where you can point at people one at a time to see who they are, but I had never found anything that allowed visual annotation of all the people on the image for publishing, whether online or in print.

As you say, LRc can include the person metadata in the image export, though it can be enabled/disabled in the export dialog settings, so needs some care to get what you need.

ExifTool and Region Metadata

You have found and used the amazingly powerful exiftool, which has both a wealth of helpful information online and an expert and active community using it and answering questions. As mentioned above, my plugin uses exiftool to access the image file metadata. I have chosen to put much of the complexity into an exiftool 'config file' (basically a bunch of exiftool supported perl code) to handle different metadata standards (e.g. Microsoft, MWG, IPTC) and the different tag names and coordinate systems that they use. I'm sure it is not the most streamlined implementation, so could well show its limitations on bulk exports, but it felt like a decent partitioning of functionality for clarity and future maintenance. See file currently named "get_regions.config" in the github repository as per link above (I won't give a file link here since I might break it in future if I do any file renaming or structuring in my FLE plugin).

In that exiftool 'config file', I also try to handle the surprisingly complicated implications of rotation and crop, and whether those have been already applied or not. I didn't find any good documentation or examples on how to handle that, beyond a few useful illustrations of what the rotation scenarios looked like, and from what I have seen I have the impression there are many variations and inconsistencies in how these fields are used in the wild. So I fully expect to find cases that I have not handled correctly.

Anyway, that is complicated background on why there isn't a one-line answer, but not yet addressing your question about names per face/person ... see the following which might help:

Examples of viewing region metadata

If you want to see all the region data, including names per face-region (if image file is appropriately labelled in metadata), then if it is in MWG format (from the 'Metadata Working Group') then you should be able to use:

exiftool <image_file> -j -XMP-mwg-rs:all

If the region data is in Microsoft format then this should help:

exiftool <image_file> -j -XMP-MP:all

Notes:

  • If exiftool isn't in your search path then include full executable path & filename
  • Insert your image file path & name in place of <image_file>
  • There is also an IPTC format which I support in config file but haven't given an example above
  • If you try to do anything with these regions, be aware that the different formats use different coordinate systems (e.g. centred vs top-left) to locate the face regions

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines