ExifTool Forum

ExifTool => The "exiftool" Application => Topic started by: TimA on November 14, 2024, 06:45:50 PM

Title: geolocation - database from geonames.org
Post by: TimA on November 14, 2024, 06:45:50 PM
Been exploring exiftool's "geolocation information (including city, region, subregion and country) from GPS coordinates (and visa versa) using an included database of all cities with population 2000 or greater based on a Creative Commons database geonames.org"

Question: exiftool is 324 K file while a dump of the geonames file is 9.1Meg.
Where is the latter stored? And is it updated with each new version of exiftool?
Thanks
Title: Re: geolocation - database from geonames.org
Post by: StarGeek on November 14, 2024, 07:51:50 PM
Quote from: TimA on November 14, 2024, 06:45:50 PMuestion: exiftool is 324 K file while a dump of the geonames file is 9.1Meg.
Where is the latter stored?

The full database isn't included. From this previous post
Quote from: Phil Harvey on March 06, 2024, 09:49:48 AMThe >1000-population city database from geonames.org (https://download.geonames.org/export/) that FrankB mentioned, but I have reformatted the database to reduce the file size.

You can find further details in that thread and in the Geolocation.pm source code (https://github.com/exiftool/exiftool/blob/master/lib/Image/ExifTool/Geolocation.pm).

Quote from: TimA on November 14, 2024, 06:45:50 PMAnd is it updated with each new version of exiftool?

It doesn't look like it's updated every time. You can check the version history, as it appears to be included. For example, it was updated with Version 13.00, Oct. 29, 2024 (https://exiftool.org/history.html#v13.00).
Title: Re: geolocation - database from geonames.org
Post by: Phil Harvey on November 14, 2024, 10:10:37 PM
I plan to update the geolocation database with each production version (every couple of months or so).

Currently the included database is cities with population > 2000 (read here (http://exiftool.org/geolocation.html) for more details), and its size is 2.9 MB.  I've worked hard to store it as efficiently as I could to reduce the size.

- Phil