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

[SEDONA-639] Fix GeometrySplitter accuracy issues when splitting LineStrings #1542

Merged
merged 1 commit into from
Aug 7, 2024

Conversation

Kontinuation
Copy link
Member

Did you read the Contributor Guide?

Is this PR related to a JIRA ticket?

What changes were proposed in this PR?

The algorithm we used before computes the intersection points of the input and the blade and splits the input using the intersection points. The problem is that the intersection point may not perfectly lie on the input LineString due to precision issues of the overlay algorithm, so the input LineString won't be split correctly.

This PR uses a more robust algorithm for splitting LineStrings using LineString blades. It simply computes the difference between the input and blade geometry to derive the split result.

How was this patch tested?

Pass existing tests and a newly added test.

Did this PR include necessary documentation updates?

  • No, this PR does not affect any public API so no need to change the documentation.

@Kontinuation Kontinuation marked this pull request as ready for review August 7, 2024 03:31
@jiayuasu jiayuasu added the bug label Aug 7, 2024
@jiayuasu jiayuasu added this to the sedona-1.6.1 milestone Aug 7, 2024
@jiayuasu jiayuasu merged commit 2407c51 into apache:master Aug 7, 2024
51 checks passed
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants