SlideShare a Scribd company logo
1 of 19
Download to read offline
GeoHash
encode(lat/long) --> 'string'
What's the plan today?
What is geohash?
Why do we need it?
geohash.org
How does it work?
Grouping and Zooming
Nearby (proximity) searches
The Edge case
Limitations
Demo (Let's see it working)
Who am I?
Co-Founded Ideophone with @oligoglot & @anenth
helped building @pyka, @suruk, @onetouchsos,
@kopa_app
product architecture, platform development
x-SunTec, x-TAT, mtech from IIIT-B
What is geohash?
Simple way to encode lat/long into a string
Compact string encoding of geographic coordinate with
arbitrary precision
    Bangalore - TDR1, Domlur - TDR1WX




Invented by Gustavo Niemeyer for geohash.org
Available in public domain http://en.wikipedia.org/wiki/geohash/
Why do we need it when we have LL?
Big address of this venue
Complicated Lat/Long {12.963787,77.637789}




      The Mail from Cartonama could've said Venue:
                    "tdr1wxyp5dn7v"
● Subdivides space into "buckets" of grid shape
● Doesn't really represent a point, rather a bounding
   area in which the point is present
● Hierarchical spatial structure with gradual degradation
● Longer the geohash
   -> Smaller the area


Demo
How does it work?




11001 01100 10111 00001 11100 11101 11110 10101 00101 01100 10100 00111 11011
  t     d     r    1     w     x    y     p       5     d     n      7    v !
geohash.org
              Short URL uniquely
              identifying points on
              earth




              Referencing them on
              emails, website etc
              becomes far more
              convenient




              Bangalore:
              http://geohash.org/tdr1
              Domlur:
              http://geohash.
              org/tdr1wx
Grouping and Zooming
Easy grouping
   ○ tdr1wxyp5dn7v -> {12.9637069, 77.6377931}
         ●   4th Main Rd, Domlur II Stage, Domlur, Bengaluru, Karnataka

   ○ tdr1wxyp5dn7v -> {12.9637, 77.6378}
         ●   Domlur, Bengaluru, Karnataka

   ○ tdr1wxyp5dn7v -> {12.96, 77.64}
         ●   Bengaluru, Karnataka

   ○ tdr1wxyp5dn7v -> {13, 78}
         ●   Malur-Bangarapettu Rd
Nearby (Proximity) Search

● Nearby locations usually share similar prefixes.
● Long common prefixes indicate two places are near,
   however two nearby places do not always have
   common prefixes
There is an Edge Case:
E.g. Two nearby places in Boston
DRT..
DRM..
Nearby Search
tdr1wxyp5dn7v (TERI)
tdr1wxyqekmg (Bangalore I'ntl Chapter)
tdr1y8jbvrmc (Domlur Club)
tdr1y8jykh6w (CIS)
tdr1ybmhdj4p (Ideophone)
tdr1v4e3mecx (Majestic Station)
tf346wn2t49t (Chennai Central)
9q8vzpgn7we0 (SFO Airport)
Finding Nearby Places
Python, Perl, PHP, Java etc
python-geohash
    ○   Encode/Decode
    ○   BoundingBox
           {'s': 12.919921875,

           'e': 77.6513671875,

           'w': 77.607421875,

           'n': 12.9638671875}

    ○   Neighbours
           ['ezefx','ezefr','ezefp','ezs40',

           'ezs41','ezs43','ezs49','ezs48']
Finding Nearby Places
● Proximity Search
   ○ Bottoms-Up




                        ● Bounding Box Search
                           ○ Hops to neighbors
                             until POI is found
Finding Nearby Places

● Compute geohash
  values for all Lat/Long
● Have index on
  geohash for quicker
  retrievals
Finding Nearby Places
● Prefix Match:
   SELECT * FROM table WHERE place_geohash LIKE hashcode%

● Expand/Neighbors Match
   SELECT * FROM table WHERE place_geohash IN (geohash.expand('tzxy1'))
Limitations

● Locality Anomalies
   ○ Complicates Proximity Searches
   ○ Need to use bounding box extensively making
      search an expensive operation



● Projection based model
   ○ A geohash of given length will denote different
      region size in poles than in equator region
Demo
http://openlocation.org/geohash/geohash-js/
http://geohash.gofreerange.com/
Conclusions

● Simple and effective system to map complex lat-long
   coordinates into simple string representations



● Useful in applications where "nearness" of POIs is
   more relevant than accurate distance computation



● Enables quick db access using LIKE using grouping of
   prefixes of geohashes
Thank you!
@sandeepbhaskar
https://github.com/sandeepbhaskar/geohash-demo

More Related Content

What's hot

The Integration of Geospatial Technologies: GIS and GPS
The Integration of Geospatial Technologies: GIS and GPS	The Integration of Geospatial Technologies: GIS and GPS
The Integration of Geospatial Technologies: GIS and GPS Lindsey Landolfi
 
RDB2RDF Tutorial (R2RML and Direct Mapping) at ISWC 2013
RDB2RDF Tutorial (R2RML and Direct Mapping) at ISWC 2013RDB2RDF Tutorial (R2RML and Direct Mapping) at ISWC 2013
RDB2RDF Tutorial (R2RML and Direct Mapping) at ISWC 2013Juan Sequeda
 
Integrating PostGIS in Web Applications
Integrating PostGIS in Web ApplicationsIntegrating PostGIS in Web Applications
Integrating PostGIS in Web ApplicationsCommand Prompt., Inc
 
Web Mapping 101: What Is It and Making It Work For You
Web Mapping 101: What Is It and Making It Work For YouWeb Mapping 101: What Is It and Making It Work For You
Web Mapping 101: What Is It and Making It Work For YouSafe Software
 
MySQL 8.0で強化されたGIS機能のご紹介と周辺ツールとの連携について
MySQL 8.0で強化されたGIS機能のご紹介と周辺ツールとの連携についてMySQL 8.0で強化されたGIS機能のご紹介と周辺ツールとの連携について
MySQL 8.0で強化されたGIS機能のご紹介と周辺ツールとの連携についてyoyamasaki
 
Introduction To PostGIS
Introduction To PostGISIntroduction To PostGIS
Introduction To PostGISmleslie
 
Introduction to GPS
Introduction to GPSIntroduction to GPS
Introduction to GPSDaniel Kim
 
Building Enterprise SDI with Geonode
Building Enterprise SDI with GeonodeBuilding Enterprise SDI with Geonode
Building Enterprise SDI with GeonodeRafael Soto
 
India Enters Golden Jubilee of Rocket Launch
India Enters Golden Jubilee of Rocket LaunchIndia Enters Golden Jubilee of Rocket Launch
India Enters Golden Jubilee of Rocket LaunchDr. Pranabjyoti Das
 
지리정보체계(GIS) - [2] 좌표계 이해하기
지리정보체계(GIS) - [2] 좌표계 이해하기지리정보체계(GIS) - [2] 좌표계 이해하기
지리정보체계(GIS) - [2] 좌표계 이해하기Byeong-Hyeok Yu
 
Introduction to GIS
Introduction to GISIntroduction to GIS
Introduction to GISJoey Li
 
Precision AI Inc. - Ag & Tech
Precision AI Inc. - Ag & TechPrecision AI Inc. - Ag & Tech
Precision AI Inc. - Ag & TechNaiomi Lynn
 

What's hot (20)

The Integration of Geospatial Technologies: GIS and GPS
The Integration of Geospatial Technologies: GIS and GPS	The Integration of Geospatial Technologies: GIS and GPS
The Integration of Geospatial Technologies: GIS and GPS
 
Hadoop HDFS.ppt
Hadoop HDFS.pptHadoop HDFS.ppt
Hadoop HDFS.ppt
 
Gephi Toolkit Tutorial
Gephi Toolkit TutorialGephi Toolkit Tutorial
Gephi Toolkit Tutorial
 
Unit-3_BDA.ppt
Unit-3_BDA.pptUnit-3_BDA.ppt
Unit-3_BDA.ppt
 
RDB2RDF Tutorial (R2RML and Direct Mapping) at ISWC 2013
RDB2RDF Tutorial (R2RML and Direct Mapping) at ISWC 2013RDB2RDF Tutorial (R2RML and Direct Mapping) at ISWC 2013
RDB2RDF Tutorial (R2RML and Direct Mapping) at ISWC 2013
 
Integrating PostGIS in Web Applications
Integrating PostGIS in Web ApplicationsIntegrating PostGIS in Web Applications
Integrating PostGIS in Web Applications
 
LeafletでWebGIS入門
LeafletでWebGIS入門LeafletでWebGIS入門
LeafletでWebGIS入門
 
Web Mapping 101: What Is It and Making It Work For You
Web Mapping 101: What Is It and Making It Work For YouWeb Mapping 101: What Is It and Making It Work For You
Web Mapping 101: What Is It and Making It Work For You
 
Open layers
Open layersOpen layers
Open layers
 
Presentation on gis and future trends
Presentation on gis and future trendsPresentation on gis and future trends
Presentation on gis and future trends
 
MySQL 8.0で強化されたGIS機能のご紹介と周辺ツールとの連携について
MySQL 8.0で強化されたGIS機能のご紹介と周辺ツールとの連携についてMySQL 8.0で強化されたGIS機能のご紹介と周辺ツールとの連携について
MySQL 8.0で強化されたGIS機能のご紹介と周辺ツールとの連携について
 
Introduction To PostGIS
Introduction To PostGISIntroduction To PostGIS
Introduction To PostGIS
 
Introduction to GPS
Introduction to GPSIntroduction to GPS
Introduction to GPS
 
Building Enterprise SDI with Geonode
Building Enterprise SDI with GeonodeBuilding Enterprise SDI with Geonode
Building Enterprise SDI with Geonode
 
India Enters Golden Jubilee of Rocket Launch
India Enters Golden Jubilee of Rocket LaunchIndia Enters Golden Jubilee of Rocket Launch
India Enters Golden Jubilee of Rocket Launch
 
지리정보체계(GIS) - [2] 좌표계 이해하기
지리정보체계(GIS) - [2] 좌표계 이해하기지리정보체계(GIS) - [2] 좌표계 이해하기
지리정보체계(GIS) - [2] 좌표계 이해하기
 
Introduction to GIS
Introduction to GISIntroduction to GIS
Introduction to GIS
 
Hadoop ecosystem
Hadoop ecosystemHadoop ecosystem
Hadoop ecosystem
 
Precision AI Inc. - Ag & Tech
Precision AI Inc. - Ag & TechPrecision AI Inc. - Ag & Tech
Precision AI Inc. - Ag & Tech
 
Gps tracking system
Gps tracking system Gps tracking system
Gps tracking system
 

Viewers also liked

Scaling GIS Data in Non-relational Data Stores
Scaling GIS Data in Non-relational Data StoresScaling GIS Data in Non-relational Data Stores
Scaling GIS Data in Non-relational Data StoresMike Malone
 
Architecture at SimpleGeo: Staying Agile at Scale
Architecture at SimpleGeo: Staying Agile at ScaleArchitecture at SimpleGeo: Staying Agile at Scale
Architecture at SimpleGeo: Staying Agile at ScaleMike Malone
 
GeoPackage, Context and POI (and a sprinkle of GeoJSON)
GeoPackage, Context and POI (and a sprinkle of GeoJSON)GeoPackage, Context and POI (and a sprinkle of GeoJSON)
GeoPackage, Context and POI (and a sprinkle of GeoJSON) Raj Singh
 
Geohash in mapping applications
Geohash in mapping applicationsGeohash in mapping applications
Geohash in mapping applicationsAlex Tumanoff
 
Serverless Geospatial Mobile Apps with AWS
Serverless Geospatial Mobile Apps with AWSServerless Geospatial Mobile Apps with AWS
Serverless Geospatial Mobile Apps with AWSAmazon Web Services
 
Osc2012 spring HBase Report
Osc2012 spring HBase ReportOsc2012 spring HBase Report
Osc2012 spring HBase ReportSeiichiro Ishida
 
How To Analyze Geolocation Data with Hive and Hadoop
How To Analyze Geolocation Data with Hive and HadoopHow To Analyze Geolocation Data with Hive and Hadoop
How To Analyze Geolocation Data with Hive and HadoopHortonworks
 
"Spark Search" - In-memory, Distributed Search with Lucene, Spark, and Tachyo...
"Spark Search" - In-memory, Distributed Search with Lucene, Spark, and Tachyo..."Spark Search" - In-memory, Distributed Search with Lucene, Spark, and Tachyo...
"Spark Search" - In-memory, Distributed Search with Lucene, Spark, and Tachyo...Lucidworks
 
Facebook Messages & HBase
Facebook Messages & HBaseFacebook Messages & HBase
Facebook Messages & HBase强 王
 
Spark: Interactive To Production
Spark: Interactive To ProductionSpark: Interactive To Production
Spark: Interactive To ProductionJen Aman
 
LuceneRDD for (Geospatial) Search and Entity Linkage
LuceneRDD for (Geospatial) Search and Entity LinkageLuceneRDD for (Geospatial) Search and Entity Linkage
LuceneRDD for (Geospatial) Search and Entity Linkagezouzias
 
GIS presentation
GIS presentationGIS presentation
GIS presentationarniontech
 
Drizzle—Low Latency Execution for Apache Spark: Spark Summit East talk by Shi...
Drizzle—Low Latency Execution for Apache Spark: Spark Summit East talk by Shi...Drizzle—Low Latency Execution for Apache Spark: Spark Summit East talk by Shi...
Drizzle—Low Latency Execution for Apache Spark: Spark Summit East talk by Shi...Spark Summit
 

Viewers also liked (16)

Spatial search with geohashes
Spatial search with geohashesSpatial search with geohashes
Spatial search with geohashes
 
Scaling GIS Data in Non-relational Data Stores
Scaling GIS Data in Non-relational Data StoresScaling GIS Data in Non-relational Data Stores
Scaling GIS Data in Non-relational Data Stores
 
Architecture at SimpleGeo: Staying Agile at Scale
Architecture at SimpleGeo: Staying Agile at ScaleArchitecture at SimpleGeo: Staying Agile at Scale
Architecture at SimpleGeo: Staying Agile at Scale
 
GeoPackage, Context and POI (and a sprinkle of GeoJSON)
GeoPackage, Context and POI (and a sprinkle of GeoJSON)GeoPackage, Context and POI (and a sprinkle of GeoJSON)
GeoPackage, Context and POI (and a sprinkle of GeoJSON)
 
Geohash in mapping applications
Geohash in mapping applicationsGeohash in mapping applications
Geohash in mapping applications
 
投影法
投影法投影法
投影法
 
Serverless Geospatial Mobile Apps with AWS
Serverless Geospatial Mobile Apps with AWSServerless Geospatial Mobile Apps with AWS
Serverless Geospatial Mobile Apps with AWS
 
Osc2012 spring HBase Report
Osc2012 spring HBase ReportOsc2012 spring HBase Report
Osc2012 spring HBase Report
 
How To Analyze Geolocation Data with Hive and Hadoop
How To Analyze Geolocation Data with Hive and HadoopHow To Analyze Geolocation Data with Hive and Hadoop
How To Analyze Geolocation Data with Hive and Hadoop
 
"Spark Search" - In-memory, Distributed Search with Lucene, Spark, and Tachyo...
"Spark Search" - In-memory, Distributed Search with Lucene, Spark, and Tachyo..."Spark Search" - In-memory, Distributed Search with Lucene, Spark, and Tachyo...
"Spark Search" - In-memory, Distributed Search with Lucene, Spark, and Tachyo...
 
Facebook Messages & HBase
Facebook Messages & HBaseFacebook Messages & HBase
Facebook Messages & HBase
 
Spark: Interactive To Production
Spark: Interactive To ProductionSpark: Interactive To Production
Spark: Interactive To Production
 
LuceneRDD for (Geospatial) Search and Entity Linkage
LuceneRDD for (Geospatial) Search and Entity LinkageLuceneRDD for (Geospatial) Search and Entity Linkage
LuceneRDD for (Geospatial) Search and Entity Linkage
 
GraphQL 101
GraphQL 101GraphQL 101
GraphQL 101
 
GIS presentation
GIS presentationGIS presentation
GIS presentation
 
Drizzle—Low Latency Execution for Apache Spark: Spark Summit East talk by Shi...
Drizzle—Low Latency Execution for Apache Spark: Spark Summit East talk by Shi...Drizzle—Low Latency Execution for Apache Spark: Spark Summit East talk by Shi...
Drizzle—Low Latency Execution for Apache Spark: Spark Summit East talk by Shi...
 

Similar to Geohash

Locality Sensitive Hashing By Spark
Locality Sensitive Hashing By SparkLocality Sensitive Hashing By Spark
Locality Sensitive Hashing By SparkSpark Summit
 
Real-time GeoSearching at Scale with RediSearch by Apoorva Gaurav and Ronil M...
Real-time GeoSearching at Scale with RediSearch by Apoorva Gaurav and Ronil M...Real-time GeoSearching at Scale with RediSearch by Apoorva Gaurav and Ronil M...
Real-time GeoSearching at Scale with RediSearch by Apoorva Gaurav and Ronil M...Redis Labs
 
Shortest route finding using an object oriented database approach
Shortest route finding using an object oriented database approachShortest route finding using an object oriented database approach
Shortest route finding using an object oriented database approachAlexander Decker
 
Magellan FOSS4G Talk, Boston 2017
Magellan FOSS4G Talk, Boston 2017Magellan FOSS4G Talk, Boston 2017
Magellan FOSS4G Talk, Boston 2017Ram Sriharsha
 
2017 RM-URISA Track: Spatial SQL - The Best Kept Secret in the Geospatial World
2017 RM-URISA Track:  Spatial SQL - The Best Kept Secret in the Geospatial World2017 RM-URISA Track:  Spatial SQL - The Best Kept Secret in the Geospatial World
2017 RM-URISA Track: Spatial SQL - The Best Kept Secret in the Geospatial WorldGIS in the Rockies
 
Approximate shortest distance computing
Approximate shortest distance computingApproximate shortest distance computing
Approximate shortest distance computingLeMeniz Infotech
 
Bandwidth distributed denial of service attacks and defenses
Bandwidth distributed denial of service attacks and defensesBandwidth distributed denial of service attacks and defenses
Bandwidth distributed denial of service attacks and defensesLeMeniz Infotech
 
Location Analytics Real-Time Geofencing using Kafka
Location Analytics Real-Time Geofencing using KafkaLocation Analytics Real-Time Geofencing using Kafka
Location Analytics Real-Time Geofencing using KafkaGuido Schmutz
 
mini project_shortest path visualizer.pptx
mini project_shortest path visualizer.pptxmini project_shortest path visualizer.pptx
mini project_shortest path visualizer.pptxtusharpawar803067
 
Node Path Visualizer Using Shortest Path Algorithms
Node Path Visualizer Using Shortest Path AlgorithmsNode Path Visualizer Using Shortest Path Algorithms
Node Path Visualizer Using Shortest Path AlgorithmsIRJET Journal
 
Introduction To Geocoding: Linda Achieng
Introduction To Geocoding: Linda AchiengIntroduction To Geocoding: Linda Achieng
Introduction To Geocoding: Linda AchiengRedis Labs
 
Postgres Vision 2018: PostGIS and Spatial Extensions
Postgres Vision 2018: PostGIS and Spatial ExtensionsPostgres Vision 2018: PostGIS and Spatial Extensions
Postgres Vision 2018: PostGIS and Spatial ExtensionsEDB
 
Corinne Hutchinson's 7/8/2015 PuPPy Presentation on GeoDjango
Corinne Hutchinson's 7/8/2015 PuPPy Presentation on GeoDjangoCorinne Hutchinson's 7/8/2015 PuPPy Presentation on GeoDjango
Corinne Hutchinson's 7/8/2015 PuPPy Presentation on GeoDjangoDon Sheu
 
How to Analyze & Optimize Mobility with Geospatial Data (Snowflake).pdf
How to Analyze & Optimize Mobility with Geospatial Data (Snowflake).pdfHow to Analyze & Optimize Mobility with Geospatial Data (Snowflake).pdf
How to Analyze & Optimize Mobility with Geospatial Data (Snowflake).pdfCARTO
 
Let Android dream electric sheep: Making emotion model for chat-bot with Pyth...
Let Android dream electric sheep: Making emotion model for chat-bot with Pyth...Let Android dream electric sheep: Making emotion model for chat-bot with Pyth...
Let Android dream electric sheep: Making emotion model for chat-bot with Pyth...Jeongkyu Shin
 
Евгений Хыст: "Server-Side Geo-Clustering Based on Geohash"
Евгений Хыст: "Server-Side Geo-Clustering Based on Geohash"Евгений Хыст: "Server-Side Geo-Clustering Based on Geohash"
Евгений Хыст: "Server-Side Geo-Clustering Based on Geohash"Anna Shymchenko
 
Lecture 8: IoT System Models and Applications
Lecture 8: IoT System Models and ApplicationsLecture 8: IoT System Models and Applications
Lecture 8: IoT System Models and ApplicationsPayamBarnaghi
 

Similar to Geohash (20)

Locality Sensitive Hashing By Spark
Locality Sensitive Hashing By SparkLocality Sensitive Hashing By Spark
Locality Sensitive Hashing By Spark
 
Real-time GeoSearching at Scale with RediSearch by Apoorva Gaurav and Ronil M...
Real-time GeoSearching at Scale with RediSearch by Apoorva Gaurav and Ronil M...Real-time GeoSearching at Scale with RediSearch by Apoorva Gaurav and Ronil M...
Real-time GeoSearching at Scale with RediSearch by Apoorva Gaurav and Ronil M...
 
Geo data analytics
Geo data analyticsGeo data analytics
Geo data analytics
 
VenmoPlus demo week6
VenmoPlus demo week6VenmoPlus demo week6
VenmoPlus demo week6
 
Shortest route finding using an object oriented database approach
Shortest route finding using an object oriented database approachShortest route finding using an object oriented database approach
Shortest route finding using an object oriented database approach
 
Magellan FOSS4G Talk, Boston 2017
Magellan FOSS4G Talk, Boston 2017Magellan FOSS4G Talk, Boston 2017
Magellan FOSS4G Talk, Boston 2017
 
2017 RM-URISA Track: Spatial SQL - The Best Kept Secret in the Geospatial World
2017 RM-URISA Track:  Spatial SQL - The Best Kept Secret in the Geospatial World2017 RM-URISA Track:  Spatial SQL - The Best Kept Secret in the Geospatial World
2017 RM-URISA Track: Spatial SQL - The Best Kept Secret in the Geospatial World
 
Approximate shortest distance computing
Approximate shortest distance computingApproximate shortest distance computing
Approximate shortest distance computing
 
Bandwidth distributed denial of service attacks and defenses
Bandwidth distributed denial of service attacks and defensesBandwidth distributed denial of service attacks and defenses
Bandwidth distributed denial of service attacks and defenses
 
Location Analytics Real-Time Geofencing using Kafka
Location Analytics Real-Time Geofencing using KafkaLocation Analytics Real-Time Geofencing using Kafka
Location Analytics Real-Time Geofencing using Kafka
 
mini project_shortest path visualizer.pptx
mini project_shortest path visualizer.pptxmini project_shortest path visualizer.pptx
mini project_shortest path visualizer.pptx
 
Node Path Visualizer Using Shortest Path Algorithms
Node Path Visualizer Using Shortest Path AlgorithmsNode Path Visualizer Using Shortest Path Algorithms
Node Path Visualizer Using Shortest Path Algorithms
 
Introduction To Geocoding: Linda Achieng
Introduction To Geocoding: Linda AchiengIntroduction To Geocoding: Linda Achieng
Introduction To Geocoding: Linda Achieng
 
Postgres Vision 2018: PostGIS and Spatial Extensions
Postgres Vision 2018: PostGIS and Spatial ExtensionsPostgres Vision 2018: PostGIS and Spatial Extensions
Postgres Vision 2018: PostGIS and Spatial Extensions
 
Corinne Hutchinson's 7/8/2015 PuPPy Presentation on GeoDjango
Corinne Hutchinson's 7/8/2015 PuPPy Presentation on GeoDjangoCorinne Hutchinson's 7/8/2015 PuPPy Presentation on GeoDjango
Corinne Hutchinson's 7/8/2015 PuPPy Presentation on GeoDjango
 
How to Analyze & Optimize Mobility with Geospatial Data (Snowflake).pdf
How to Analyze & Optimize Mobility with Geospatial Data (Snowflake).pdfHow to Analyze & Optimize Mobility with Geospatial Data (Snowflake).pdf
How to Analyze & Optimize Mobility with Geospatial Data (Snowflake).pdf
 
Let Android dream electric sheep: Making emotion model for chat-bot with Pyth...
Let Android dream electric sheep: Making emotion model for chat-bot with Pyth...Let Android dream electric sheep: Making emotion model for chat-bot with Pyth...
Let Android dream electric sheep: Making emotion model for chat-bot with Pyth...
 
Евгений Хыст: "Server-Side Geo-Clustering Based on Geohash"
Евгений Хыст: "Server-Side Geo-Clustering Based on Geohash"Евгений Хыст: "Server-Side Geo-Clustering Based on Geohash"
Евгений Хыст: "Server-Side Geo-Clustering Based on Geohash"
 
distance_matrix_ch
distance_matrix_chdistance_matrix_ch
distance_matrix_ch
 
Lecture 8: IoT System Models and Applications
Lecture 8: IoT System Models and ApplicationsLecture 8: IoT System Models and Applications
Lecture 8: IoT System Models and Applications
 

Recently uploaded

Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)Kaya Weers
 
Tampa BSides - The No BS SOC (slides from April 6, 2024 talk)
Tampa BSides - The No BS SOC (slides from April 6, 2024 talk)Tampa BSides - The No BS SOC (slides from April 6, 2024 talk)
Tampa BSides - The No BS SOC (slides from April 6, 2024 talk)Mark Simos
 
Irene Moetsana-Moeng: Stakeholders in Cybersecurity: Collaborative Defence fo...
Irene Moetsana-Moeng: Stakeholders in Cybersecurity: Collaborative Defence fo...Irene Moetsana-Moeng: Stakeholders in Cybersecurity: Collaborative Defence fo...
Irene Moetsana-Moeng: Stakeholders in Cybersecurity: Collaborative Defence fo...itnewsafrica
 
Email Marketing Automation for Bonterra Impact Management (fka Social Solutio...
Email Marketing Automation for Bonterra Impact Management (fka Social Solutio...Email Marketing Automation for Bonterra Impact Management (fka Social Solutio...
Email Marketing Automation for Bonterra Impact Management (fka Social Solutio...Jeffrey Haguewood
 
Why device, WIFI, and ISP insights are crucial to supporting remote Microsoft...
Why device, WIFI, and ISP insights are crucial to supporting remote Microsoft...Why device, WIFI, and ISP insights are crucial to supporting remote Microsoft...
Why device, WIFI, and ISP insights are crucial to supporting remote Microsoft...panagenda
 
[Webinar] SpiraTest - Setting New Standards in Quality Assurance
[Webinar] SpiraTest - Setting New Standards in Quality Assurance[Webinar] SpiraTest - Setting New Standards in Quality Assurance
[Webinar] SpiraTest - Setting New Standards in Quality AssuranceInflectra
 
Testing tools and AI - ideas what to try with some tool examples
Testing tools and AI - ideas what to try with some tool examplesTesting tools and AI - ideas what to try with some tool examples
Testing tools and AI - ideas what to try with some tool examplesKari Kakkonen
 
Varsha Sewlal- Cyber Attacks on Critical Critical Infrastructure
Varsha Sewlal- Cyber Attacks on Critical Critical InfrastructureVarsha Sewlal- Cyber Attacks on Critical Critical Infrastructure
Varsha Sewlal- Cyber Attacks on Critical Critical Infrastructureitnewsafrica
 
MuleSoft Online Meetup Group - B2B Crash Course: Release SparkNotes
MuleSoft Online Meetup Group - B2B Crash Course: Release SparkNotesMuleSoft Online Meetup Group - B2B Crash Course: Release SparkNotes
MuleSoft Online Meetup Group - B2B Crash Course: Release SparkNotesManik S Magar
 
Potential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and InsightsPotential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and InsightsRavi Sanghani
 
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyes
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyesHow to Effectively Monitor SD-WAN and SASE Environments with ThousandEyes
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyesThousandEyes
 
Assure Ecommerce and Retail Operations Uptime with ThousandEyes
Assure Ecommerce and Retail Operations Uptime with ThousandEyesAssure Ecommerce and Retail Operations Uptime with ThousandEyes
Assure Ecommerce and Retail Operations Uptime with ThousandEyesThousandEyes
 
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...Wes McKinney
 
Generative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdfGenerative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdfIngrid Airi González
 
So einfach geht modernes Roaming fuer Notes und Nomad.pdf
So einfach geht modernes Roaming fuer Notes und Nomad.pdfSo einfach geht modernes Roaming fuer Notes und Nomad.pdf
So einfach geht modernes Roaming fuer Notes und Nomad.pdfpanagenda
 
Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024Hiroshi SHIBATA
 
Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...
Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...
Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...Nikki Chapple
 
JET Technology Labs White Paper for Virtualized Security and Encryption Techn...
JET Technology Labs White Paper for Virtualized Security and Encryption Techn...JET Technology Labs White Paper for Virtualized Security and Encryption Techn...
JET Technology Labs White Paper for Virtualized Security and Encryption Techn...amber724300
 
A Framework for Development in the AI Age
A Framework for Development in the AI AgeA Framework for Development in the AI Age
A Framework for Development in the AI AgeCprime
 
Bridging Between CAD & GIS: 6 Ways to Automate Your Data Integration
Bridging Between CAD & GIS:  6 Ways to Automate Your Data IntegrationBridging Between CAD & GIS:  6 Ways to Automate Your Data Integration
Bridging Between CAD & GIS: 6 Ways to Automate Your Data Integrationmarketing932765
 

Recently uploaded (20)

Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)
 
Tampa BSides - The No BS SOC (slides from April 6, 2024 talk)
Tampa BSides - The No BS SOC (slides from April 6, 2024 talk)Tampa BSides - The No BS SOC (slides from April 6, 2024 talk)
Tampa BSides - The No BS SOC (slides from April 6, 2024 talk)
 
Irene Moetsana-Moeng: Stakeholders in Cybersecurity: Collaborative Defence fo...
Irene Moetsana-Moeng: Stakeholders in Cybersecurity: Collaborative Defence fo...Irene Moetsana-Moeng: Stakeholders in Cybersecurity: Collaborative Defence fo...
Irene Moetsana-Moeng: Stakeholders in Cybersecurity: Collaborative Defence fo...
 
Email Marketing Automation for Bonterra Impact Management (fka Social Solutio...
Email Marketing Automation for Bonterra Impact Management (fka Social Solutio...Email Marketing Automation for Bonterra Impact Management (fka Social Solutio...
Email Marketing Automation for Bonterra Impact Management (fka Social Solutio...
 
Why device, WIFI, and ISP insights are crucial to supporting remote Microsoft...
Why device, WIFI, and ISP insights are crucial to supporting remote Microsoft...Why device, WIFI, and ISP insights are crucial to supporting remote Microsoft...
Why device, WIFI, and ISP insights are crucial to supporting remote Microsoft...
 
[Webinar] SpiraTest - Setting New Standards in Quality Assurance
[Webinar] SpiraTest - Setting New Standards in Quality Assurance[Webinar] SpiraTest - Setting New Standards in Quality Assurance
[Webinar] SpiraTest - Setting New Standards in Quality Assurance
 
Testing tools and AI - ideas what to try with some tool examples
Testing tools and AI - ideas what to try with some tool examplesTesting tools and AI - ideas what to try with some tool examples
Testing tools and AI - ideas what to try with some tool examples
 
Varsha Sewlal- Cyber Attacks on Critical Critical Infrastructure
Varsha Sewlal- Cyber Attacks on Critical Critical InfrastructureVarsha Sewlal- Cyber Attacks on Critical Critical Infrastructure
Varsha Sewlal- Cyber Attacks on Critical Critical Infrastructure
 
MuleSoft Online Meetup Group - B2B Crash Course: Release SparkNotes
MuleSoft Online Meetup Group - B2B Crash Course: Release SparkNotesMuleSoft Online Meetup Group - B2B Crash Course: Release SparkNotes
MuleSoft Online Meetup Group - B2B Crash Course: Release SparkNotes
 
Potential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and InsightsPotential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and Insights
 
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyes
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyesHow to Effectively Monitor SD-WAN and SASE Environments with ThousandEyes
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyes
 
Assure Ecommerce and Retail Operations Uptime with ThousandEyes
Assure Ecommerce and Retail Operations Uptime with ThousandEyesAssure Ecommerce and Retail Operations Uptime with ThousandEyes
Assure Ecommerce and Retail Operations Uptime with ThousandEyes
 
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
 
Generative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdfGenerative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdf
 
So einfach geht modernes Roaming fuer Notes und Nomad.pdf
So einfach geht modernes Roaming fuer Notes und Nomad.pdfSo einfach geht modernes Roaming fuer Notes und Nomad.pdf
So einfach geht modernes Roaming fuer Notes und Nomad.pdf
 
Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024
 
Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...
Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...
Microsoft 365 Copilot: How to boost your productivity with AI – Part one: Ado...
 
JET Technology Labs White Paper for Virtualized Security and Encryption Techn...
JET Technology Labs White Paper for Virtualized Security and Encryption Techn...JET Technology Labs White Paper for Virtualized Security and Encryption Techn...
JET Technology Labs White Paper for Virtualized Security and Encryption Techn...
 
A Framework for Development in the AI Age
A Framework for Development in the AI AgeA Framework for Development in the AI Age
A Framework for Development in the AI Age
 
Bridging Between CAD & GIS: 6 Ways to Automate Your Data Integration
Bridging Between CAD & GIS:  6 Ways to Automate Your Data IntegrationBridging Between CAD & GIS:  6 Ways to Automate Your Data Integration
Bridging Between CAD & GIS: 6 Ways to Automate Your Data Integration
 

Geohash

  • 2. What's the plan today? What is geohash? Why do we need it? geohash.org How does it work? Grouping and Zooming Nearby (proximity) searches The Edge case Limitations Demo (Let's see it working)
  • 3. Who am I? Co-Founded Ideophone with @oligoglot & @anenth helped building @pyka, @suruk, @onetouchsos, @kopa_app product architecture, platform development x-SunTec, x-TAT, mtech from IIIT-B
  • 4. What is geohash? Simple way to encode lat/long into a string Compact string encoding of geographic coordinate with arbitrary precision Bangalore - TDR1, Domlur - TDR1WX Invented by Gustavo Niemeyer for geohash.org Available in public domain http://en.wikipedia.org/wiki/geohash/
  • 5. Why do we need it when we have LL? Big address of this venue Complicated Lat/Long {12.963787,77.637789} The Mail from Cartonama could've said Venue: "tdr1wxyp5dn7v"
  • 6. ● Subdivides space into "buckets" of grid shape ● Doesn't really represent a point, rather a bounding area in which the point is present ● Hierarchical spatial structure with gradual degradation ● Longer the geohash -> Smaller the area Demo
  • 7. How does it work? 11001 01100 10111 00001 11100 11101 11110 10101 00101 01100 10100 00111 11011 t d r 1 w x y p 5 d n 7 v !
  • 8. geohash.org Short URL uniquely identifying points on earth Referencing them on emails, website etc becomes far more convenient Bangalore: http://geohash.org/tdr1 Domlur: http://geohash. org/tdr1wx
  • 9. Grouping and Zooming Easy grouping ○ tdr1wxyp5dn7v -> {12.9637069, 77.6377931} ● 4th Main Rd, Domlur II Stage, Domlur, Bengaluru, Karnataka ○ tdr1wxyp5dn7v -> {12.9637, 77.6378} ● Domlur, Bengaluru, Karnataka ○ tdr1wxyp5dn7v -> {12.96, 77.64} ● Bengaluru, Karnataka ○ tdr1wxyp5dn7v -> {13, 78} ● Malur-Bangarapettu Rd
  • 10. Nearby (Proximity) Search ● Nearby locations usually share similar prefixes. ● Long common prefixes indicate two places are near, however two nearby places do not always have common prefixes There is an Edge Case: E.g. Two nearby places in Boston DRT.. DRM..
  • 11. Nearby Search tdr1wxyp5dn7v (TERI) tdr1wxyqekmg (Bangalore I'ntl Chapter) tdr1y8jbvrmc (Domlur Club) tdr1y8jykh6w (CIS) tdr1ybmhdj4p (Ideophone) tdr1v4e3mecx (Majestic Station) tf346wn2t49t (Chennai Central) 9q8vzpgn7we0 (SFO Airport)
  • 12. Finding Nearby Places Python, Perl, PHP, Java etc python-geohash ○ Encode/Decode ○ BoundingBox {'s': 12.919921875, 'e': 77.6513671875, 'w': 77.607421875, 'n': 12.9638671875} ○ Neighbours ['ezefx','ezefr','ezefp','ezs40', 'ezs41','ezs43','ezs49','ezs48']
  • 13. Finding Nearby Places ● Proximity Search ○ Bottoms-Up ● Bounding Box Search ○ Hops to neighbors until POI is found
  • 14. Finding Nearby Places ● Compute geohash values for all Lat/Long ● Have index on geohash for quicker retrievals
  • 15. Finding Nearby Places ● Prefix Match: SELECT * FROM table WHERE place_geohash LIKE hashcode% ● Expand/Neighbors Match SELECT * FROM table WHERE place_geohash IN (geohash.expand('tzxy1'))
  • 16. Limitations ● Locality Anomalies ○ Complicates Proximity Searches ○ Need to use bounding box extensively making search an expensive operation ● Projection based model ○ A geohash of given length will denote different region size in poles than in equator region
  • 18. Conclusions ● Simple and effective system to map complex lat-long coordinates into simple string representations ● Useful in applications where "nearness" of POIs is more relevant than accurate distance computation ● Enables quick db access using LIKE using grouping of prefixes of geohashes