<div dir="ltr"><div>Hi Brendan,</div><div><br></div><div>I don't remember it being discussed anywhere, but it's certainly been floating around in my head for a while. I think it's very much worth pursuing.<br></div><div><br></div><div>Dan<br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Fri, Nov 13, 2020 at 11:41 AM Brendan Ward <<a href="mailto:bcward@astutespruce.com">bcward@astutespruce.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div>I would like to expose functionality similar to ST_Subdivide (<a href="https://postgis.net/docs/ST_Subdivide.html" target="_blank">https://postgis.net/docs/ST_Subdivide.html</a>) in pygeos (ref: <a href="https://github.com/pygeos/pygeos/issues/244" target="_blank">https://github.com/pygeos/pygeos/issues/244</a>), which provides a Python interface to GEOS.</div><div><br></div><div>The algorithm recursively subdivides input geometries along alternating x vs y dimensions until a target number of vertices per geometry is reached, which can greatly improve spatial index performance for complex polygons (e.g., countries with coastlines).  Paul has written a very nice overview of it here: <a href="http://blog.cleverelephant.ca/2019/11/subdivide.html" target="_blank">http://blog.cleverelephant.ca/2019/11/subdivide.html</a></div><div><br></div><div>Apologies if this has already been raised here; I was unable to find any record of such a discussion in Github, Trac, mailing list archives.</div><div><br></div><div>I did not find a counterpart in JTS, so perhaps this is out of scope for GEOS?<br></div><div><br></div><div>While we can take this on in a downstream library (and indeed may want to pilot there first), this seems like it would have broader appeal to the GEOS community if exposed via the C API.  There may also be potential performance improvements to leveraging aspects of something like STRtree to help identify x or y subdivision points (ideas not yet well developed though).</div><div><br></div><div>Is there any interest in providing something similar within GEOS?  If so, perhaps the next stage is to log this as a feature request to Trac.  I anticipated the need for a little discussion around this topic, so I'm raising here first.</div><br clear="all"><div>Thanks,</div><div><br></div><div>BCW</div><div><br></div>-- <br><div dir="ltr"><div dir="ltr"><div><div dir="ltr"><div><div dir="ltr"><font size="4">Brendan C. Ward</font><div><font color="#666666">Owner | Lead Software Engineer</font><br><div>Astute Spruce, LLC</div></div><div><a href="https://astutespruce.com/" target="_blank">astutespruce.com</a><br></div><div>541-250-9544</div></div></div></div></div></div></div></div>
_______________________________________________<br>
geos-devel mailing list<br>
<a href="mailto:geos-devel@lists.osgeo.org" target="_blank">geos-devel@lists.osgeo.org</a><br>
<a href="https://lists.osgeo.org/mailman/listinfo/geos-devel" rel="noreferrer" target="_blank">https://lists.osgeo.org/mailman/listinfo/geos-devel</a></blockquote></div>