ExifTool Forum

ExifTool => The "exiftool" Application => Topic started by: linuxuser on February 05, 2012, 09:27:22 AM

Title: All photos with no gps data
Post by: linuxuser on February 05, 2012, 09:27:22 AM
I am using Linux and want to find all photos with no gps data (exactly all photalbums with at least 1 photo with no gps data)

Is there a simply way with exiftool?
Title: Re: All photos with no gps data
Post by: Phil Harvey on February 05, 2012, 10:02:34 AM
This may do what you want:

exiftool -p '$directory/$filename' -if 'not $gpslatitude' -r DIR

This command will print the path names of all images without EXIF GPS information in directory DIR and its subdirectories.

- Phil

Edit: changed $gpsversionid to $gpslatitude because some cameras write empty GPS information containing only GPSVersionID.
Title: Re: All photos with no gps data
Post by: linuxuser on February 06, 2012, 04:35:51 AM
Thanks,

I think


exiftool -p '$directory' -if 'not $gpslatitude' -r DIR | sort -u


does what I want, but I want to limit the search. I want to search for *.jpg only and e.g not for *.jpeg
A limitation to the maximum number of subdirectories could be also helpful
Title: Re: All photos with no gps data
Post by: Phil Harvey on February 06, 2012, 07:21:12 AM
Add -ext jpg to search for only .jpg and .JPG files.  There is no way to limit the depth.

- Phil
Title: Re: All photos with no gps data
Post by: linuxuser on February 06, 2012, 07:42:40 AM
Thanks a lot. I solved it by using a pipe with cut.