Copy files to new directory based on Picasa face tag or keyword

Started by neon013, January 25, 2017, 06:04:46 AM

Previous topic - Next topic

neon013


Newbie.

Is it possible to scan my original photos that have been tagged in Picasa and copy them to new directories based on both Picasa people tags and Picasa keyword tags i.e.

Original.jpg (tagged with John and Snowboarding in Picasa) copied to new directories   John\Original.jpg and Snowboarding\original.jpg

Any attempts at this would be greatly appreciated.


Phil Harvey

First you have to figure out what tag Picasa uses for the keywords are store (see FAQ 2).  Assuming is the the "Subject" tag, you could use these commands to copy them:

1. exiftool "-directory<${subject;my @a=split /, /;$_=$a[0]}" -if "defined $subject" -o . DIR

2. exiftool "-directory<${subject;my @a=split /, /;$_=$a[1]}" -if "defined $subject and (()=$subject=~/, /g)>=1" -o . DIR

3. exiftool "-directory<${subject;my @a=split /, /;$_=$a[2]}" -if "defined $subject and (()=$subject=~/, /g)>=2" -o . DIR

... and so on for any additional keywords.

These commands will create the new directories in the current working directory.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).