[geos-devel] RE: [GEOS] #468: Geometry breaks valid() and
buffer(): "Assertion failed: (0), function query, file
AbstractSTRtree.cpp, line 286"
Sandro Santilli
strk at keybit.net
Wed Aug 24 10:46:04 EDT 2011
I guess GeoDjango is using the C++ API ?
Ahi ahi ahi ...
(yes, it changed, see NEWS file)
--strk;
On Mon, Aug 22, 2011 at 11:58:44AM -0700, Christopher DeMars wrote:
> I'm thinking that there must be some sort of conflict between the GEOS
> and geodjango. Has the API changed significantly lately?
>
> After installing the latest SVN release (3.4.0dev-CAPI-1.8.0), things
> got worse, not better. Now no geometry will buffer, even super simple
> example geometries from wikipedia's wkt entry.
>
> Using two geometries from my dataset (attached as wkt), I ran through
> the geodjango geos api.
>
> Operations that seemed to work:
> .empty
> .geom_type
> .num_coords
> .num_geom
> .hasz
> .ring
> .simple
> .srid
> .json
> .ewkt
> .hex
> .hexewkb
> .geojson
> .ogr
> .ewkb
> .wkb
> .contains(w2)
> .crosses(w2)
> .disjoint(w2)
> .equals(w2)
> .equals_exact(w2)
> .intersects(w2)
> .overlaps(w2)
> .touches(w2)
> .within(w2)
> .relate(w2)
> .boundary
> .centroid
> .convex_hull
> .envelope
> .area
> .clone
> .length
> .prepared
> .srs
>
>
> Worked, but returned a bogus answer
> In [17]: w1.distance(w2)
> Out[17]: 1.7976931348623157e+308
>
>
> Type errors:
> .kml
> GEOS_ERROR: Argument is not a Polygon
> GEOS_ERROR: Argument is not a Polygon
> w1.difference(w2)
> GEOS_ERROR: UnsupportedOperationException: GeometryGraph::add(Geometry
> *): unknown geometry type: N4geos4geom12MultiPolygonE
> w1.intersection(w2)
> GEOS_ERROR: UnsupportedOperationException: GeometryGraph::add(Geometry
> *): unknown geometry type: N4geos4geom12MultiPolygonE
> w1.sym_difference(w2)
> GEOS_ERROR: UnsupportedOperationException: GeometryGraph::add(Geometry
> *): unknown geometry type: N4geos4geom12MultiPolygonE
> w1.union(w2)
> GEOS_ERROR: UnsupportedOperationException: GeometryGraph::add(Geometry
> *): unknown geometry type: N4geos4geom12MultiPolygonE
> w1.point_on_surface
> GEOS_ERROR: UnsupportedOperationException: GeometryGraph::add(Geometry
> *): unknown geometry type: N4geos4geom10LineStringE
> GEOS_ERROR: UnsupportedOperationException: GeometryGraph::add(Geometry
> *): unknown geometry type: N4geos4geom10LineStringE
> w1.extent
> GEOS_ERROR: Geometry must be a Point or LineString
> GEOS_ERROR: Geometry must be a Point or LineString
> w1.coords
> GEOS_ERROR: Argument is not a Polygon
> GEOS_ERROR: Argument is not a Polygon
>
>
> Segfault:
> w1.simplify()
> Segmentation fault
> w1.valid
> Segmentation fault
> w1.valid_reason
> Segmentation fault
> w1.buffer(20)
> Segmentation fault
>
>
> I guess I'll go bitch at the GeoDjango folks for a while until I can
> get an exact reason why things are going fubar when translating from
> django to geos.
>
> Thanks for your time,
> --Christopher
> _______________________________________________
> geos-devel mailing list
> geos-devel at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/geos-devel
--
() Free GIS & Flash consultant/developer
/\ http://strk.keybit.net/services.html
More information about the geos-devel
mailing list