Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ENH: Add support for mask parameter #285

Merged
merged 14 commits into from
Sep 29, 2023
Merged

ENH: Add support for mask parameter #285

merged 14 commits into from
Sep 29, 2023

Conversation

brendan-ward
Copy link
Member

Resolves #277

Adds mask parameter to read, read_dataframe, open_arrow, and read_bounds.

This takes an easier path to supporting geometries than Fiona (which supports GeoJSON-like inputs). This requires Shapely Geometry objects, and internally converts them to WKB to create the geometry within GDAL.

I have not finished checking compatibility with other parameters, like where or sql.

I am currently seeing inconsistent behavior when using Arrow, where it will return more results than expected for GPKG.

@brendan-ward
Copy link
Member Author

GDAL Arrow bug logged at: OSGeo/gdal#8347

This affects both bbox and mask filters when using Arrow for both GPKG and FlatGeobuf.

@normanb
Copy link

normanb commented Sep 10, 2023

@brendan-ward there has been quite a few commits to GDAL master regarding Arrow filtering. I have been using pyogrio with TileDB in GDAL (which supports arrow) and I am 👍 on adding mask support.

Copy link
Member

@jorisvandenbossche jorisvandenbossche left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good!

docs/source/introduction.md Outdated Show resolved Hide resolved
docs/source/introduction.md Outdated Show resolved Hide resolved
@brendan-ward brendan-ward marked this pull request as ready for review September 26, 2023 19:36
pyogrio/geopandas.py Outdated Show resolved Hide resolved
pyogrio/raw.py Outdated Show resolved Hide resolved
@brendan-ward brendan-ward added this to the 0.7.0 milestone Sep 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

ENH: support mask keyword for compatibility with Fiona
4 participants