dask-contrib / dask-sql

Distributed SQL Engine in Python using Dask
https://dask-sql.readthedocs.io/
MIT License
386 stars 71 forks source link

Spatial SQL Support #1307

Open alxmrs opened 7 months ago

alxmrs commented 7 months ago

Is your feature request related to a problem? Please describe. I have a few geospatial datasets and am using geopandas-dask with them. They include geometry and other spatial types (see discussion in #7). I would like to use SQL syntax to express a left outer join between these two datasets, similar to how I would write a PostGIS query. I’m addition to types, I’d like to use geospatial operations, like intersection.

E.g.: the toy example in this documentation. https://geopandas.org/en/stable/gallery/spatial_joins.html

I wish I could trade out a PostGIS Query for one in Dask-SQL.

Describe the solution you'd like When both dask-sql and geopandas-dask are installed, users can use all of Apache Calcite’s Spatial features.

https://calcite.apache.org/docs/spatial.html

dask-sql would allow this SQL syntax and would translate operations to geopandas-dask ops.

Describe alternatives you've considered I can call the geopandas-dask functions directly. But, I’m trying to serve users who only know SQL.

Additional context I thing I can replace using Google Earth Engine with Dask via integrations like these.

beckermr commented 4 months ago

See also this one: https://github.com/dask-contrib/dask-sql/issues/138

A lot of the geospatial items can be used with astronomical datasets as well I am betting!