Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/a-b-street/country-geocoder

Reverse geocode WGS84 coordinates to an ISO country-code
https://github.com/a-b-street/country-geocoder

Last synced: 3 months ago
JSON representation

Reverse geocode WGS84 coordinates to an ISO country-code

Awesome Lists containing this project

README

        

# country-geocoder

This crate takes a WGS84 coordinate and determines the [two-letter ISO country
code](https://en.wikipedia.org/wiki/ISO_3166-1_alpha-2) where it exists. It
also determines if that country drives on the left or right. It does this by
offline geocoding, using a bundled file.

`data.geojson` is produced by `generate_data.py`. Thanks to
for preprocessing public domain Natural Earth data of
country boundaries, and to Tobias Zwick for
[countrymetadata](https://github.com/streetcomplete/countrymetadata) and for
[inspiring this approach](https://github.com/westnordost/countryboundaries).