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

Fix dedup merged linestrings #105

Merged
merged 4 commits into from
Aug 19, 2020
Merged

Fix dedup merged linestrings #105

merged 4 commits into from
Aug 19, 2020

Conversation

mattijn
Copy link
Owner

@mattijn mattijn commented Aug 19, 2020

This PR changes how non-shared arcs are merged, when possible.

Original codebase did not detect a single shared coordinate as junction and also start of geometries were not seen as a junction. This is changed in the last year and now this need some side solving of side effects.

The new approach detects which arcs were merged and set the merged linestring on the highest index of the arcs that are part of this merged linestring.

The remaining indici are collected and set to NaN, when bookkeeping for all other arcs are maintained. The implemented approach is very similar to the deduplication of duplicate linestrings.

A new test was added and all existing tests still pass.

Fix #104

@mattijn mattijn merged commit 9eabe8f into master Aug 19, 2020
@mattijn mattijn deleted the fix-dedup-merged-linestrings branch August 19, 2020 21:23
@mattijn mattijn mentioned this pull request Aug 22, 2020
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.

"TypeError: 'NoneType' object is not iterable" during polygon simplification
1 participant