geo-indexing: efficiently calculating proximity based on latitude/longitude

Posted by AnC on Stack Overflow See other posts from Stack Overflow or by AnC
Published on 2010-03-17T07:48:41Z Indexed on 2010/03/17 7:51 UTC
Read the original article Hit count: 374

Filed under:

My simple web app (WSGI, Python) supports text queries to find items in the database. Now I'd like to extend this to allow for queries like "find all items within 1 mile of {lat,long}".

Of course that's a complex job if efficiency is a concern, so I'm thinking of a dedicated external module that does indexing for geo-coordinates - sort of like Lucene would for text.

I assume a generic component like this already exists, but haven't been able to find anything so far. Any help would be greatly appreciated.

© Stack Overflow or respective owner

Related posts about geolocation