Skip to main content
Log in

Efficient spatial queries over complex polygons with hybrid representations

  • Research
  • Published:
GeoInformatica Aims and scope Submit manuscript

Abstract

One major goal of spatial query processing is to mitigate I/O costs and minimize the search space. However, geometric computation can be heavy-duty for spatial queries, in particular for complex geometries such as polygons with many edges based on a vector-based representation. Many past techniques have been provided for spatial partitioning and indexing, which are mainly built on minimal bounding boxes or other approximation methods and are not optimized for reducing geometric computation. In this paper, we propose a novel vector-raster hybrid approach through rasterization, where rich pixel-centric information is preserved to help not only filter out more candidates but also reduce geometry computation load. Based on the hybrid model, we implement four typical spatial queries, which can be generalized for other types of spatial queries. We also propose cost models to estimate the latency for those query types. Our experiments demonstrate that the hybrid model can boost the performance of spatial queries on complex polygons by up to one order of magnitude.

This is a preview of subscription content, log in via an institution to check access.

Access this article

Price excludes VAT (USA)
Tax calculation will be finalised during checkout.

Instant access to the full article PDF.

Fig. 1
Fig. 2
Algorithm 1
Fig. 3
Algorithm 2
Fig. 4
Algorithm 3
Algorithm 4
Fig. 5
Fig. 6
Algorithm 5
Algorithm 6
Fig. 7
Fig. 8
Fig. 9
Fig. 10
Fig. 11
Fig. 12
Fig. 13
Fig. 14
Fig. 15
Fig. 16
Fig. 17
Fig. 18
Fig. 19

Similar content being viewed by others

Availability of data and materials

The Open Street Map dataset we used is open to public and can be downloaded from here [4].

References

  1. HDMAP (2023) HDMAP. https://www.here.com/platform/automotive-services/hd-maps. Accessed Oct 2023

  2. Campbell JB, Wynne RH (2011) Introduction to remote sensing

  3. Kamilaris A, Ostermann FO (2018) Geospatial analysis and the internet of things. ISPRS Int J Geo-Inf 7(7):269

    Article  Google Scholar 

  4. Map OS (2023) Open Street Map. https://www.openstreetmap.org/. Accessed Oct 2023

  5. YELP (2023) YELP. https://www.yelp.com/. Accessed Oct 2023

  6. FOURSQURE (2023) FOURSQURE. https://foursquare.com/. Accessed Oct 2023

  7. DIDI (2023) DIDI. https://www.didiglobal.com/. Accessed Oct 2023

  8. Uber (2023) Uber. https://www.uber.com/. Accessed Oct 2023

  9. Department of Environmental Conservation N (2023) Environmental investigation and cleanup activities at the former U.S. Navy and Northrop Grumman Bethpage facility sites. https://www.dec.ny.gov/chemical/35727.html. Accessed Oct 2023

  10. Worboys M, Duckham M (2004) GIS: a computing perspective, 2nd edn. CRC Press Inc, USA

    Book  Google Scholar 

  11. Marschner S, Shirley P (2016) Fundamentals of computer graphics, fourth edition, 4th edn. A. K, Peters Ltd, USA

    Google Scholar 

  12. Samet H (2006) Foundations of multidimensional and metric data structures

  13. Cheung KL, Fu AW-C (1998) Enhanced nearest neighbour search on the r-tree. ACM SIGMOD Record 27(3):16–21

    Article  MathSciNet  Google Scholar 

  14. Kamel I, Faloutsos C (1993) Hilbert r-tree: an improved r-tree using fractals. In: Proceedings of the international conference on very large databases, pp 500–509

  15. Beckmann N, Kriegel H-P, Schneider R, Seeger B (1990) The r*-tree: an efficient and robust access method for points and rectangles. In: Proceedings of the 1990 ACM SIGMOD international conference on management of data, pp 322–331

  16. Guttman A (1984) R-trees: a dynamic index structure for spatial searching. In: Proceedings of the 1984 ACM SIGMOD international conference on management of data, pp 47–57

  17. Brinkhoff T, Kriegel H-P, Seeger B (1993) Efficient processing of spatial joins using r-trees. ACM SIGMOD Record 22(2):237–246

    Article  Google Scholar 

  18. Samet H (1984) The quadtree and related hierarchical data structures. ACM Comput Surv (CSUR) 16(2):187–260

    Article  MathSciNet  Google Scholar 

  19. Brinkhoff T, Kriegel H-P, Schneider R, Seeger B (1994) Multi-step processing of spatial joins. Acm Sigmod Record 23(2):197–208

    Article  Google Scholar 

  20. Fang Y, Friedman M, Nair G, Rys M, Schmid A-E (2008) Spatial indexing in microsoft sql server 2008. In: Proceedings of the 2008 ACM SIGMOD international conference on management of data, pp 1207–1216

  21. Microsoft (2023) SQL Server. https://www.microsoft.com/en-us/sql-server. Accessed Oct 2023

  22. IBM (2023) Spatial Extender User’s Guide and Reference. ftp://public.dhe.ibm.com/ps/products/db2/info/vr105/pdf/en_US/DB2Spatial-db2sbe1050.pdf. Accessed Oct 2023

  23. Zacharatou ET, Doraiswamy H, Ailamaki A, Silva CT, Freiref J (2017) Gpu rasterization for real-time spatial aggregation over arbitrary polygons. Proc VLDB Endowment 11(3):352–365

    Article  Google Scholar 

  24. Wang K, Huai Y, Lee R,Wang F, Zhang X, Saltz JH (2012) Accelerating pathology image data cross-comparison on cpu-gpu hybrid systems. In: Proceedings of the VLDB endowment international conference on very large data bases, vol 5, p 1543. NIH Public Access

  25. Aji A, Wang F, Vo H, Lee R, Liu Q, Zhang X, Saltz J (2013) Hadoop gis: a high performance spatial data warehousing system over map reduce. Proc VLDB Endowment 6(11):1009–1020

    Article  Google Scholar 

  26. Domiter V, Žalik B (2008) Sweep-line algorithm for constrained delaunay triangulation. Int J Geogr Inf Sci 22(4):449–462

    Article  Google Scholar 

  27. Teng D, Baig F, Sun Q, Kong J, Wang F (2021) Ideal: a vector-raster hybrid model for efficient spatial queries over complex polygons. In: 2021 22nd IEEE international conference on mobile data management (MDM). IEEE, pp 99–108

  28. Eldawy A, Mokbel MF (2015) Spatialhadoop: a mapreduce framework for spatial data. In: 2015 IEEE 31st international conference on data engineering. IEEE, pp 1352–1363

  29. Baig F, Vo H, Kurc T, Saltz J, Wang F (2017) Sparkgis: resource aware efficient in-memory spatial query processing. In: Proceedings of the 25th ACM SIGSPATIAL international conference on advances in geographic information systems. ACM, p 28

  30. Yu J, Zhang Z, Sarwat M (2019) Spatial data management in apache spark: the geospark perspective and beyond. Geoinformatica 23(1):37–78

    Article  Google Scholar 

  31. Xie D, Li F, Yao B, Li G, Zhou L, Guo M (2016) Simba: efficient in-memory spatial analytics. In: Proceedings of the 2016 international conference on management of data, pp 1071–1085

  32. Brinkhoff T, Kriegel H-P, Schneider R (1993) Comparison of approximations of complex objects used for approximation-based query processing in spatial database systems. In: Proceedings of IEEE 9th international conference on data engineering. IEEE, pp 40–49

  33. Sidlauskas D, Chester S, Zacharatou ET, Ailamaki A (2018) Improving spatial data processing by clipping minimum bounding boxes. In: 2018 IEEE 34th international conference on data engineering (ICDE). IEEE, pp 425–436

  34. Liang Y, Vo H, Kong J, Wang F (2017) ispeed: an efficient in-memory based spatial query system for large-scale 3d data with complex structures. In: Proceedings of the 25th ACM SIGSPATIAL international conference on advances in geographic information systems. ACM, p 17

  35. Liu Y, Puri S (2020) Efficient filters for geometric intersection computations using gpu. In: Proceedings of the 28th international conference on advances in geographic information systems, pp 487–496

  36. Aghajarian D, Puri S, Prasad S (2016) Gcmf: an efficient end-to-end spatial join system over large polygonal datasets on gpgpu platform. In: Proceedings of the 24th ACM SIGSPATIAL international conference on advances in geographic information systems, pp 1–10

  37. Liu Y, Yang J, Puri S (2019) Hierarchical filter and refinement system over large polygonal datasets on cpu-gpu. In: 2019 IEEE 26th international conference on high performance computing, data, and analytics (HiPC). IEEE, pp 141–151

  38. Wang Y, Chen Z, Cheng L, Li M, Wang J (2013) Parallel scanline algorithm for rapid rasterization of vector geographic data. Comput Geosci 59:31–40

    Article  Google Scholar 

  39. Zhang J (2011) Speeding up large-scale geospatial polygon rasterization on gpgpus. In: Proceedings of the ACM SIGSPATIAL second international workshop on high performance and distributed geographic information systems, pp 10–17

  40. McCool MD, Wales C, Moule K (2001) Incremental and hierarchical hilbert order edge equation polygon rasterizatione. In: Proceedings of the ACM SIGGRAPH/EUROGRAPHICS workshop on graphics hardware, pp 65–72

  41. Silva-Coira F, Paramá JR, Ladra S, López JR, Gutiérrez G (2020) Efficient processing of raster and vector data. Plos one 15(1):0226943

    Article  Google Scholar 

  42. Singla S, Eldawy A (2018) Distributed zonal statistics of big raster and vector data. In: Proceedings of the 26th ACM SIGSPATIAL international conference on advances in geographic information systems, pp 536–539

  43. Gutiérrez G, Ladra S, López JR, Paramá JR, Silva-Coira F (2018) Efficient processing of top-k vector-raster queries over compressed data. In: 2018 data compression conference. IEEE, pp 410–410

  44. Abdalla M, Mokhtar HM, Noureldin M (2013) A unified approach for spatial data query. Int J Data Min Knowl Manag Process 3(6):55

    Article  Google Scholar 

  45. Singla S, Eldawy A, Diao T, Mukhopadhyay A, Scudiero E (2021) The raptor join operator for processing big raster+ vector data. In: Proceedings of the 29th international conference on advances in geographic information systems, pp 324–335

  46. Zimbrao G, De Souza JM (1998) A raster approximation for processing of spatial joins. VLDB 98:24–27

    Google Scholar 

  47. Azevedo LG, Zimbrao G, De Souza JM (2007) Approximate query processing in spatial databases using raster signatures, pp 69–86

  48. Kipf CWA, Anneser C, Zacharatou ET, Kemper TNA (2021) Geoblocks: a query-cache accelerated data structure for spatial aggregation over polygons

  49. RaulAlexandruPersa AHV, Zacharatou CAET, Doraiswamy H, Boncz P, Kemper TNA (2020) Adaptive main-memory indexing for high-performance point-polygon joins

  50. Doraiswamy H, Freire J (2020) A gpu-friendly geometric data model and algebra for spatial queries. In: Proceedings of the 2020 ACM SIGMOD international conference on management of data, pp 1875–1885

  51. Liang Y, Wang F, Zhang P, Saltz JH, Brat DJ, Kong J (2017) Development of a framework for large scale three-dimensional pathology and biomarker imaging and spatial analytics. AMIA Summits Trans Sci Proc 2017:75

    Google Scholar 

  52. Haines E (1994) Point in polygon strategies. Graphics Gems IV 994:24–26

    Article  Google Scholar 

  53. Hormann K, Agathos A (2001) The point in polygon problem for arbitrary polygons. Comput Geom 20(3):131–144

    Article  MathSciNet  Google Scholar 

  54. Huang C-W, Shih T-Y (1997) On the complexity of point-in-polygon algorithms. Comput Geosci 23(1):109–118

    Article  Google Scholar 

  55. Chazelle B (1981) The polygon containment problem

  56. Clementini E, Sharma J, Egenhofer MJ (1994) Modelling topological spatial relations: strategies for query processing. Comput Graph 18(6):815–822

    Article  Google Scholar 

  57. Mouratidis K, Papadias D, Hadjieleftheriou M (2005) Conceptual partitioning: an efficient method for continuous nearest neighbor monitoring. In: Proceedings of the 2005 ACM SIGMOD international conference on management of data, pp 634–645

  58. GEOS contributors (2023) GEOS coordinate transformation software library. Open Source Geospatial Foundation. https://libgeos.org/

  59. Postgres (2023) PostGIS. https://postgis.net/. Accessed Oct 2023

  60. Yu J, Wu J, Sarwat M (2015) Geospark: a cluster computing framework for processing large-scale spatial data. In: Proceedings of the 23rd SIGSPATIAL international conference on advances in geographic information systems, pp 1–4

  61. Vo H, Aji A, Wang F (2014) Sato: a spatial data partitioning framework for scalable query processing. In: Proceedings of the 22nd ACM IGSPATIAL international conference on advances in geographic information systems, pp 545–548

  62. WikiPedia (2023) Landlocked Country. https://en.wikipedia.org/wiki/Landlocked_country. Accessed Oct 2023

Download references

Funding

This research is supported in part by grants from National Science Foundation ACI 1443054 and IIS 1541063, National Institute of Health U01CA242936, and National Natural Science Foundation of China (No.62072282).

Author information

Authors and Affiliations

Authors

Contributions

Dejun Teng proposed the main idea of this work and wrote the main manuscript text. Furqan Baig helped formalize the technical details of the implementations. Furqan Baig, Jun Kong, and Fusheng Wang helped improve the paper writing. Zhaohui Peng helped formalize the equations for the cost models and gave significant suggestions on the implementations of polygon-pair evaluations. All authors reviewed the manuscript.

Corresponding author

Correspondence to Zhaohui Peng.

Ethics declarations

Competing interests

The authors have no competing interests as defined by Springer.

Additional information

Publisher's Note

Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Rights and permissions

Springer Nature or its licensor (e.g. a society or other partner) holds exclusive rights to this article under a publishing agreement with the author(s) or other rightsholder(s); author self-archiving of the accepted manuscript version of this article is solely governed by the terms of such publishing agreement and applicable law.

Reprints and permissions

About this article

Check for updates. Verify currency and authenticity via CrossMark

Cite this article

Teng, D., Baig, F., Peng, Z. et al. Efficient spatial queries over complex polygons with hybrid representations. Geoinformatica (2023). https://doi.org/10.1007/s10707-023-00508-2

Download citation

  • Received:

  • Revised:

  • Accepted:

  • Published:

  • DOI: https://doi.org/10.1007/s10707-023-00508-2

Keywords

Navigation