Juliacon 2024

GeometryOps.jl: Building a Comprehensive Native Geometry Package
07-12, 10:10–10:20 (Europe/Amsterdam), While Loop (4.2)

There is no native Julia geometry package equivalent to Python’s Shapely or R’s sf. The driving idea behind GeometryOps.jl is to unify existing native geometry packages, develop functionalities that only exist in non-native wrapper packages, and make algorithms usable with various geometric representations through GeoInterface.jl. Initial benchmarks show speedups over widely used wrapper library LibGEOS.jl: 2x for polygon area, 7x for polygon intersection, and 10x for point-to-polygon distance.


Julia’s Geo and Geometry ecosystems lack a comprehensive, native package for standard geometric algorithms for spatial data. The most comprehensive option is LibGEOS.jl, the Julia wrapper of C library GEOS. However, use of LibGEOS.jl comes with performance drawbacks when calling C functions and creating C objects.

On the other hand, the native Julia ecosystem is made up of a collection of disparate packages, many focusing on implementing specific geometric algorithms to solve targeted questions rather than general functionality. Additionally, there are numerous Julia representations of common geometries, with many of the native algorithms only working with specific representations.

To address these problems, we have created GeometryOps.jl, which seeks to unify the disparate packages and algorithms for geometric calculations in Julia and make them GeoInterface.jl-compatible.

In time, this package could come to replace LibGEOS.jl. For implemented algorithms, GeometryOps.jl already provides substantial performance improvements over LibGEOS.jl when using native geometry objects.

See also: Slides (3.0 MB)

Rafael is an Ecologist at the Center for Macroecology, Climate and Evolution in Copenhagen. He works on process-based ecological models of species distributions, dispersal, threats and extinction, and contributes to a variety of geospatial, modelling and visualization packages.

https://github.com/rafaqz

This speaker also appears in:

Julia developer in data visualization and geospatial.