Skip to content

bug: GridIntersect improvements #2344

@dbrakenhoff

Description

@dbrakenhoff

Some things I'd like to fix in gridintersect.py:

  • When intersecting linestrings with GridIntersect in structured mode, and those intersections result in GeometryCollections, there are overlapping results in the intersection output. This was originally reported in bug: typo shapely function call within gridintersect #2342 (for "vertex" mode, which was fixed in fix(gridintersect): typo shapely function call within gridintersect #2342 #2343).
  • Return intersection result as GeoDataFrame (instead of np.recarray) if geopandas is available.
  • Remove shapely<2.0 code. It's been released for a while now so perhaps we can get rid of some old code?
  • Deprecate method="structured" mode? This is somewhat complex to maintain, and performs worse than "vertex" mode in almost all cases, especially since Shapely 2.0 was released. This has the added advantage of "solving" the first issue in this list.

I'm curious to hear your thoughts about these suggestions, so let me know what you think, and I can put together a PR!

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions