[postgis-devel] CascadedUnion Early Results

Paul Ramsey pramsey at cleverelephant.ca
Tue Jan 20 15:10:43 PST 2009


This test case is taking a *very* long time for the standard function.
No answer yet :)

P

On Tue, Jan 20, 2009 at 2:29 PM, Kevin Neufeld <kneufeld at refractions.net> wrote:
> Yup, already forwarded it to you.
>
> Yes, it looks much better.  It obviously depends greatly on the dataset
> being used ... just how much the dataset overlaps.
>
> Paul, out of curiosity, how does this method compare when trying to use a
> set of completely disjoint polygons?  Since there is nothing to gain by
> using a cascaded methodology in such a case, is there an overhead to using
> the function?
>
> Cheers,
> Kevin
>
> Obe, Regina wrote:
>>
>> Ah okay that looks good.  I think the numbers look like about what I got
>> on JTS.
>>
>> I have to dig up that set Kevin had given me way back when.  Kevin you
>> don't still happen to have that do you?  I think it was named
>> sample_poly.zip
>>
>>
>>
>> -----Original Message-----
>> From: postgis-devel-bounces at postgis.refractions.net on behalf of Paul
>> Ramsey
>> Sent: Tue 1/20/2009 5:08 PM
>> To: PostGIS Development Discussion
>> Subject: Re: [postgis-devel] CascadedUnion Early Results
>>
>> Here's your test, slightly modified. Shows about 30-times improvement
>> over traditional union.
>>
>>  SELECT state,
>>   SUM(ST_NPoints(the_geom)) As  numpointsbefore,
>>     ST_NPoints(ST_Union(the_geom)) As numpointsafter
>>   FROM usstatebounds
>>   GROUP BY state
>>   ORDER BY state;
>>
>> Time: 579121.791 ms
>>
>>  SELECT state,
>>   SUM(ST_NPoints(the_geom)) As  numpointsbefore,
>>     ST_NPoints(ST_Union_Fast(the_geom)) As numpointsafter
>>   FROM usstatebounds
>>   GROUP BY state
>>   ORDER BY state;
>>
>> Time: 21145.717 ms
>>
>>
> _______________________________________________
> postgis-devel mailing list
> postgis-devel at postgis.refractions.net
> http://postgis.refractions.net/mailman/listinfo/postgis-devel
>



More information about the postgis-devel mailing list