Questions tagged [geohashing]

Geohash is a latitude/longitude encoding system using Base-32 characters.

Geohash is a latitude/longitude geocode system invented by Gustavo Niemeyer when writing the web service at geohash.org, and put into the public domain. It is a hierarchical spatial data structure which subdivides space, then interleaves the latitude and longitude information in a bitwise fashion.

Geohashes offer properties like arbitrary precision and the possibility of gradually removing characters from the end of the code to reduce its size (and gradually lose precision).

Nearby places will often (but not always) present similar prefixes. The longer a shared prefix is, the closer the two places are.

See https://en.wikipedia.org/wiki/Geohash

188 questions
1
vote
1 answer

Why aren't geohashes perfect squares?

Why are the geohashes that are rendered as demonstrably-rectangular on the map not optimized to render as squares? If the purpose of the geohash is to allow single-property spatial indexing and geoquerying, why isn't the geohash optimized into…
trndjc
  • 11,654
  • 3
  • 38
  • 51
1
vote
1 answer

How to find the nearest geohash in mysql?

Recently I'm using GeoHash to hash the paired geo-coordinates into a hash value and store it in MySQL. Now I want to find the nearest hash given the other hash. I noticed that MYSQL provide BTree structure to find a range of nearest hashes by using…
AI_ROBOT
  • 958
  • 1
  • 9
  • 19
1
vote
0 answers

I need to find the geohashes within a 10km radius of tdr706. How can I do it?

I need to find all the geohashes that lie within a 10 km radius of the the geohash tdr706 . How do i do it?
Arjun Raaghav
  • 79
  • 1
  • 8
1
vote
1 answer

Geohash-16: how to

Situation: I have JavaScript code that creates geohash with base-32 system. var BASE32_CODES = "0123456789bcdefghjkmnpqrstuvwxyz"; var BASE32_CODES_DICT = {}; for (var i = 0; i < BASE32_CODES.length; i++) { …
Max Mikhalchuk
  • 147
  • 1
  • 1
  • 10
1
vote
0 answers

Median and percentiles in Kibana geohash grid aggregation

I have an index composed by lat,long,country,value that I want to plot both in the region map and the coordinate map. I want for every bucket (region or grid tile) the median or another percentile, for example 75%, but the only metric aggregation…
1
vote
1 answer

Elastic GeoHash Query - Aggregation Filter

I am trying to query an elastic index where the result of the query is a list of the geohashes with only one matching document. I can get a simple list of all geo hashes and their document counts using the following: { "size" : 0, …
ilivewithian
  • 19,476
  • 19
  • 103
  • 165
1
vote
1 answer

How to get nearby location in a specific range?

I have a array of latitude and longitude and a center point. { center: { lat: 10.002, lng: 20.003 }, all: [ { lat: 20, lng: 50 }, { lat: 10, lng: 20.000001 }, // ... ] } I would like to…
Larry Lu
  • 1,609
  • 3
  • 21
  • 28
1
vote
0 answers

ES 5.2.2 geohash string match query required

I recently installed ES 5.2.2 I am looking for my data migration and query migration. I wanted to know, how can we query the points within specified geohash string? GET my_type/_search { "query": {"term": {"location.geohash": "9q8yy"}} }
1
vote
1 answer

Mapping definition for [location] has unsupported parameters: [geohash : true] : Elasticsearch 5.X

I'm using elasticsearch 5.2, but when setting up index mapping with [geohash:true] for a geo_point field I'm getting the following error { "error": { "root_cause": [ { "type": "mapper_parsing_exception", "reason":…
1
vote
0 answers

How to make quadrants of a city using geohash in Python?

I want to map a city in quadrants using Python and I know that exists a module called 'geohash' which can return a hash from concrete coordinates. However, I don't know how can I map and split a city in quadrants of X size. If someone could…
justme
  • 33
  • 1
  • 1
  • 9
1
vote
2 answers

Elastic search 2.4 Geohash cell query

I have following mapping in my elasticsearch: { "mappings": { "event": { "_all": { "enabled": false }, "properties": { "type": { "type": "string", "index": "not_analyzed"}, "id": { "type": "string"}, …
Liplttaa
  • 11
  • 2
1
vote
0 answers

Logstash query elasticsearch geohash data

I am aggregating the location data using geohash, which works well on the Chrome Sense plugin, but once i try to query through logstash as an input plugin of elasticsearch, its not working... My Sense Query: POST/_search { "query": { "match_all":…
1
vote
0 answers

How to calculate the HashBits length with Radius Meters in the geohash?

https://github.com/yinqiwen/ardb/wiki/Spatial-Index https://en.wikipedia.org/wiki/Geohash Based on the github for the Radius Meters 2500km and 626km, the HashBits length 8 and 12, however based on the wikipedia for 2500km and 630 km error, the …
Jason
  • 1,115
  • 14
  • 25
1
vote
1 answer

Compare geohashes between two pandas dataframes

I have 2 dataframes df1 and df2 with different Latitutde and Longitude along with their corresponding geohashes. Now for each geohash in df1, I want to find the closest geohash in dataframe df2. I am not sure whether is there a way to compare…
user3447653
  • 3,968
  • 12
  • 58
  • 100
1
vote
1 answer

Why java string hashCode has many collisions on different but similar geohash strings?

Geohash string is a feature in my sparse logistic regression model. So I used java string hashCode to generate int value on geohash string in order to get feature id. But I found hashCode method performs badly on similar geohash strings. It cause…
formath
  • 319
  • 3
  • 17