Exiftool

http://www.sno.phy.queensu.ca/~phil/exiftool/

  • Installation
    • Install by renaming exiftool(-k).exe to exiftool.exe and saving it in c:\Program Files (x86)\exiftool.
    • Add c:\Program Files (x86)\exiftool to %PATH%
    • Create .ExifTool_config in
      • .ExifTool_config
        %Image::ExifTool::UserDefined = (
            'Image::ExifTool::Composite' => {
                UniqueKeywords => {
                    Require => 'Keywords',
                    ValueConv => q{
                        my @list = ref $val eq 'ARRAY' ? @$val : $val;
                        my ($item, %found, @rtn);
                        foreach $item (@list) {
                            $item =~ s/^\s+//;   # remove leading white space
                            push @rtn, $item unless $found{$item};
                            $found{$item} = 1;
                        }
                        return \@rtn;
                    },
                },
            },
        );
  • Examples
    • Add Picasa People tags as Keywords 1)):
      exiftool "-Keywords+<RegionName" DIR
    • Add 4 first characters of filename as Keyword (assuming the 4 first characters are the year in which the picture was taken):
      exiftool "-Keywords+<${filename;$_=substr($_,0,4);s/\..*?$//}" DIR
    • Remove duplicate Keywords: 2)
      exiftool "-Keywords<UniqueKeywords" DIR
  • Add -v0 (verbose) as parameter to see processed file
1)
Check Tools>Options>Name Tags>Store name tags in photo in Picasa to ensure recognized people are written in JPG files (as 'XMP:RegionName'-tag
2)
UniqueKeywords is defined in .ExifTool_config