Opened 6 years ago
Closed 5 years ago
#4335 closed defect (fixed)
ST_VoronoiPolygons chocking on some multipoint inputs (Self-intersection)
Reported by: | tilt | Owned by: | strk |
---|---|---|---|
Priority: | medium | Milestone: | PostGIS GEOS |
Component: | liblwgeom | Version: | 2.5.x -- EOL |
Keywords: | Cc: |
Description
On some multipoint configurations ST_VoronoiPolygons will complain about:
ERROR: GEOSVoronoiDiagram: TopologyException: Input geom 1 is invalid: Self-intersection at or near point 193600.95500000002 469345.18624999997 at 193600.95500000002 469345.18624999997
Observations:
- the multipoint is valid
- oddly this does not happen when calling ST_VoronoiLines
- Adding various tolerance values doesn't help.
- liblwgeom appears to construct a linestring from the points before feeding the geom to GEOS which may cause invalidity: https://github.com/postgis/postgis/blob/c72f563bd273e3d00ee5f6ab26a85354eb6988ca/liblwgeom/lwgeom_geos.c#L1840
- related issue at https://gis.stackexchange.com/questions/287053/postgis-st-voronoipolygons-gives-topologyexception-input-geom-1-is-invalid-se
Reproduce with:
SELECT ST_VoronoiPolygons(ST_GeomFromWKB( E'\\001\\354\\003\\000\\000\\027\\000\\000\\000\\001\\351\\003\\000\\000\\354Q\\270\\036\\021\\242\\007A\\354Q\\270\\036\\205\\245\\034A\\\\\\217\\302\\365(\\3345@\\001\\351\\003\\000\\000\\037\\205\\353Q\\024\\242\\007A\\\\\\217\\302\\365\\205\\245\\034A{\\024\\256G\\341\\2725@\\001\\351\\003\\000\\000\\205\\353Q\\270\\030\\242\\007A\\250\\306K7\\206\\245\\034A>\\012\\327\\243p\\2355@\\001\\351\\003\\000\\000\\000\\000\\000\\000\\033\\242\\007A\\376\\324x\\351\\204\\245\\034A>\\012\\327\\243p\\2355@\\001\\351\\003\\000\\000\\205\\353Q\\270\\030\\242\\007A\\376\\324x\\351\\204\\245\\034A>\\012\\327\\243p\\2355@\\001\\351\\003\\000\\000\\012\\327\\243p\\026\\242\\007A\\376\\324x\\351\\204\\245\\034A>\\012\\327\\243p\\2355@\\001\\351\\003\\000\\000\\000\\000\\000\\000\\033\\242\\007AT\\343\\245\\233\\203\\245\\034A>\\012\\327\\243p\\2355@\\001\\351\\003\\000\\000\\205\\353Q\\270\\030\\242\\007AT\\343\\245\\233\\203\\245\\034A>\\012\\327\\243p\\2355@\\001\\351\\003\\000\\000\\012\\327\\243p\\026\\242\\007AT\\343\\245\\233\\203\\245\\034A>\\012\\327\\243p\\2355@\\001\\351\\003\\000\\000\\000\\000\\000\\000\\033\\242\\007A\\252\\361\\322M\\202\\245\\034A>\\012\\327\\243p\\2355@\\001\\351\\003\\000\\000\\205\\353Q\\270\\030\\242\\007A\\252\\361\\322M\\202\\245\\034A>\\012\\327\\243p\\2355@\\001\\351\\003\\000\\000\\366(\\\\\\217\\022\\242\\007A\\354Q\\270\\036\\210\\245\\034AA`\\345\\320"\\3335@\\001\\351\\003\\000\\000""""\\020\\242\\007AR\\270\\036\\305\\206\\245\\034AA`\\345\\320"\\3335@\\001\\351\\003\\000\\000O\\033\\350\\264\\015\\242\\007AR\\270\\036\\305\\206\\245\\034AA`\\345\\320"\\3335@\\001\\351\\003\\000\\000{\\024\\256G\\013\\242\\007AR\\270\\036\\305\\206\\245\\034AA`\\345\\320"\\3335@\\001\\351\\003\\000\\000""""\\020\\242\\007A\\270\\036\\205k\\205\\245\\034AA`\\345\\320"\\3335@\\001\\351\\003\\000\\000O\\033\\350\\264\\015\\242\\007A\\270\\036\\205k\\205\\245\\034AA`\\345\\320"\\3335@\\001\\351\\003\\000\\000{\\024\\256G\\013\\242\\007A\\270\\036\\205k\\205\\245\\034AA`\\345\\320"\\3335@\\001\\351\\003\\000\\000\\247\\015t\\332\\010\\242\\007A\\270\\036\\205k\\205\\245\\034AA`\\345\\320"\\3335@\\001\\351\\003\\000\\000\\324\\006:m\\006\\242\\007A\\270\\036\\205k\\205\\245\\034AA`\\345\\320"\\3335@\\001\\351\\003\\000\\000{\\024\\256G\\013\\242\\007A\\037\\205\\353\\021\\204\\245\\034AA`\\345\\320"\\3335@\\001\\351\\003\\000\\000\\247\\015t\\332\\010\\242\\007A\\037\\205\\353\\021\\204\\245\\034AA`\\345\\320"\\3335@\\001\\351\\003\\000\\000\\324\\006:m\\006\\242\\007A\\037\\205\\353\\021\\204\\245\\034AA`\\345\\320"\\3335@' ))
Version: POSTGIS="2.5.0 r16836" [EXTENSION] PGSQL="100" GEOS="3.7.0-CAPI-1.11.0 673b9939" SFCGAL="1.3.5" PROJ="Rel. 5.2.0, September 15th, 2018" GDAL="GDAL 2.4.0dev-4b763dd896-dirty, released 2018/11/19" LIBXML="2.9.4" LIBJSON="0.12.1" LIBPROTOBUF="1.2.1" RASTER
Change History (4)
comment:1 by , 6 years ago
Milestone: | PostGIS 2.5.2 → PostGIS 2.5.3 |
---|
comment:2 by , 5 years ago
Milestone: | PostGIS 2.5.3 → PostGIS GEOS |
---|
comment:3 by , 5 years ago
Fix for this issue has been committed to JTS (#448). Should show up in GEOS and then PostGIS soon.
comment:4 by , 5 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
Ticket closed in GEOS. GEOS master should have it fixed, upgrade to that if there's urgent need or wait for release.
Roamed to GEOS: https://trac.osgeo.org/geos/ticket/976#ticket