[geos-devel] [GEOS] #343: After applying a buffer over a multiline
the library starts growing in memory usage and hungs
Martin Davis
mbdavis at refractions.net
Thu May 13 12:22:49 EDT 2010
Just tried the buffer-and-union approach in JTS. It works fine - about
70 s for the union, less for the initial buffering. Memory usage was low.
This geometry is pretty much a poster child for things that defeat the
optimizations used in buffering. It has lots of small geometries, thus
preventing simplification. And the buffer size chosen is large relative
to the geometry size, thus creating lots of overlaps.
At the moment I haven't spent much time thinking about how to detect
these cases automatically. Of course it would be possible to switch to
using an automated buffer-and-union approach if this could be detected.
But this seems like such a pathological case I'm not sure it's worth
penalizing all other buffer users just to handle it.
In any case, it would be worth providing a buffer-and-union algorithm as
a builtin class. This could be further optimized by using the same
approach as CascadedPolygonUnion to produce a CascadedBuffer class.
This would reduce the amount of intermediate memory required (but would
not provide any direct performance advantage.)
M
Martin Davis wrote:
> Yikes! That's one nasty dataset. JTS has issues with it as well - I
> wasn't able to get the buffer to complete.
>
> As a workaround, you could buffer each line separately and then
> UnaryUnion the results.
> GEOS wrote:
>> #343: After applying a buffer over a multiline the library starts
>> growing in
>> memory usage and hungs
>> ------------------------+---------------------------------------------------
>>
>> Reporter: sberna | Owner: geos-devel at lists.osgeo.org
>> Type: defect | Status: new
>> Priority: major | Milestone:
>> Component: Default | Version: 3.2.0
>> Severity: Unassigned | Keywords:
>> ------------------------+---------------------------------------------------
>>
>> After applying a buffer of 0.005 to the attached geometry in hex wkb
>> the
>> library starts growing in memory usage until the kernel kills it. It
>> never
>> returns the buffered geometry nor any error message.
>>
>>
>> ------------------------------------------------------------------------
>>
>> _______________________________________________
>> geos-devel mailing list
>> geos-devel at lists.osgeo.org
>> http://lists.osgeo.org/mailman/listinfo/geos-devel
>
--
Martin Davis
Senior Technical Architect
Refractions Research, Inc.
(250) 383-3022
More information about the geos-devel
mailing list