cmartin/EXIFr

Extract latitude and longitude from exif

Closed this issue · 7 comments

Would it be possible to extend this package to extract lat and long from exif? If you do not have the time available I would maybe try to make a pass at a pull request for this feature. Is there another package you would use for this function?

Yeah, should not be too complicated to implement (and very useful).

If you could attach an example image with latitude/longitude included, I'll have a quick go at it.

If I can't get it done rapidly, I'll update you here so you can try to do it yourself.

There are a couple of other solutions to reading exif data in R. This one needs an external software to run : https://github.com/paleolimbot/exifr . And this one, which I have not tried, relies on a C++ library for the exif parsing : https://github.com/Ironholds/exif.

I put a photo up at http://akdata.org/exif_location_example.jpg from my phone.

It seems EXIF was stripped from your image (through Picasa?).

I don't see any EXIF info here, and this online reading don't see them either : http://metapicz.com/

I guess gmail stripped it? Here's the same image.
http://akdata.org/20170703_083416.jpg

I used http://exif.regex.info/exif.cgi to confirm that the coordinates are present.

Ok, so, I took a stab at it this afternoon, and it won't be the quick add I first thought it would be. The GPS data is not in the exif tag but in a gps-specific tag, so the parsing code needs to be tweaked a bit to search for that additional tag in addition to the exif one.

As of now, I don't have time dive back into that parsing code, so feel free to have a go at implementing it. Documentation about the GPS tag is in the official EXIF specification (http://www.exiv2.org/Exif2-2.PDF).

Let me know how it goes!

K. Looks like a challenge for me. I'll check back in a few days if I don't make any progress. Thanks for this project btw!

Sorry but I've been unable to make any progress. I ended up using Ironholds' exif package.