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

support multiple polygons #381

Merged

Conversation

wybert
Copy link
Contributor

@wybert wybert commented Dec 19, 2024

This could resolve #379. Tested for mixed multi polygons

@wybert wybert requested a review from koettert December 19, 2024 23:08
knime_extension/src/nodes/spatialtool.py Show resolved Hide resolved
knime_extension/src/nodes/spatialtool.py Show resolved Hide resolved
knut.check_canceled(exec_context)
exec_context.set_progress(0.4, "Exploding input polygon...")
gdf_boundary = gdf_boundary.explode(index_parts=True)
gdf_boundary = gdf_boundary.reset_index(drop=True)
Copy link
Contributor

Choose a reason for hiding this comment

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

add replace=True to the reset_index call

@koettert koettert self-assigned this Jan 7, 2025
@koettert koettert force-pushed the 379-Create-H3-grid-node-fails-with-multiple-polygons-as-input branch 2 times, most recently from 79ec430 to 256b488 Compare January 7, 2025 16:46
@koettert koettert force-pushed the 379-Create-H3-grid-node-fails-with-multiple-polygons-as-input branch from 256b488 to 5d527c7 Compare January 7, 2025 18:25
@koettert koettert merged commit 40fca12 into main Jan 7, 2025
@koettert koettert deleted the 379-Create-H3-grid-node-fails-with-multiple-polygons-as-input branch January 7, 2025 18:27
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.

Create H3 grid node fails with multiple polygons as input
2 participants