apache / sedona

A cluster computing framework for processing large-scale geospatial data
https://sedona.apache.org/
Apache License 2.0
1.96k stars 692 forks source link

[SEDONA-672] Bug fix for ST_LengthSpheroid #1679

Closed furqaankhan closed 2 weeks ago

furqaankhan commented 2 weeks ago

Did you read the Contributor Guide?

Is this PR related to a JIRA ticket?

What changes were proposed in this PR?

ST_LengthSpheroid didn't consider Polygons with holes (interior rings). This bug fix addresses that issue. Eg:

WKT:


POLYGON((-122.33 47.61, -122.32 47.62, -122.31 47.61, -122.30 47.62, -122.29 47.61, -122.30 47.60, -122.31 47.59, -122.32 47.60, -122.33 47.61), (-122.315 47.605, -122.305 47.615, -122.295 47.605, -122.305 47.595, -122.315 47.605))

old output:                   17363.913692009628

output after changes: 16106.506409488933

How was this patch tested?

Did this PR include necessary documentation updates?