TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

A fast, offline reverse geocoder in Python

181 pointsby jp_scabout 10 years ago

14 comments

yellowbkpkabout 10 years ago
If you&#x27;re interested in making both forward and reverse geocoding better, please consider paying attention to a project I started and help maintain called OpenAddresses:<p><a href="http://openaddresses.io" rel="nofollow">http:&#x2F;&#x2F;openaddresses.io</a><p>The goal is to collect address datasets so that forward and reverse geocoding is an easier problem to solve. A contributor wrote an excellent overview of the project the other day:<p><a href="https://medium.com/colemanm/creating-an-open-database-of-addresses-73a7d0dc24c5" rel="nofollow">https:&#x2F;&#x2F;medium.com&#x2F;colemanm&#x2F;creating-an-open-database-of-add...</a>
评论 #9281849 未加载
评论 #9281678 未加载
bzz01about 10 years ago
You can&#x27;t really use KD trees with lat&#x2F;lon coordinates, at least you can&#x27;t use euclidean distance there for nearest neighbor search.<p>First, longitude wraps from -180 to +180 at antimeridian, meaning distance calculations will fail there; second, and I&#x27;d say more importantly, one degree longitude length in meters differs a lot depending on latitude; meaning this library will be heavily biased towards longitudal neighbors when using it for locations far from equator.
评论 #9282477 未加载
评论 #9290882 未加载
评论 #9282018 未加载
natchabout 10 years ago
Kudos for a very well done README (and it&#x27;s not just cribbed from the original project, it explains the new stuff very well and tells what the project is, and gives credit back). So many projects neglect the README.<p>One question - is it OK to put an MIT license on something that is based on LGPL code? I don&#x27;t know enough about how the LGPL works (I do know it is less &quot;infective&quot; than plain GPL).<p>Well two questions: python2, or python3?
评论 #9281811 未加载
Animatsabout 10 years ago
While we&#x27;re on this subject, is there a good, free street address parser that will work for at least the US, Canada, UK, and the major EU countries? I&#x27;ve tried most of the available ones, and they can parse about 90-95% of business addresses.<p>(Regular expressions don&#x27;t work well for this. Neither does starting from the beginning of the address. Proper address parsing starts at the end of the address and works backwards, with the information found near the end, such as country name and postal code, used to disambiguate the information found earlier.)
评论 #9282918 未加载
评论 #9295650 未加载
mcbetzabout 10 years ago
Very good companion for Geocoder - <a href="https://github.com/DenisCarriere/geocoder" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;DenisCarriere&#x2F;geocoder</a>. Glad to see Python getting more geo libraries for Non-GIS users.
评论 #9281504 未加载
bronsonabout 10 years ago
Very impressive, I&#x27;ll be looking closer at K-D trees.<p>I wrote a quick (500k lookups&#x2F;sec) offline geocoder for Ruby: <a href="https://github.com/bronson/geolocal" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;bronson&#x2F;geolocal</a> to comply with the silly EU cookie rules. It precompiles the statements you&#x27;re interested in:<p><pre><code> Geolocal.in_eu?(request.ip) Geolocal.in_us?(&#x27;8.8.8.8&#x27;) </code></pre> Glad to see that my lib has a role model if it ever grows up. :)
zetahunterabout 10 years ago
Awesome, one more thing that can be made standalone instead of using google maps service.
评论 #9281325 未加载
sandstromabout 10 years ago
Looks really interesting!<p>Would it be possible to use OpenStreetMap data?<p><a href="http://planet.openstreetmap.org/" rel="nofollow">http:&#x2F;&#x2F;planet.openstreetmap.org&#x2F;</a>
评论 #9281410 未加载
评论 #9281350 未加载
nickstefan12about 10 years ago
Nice! Shameless plug for a SQLite no network geocoder that uses (I believe) the same text files to seed everything. <a href="https://github.com/NickStefan/no-network-geocoder" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;NickStefan&#x2F;no-network-geocoder</a>
_yid9about 10 years ago
On a related note: An efficient geolocation encoder&#x2F;decoder with error correction using Reed-Solomon. 3m accuracy with error correction in 10 symbols. 20mm accuracy with 5-nines certainty in 15 symbols:<p><a href="https://github.com/pjkundert/ezpwd-reed-solomon" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;pjkundert&#x2F;ezpwd-reed-solomon</a>
dexterbt1about 10 years ago
Starred. We&#x27;re currently using nominatim + osm data + postgis on our own hosted servers. Can this be a good alternative?
评论 #9281344 未加载
评论 #9281349 未加载
评论 #9281575 未加载
alexcrooxabout 10 years ago
This is great, does anyone know of a js version? I&#x27;m currently using <a href="http://nominatim.openstreetmap.org/reverse" rel="nofollow">http:&#x2F;&#x2F;nominatim.openstreetmap.org&#x2F;reverse</a> in my Node app but I&#x27;d rather not rely on a 3rd party, especially under heavy load.
评论 #9281599 未加载
thecodemonkeyabout 10 years ago
This is super cool! Shameless plug. If you&#x27;re looking for street-level reverse (or forward) geocoding, we offer[1] a super affordable API and CSV upload tool.<p>[1] <a href="http://geocod.io" rel="nofollow">http:&#x2F;&#x2F;geocod.io</a>
kelukelugamesabout 10 years ago
Hello, I read a little bit about geocoding on wikipedia but was hoping to learn more. Is a good beginner guide on geocdoer&#x2F;geocoding?