How to get and save unique keywords/subjects?

Started by marekl, May 01, 2017, 02:41:17 PM

Previous topic - Next topic

marekl

I have duplicated keywords/subjects saved to pictures. See example.jpg in attachment, where is:

[XMP-dc]        Subject                         : AAA, BBB, CCC, BBB, BBB, AAA, BBB, CCC

Is there a way ho to remove duplicates? The results should be then:

[XMP-dc]        Subject                         : AAA, BBB, CCC

Thank you

Phil Harvey

A quick search in the forum for "remove duplicate keywords" yields this useful post by StarGeek.

- 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 ($).

marekl


lotsobear

Hi, I tried to read through the documentation, but just not having success understanding it.

So, my filenames are in the following format:

YYYYMMDD_HHMMSS.mpg

When I copied videos from my computer to my phone, my phone shows all the videos on that date, instead of by the date they were taken.  I want to fix all the exif dates and times so that my phone will sort the videos correctly.  I tried all the different codes mentioned above, but it just sets all the dates to the current date/time.  Can someone help?  Feel stupid because it seems very similar to the OP's questions, but I can't figure it out! :(  Thanks!

Phil Harvey

I think the problem is that the phone is using the filesystem date/time for sorting, since these are the only date/times that will change when a file is copied.  If the phone is mounted as a disk, you may be able to do this to set the file modification date/time from the filename:

exiftool "-filemodifydate<filename" -ext mpg DIR

where DIR is the directory on the phone.

- 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 ($).