Free advanced tools ... Convex Hulls...

2874
0
07-23-2019 04:35 PM
Labels (1)
DanPatterson_Retired
MVP Emeritus
4 0 2,874

 Free basic functionality.  

Another Free missive that uses numpy and arcpy to produce functionality that is normally restricted to the Standard or Advanced ArcGIS Pro license. 

Previously

 - Feature Extent to Poly Features

 - Free Tools : Frequency and Statistics

Help topics

 - Feature Envelope to Polygon

 - Frequency

 -  -Convex hull in Minimum bounding geometry

Spatial containers

The extent poly* features done previously, is one of the standard containers.  The convex hull is the most widely used and the easiest to implement, not because of the simplicity but because of the availability of standard algorithms.  Many packages use modules from the ... qhull … package.

Normally containers only make sense if you are using projected coordinates or can perform geodesic densification. 

Output example

Pretty well sums it up. 

  • Specify the input featureclass (polygon, polyline or multipoint),
  • the output featureclass,
  • select convex hulls from the tool selection

--------------------------------------------------------------------------------------------------------------------------------------------------------

The conversion uses the numpy based Geo class that I describe in the 8 part series on geometry. 

I could add the original attributes to the result (either within the toolset or after) or I could also 

Add Geometry Attributes ...

The full call to the tool, or the equivalent bits that I need.

A spatial or attribute join would be another alternative if you need attributes as well.

If you have a preference let me know.

The results are derived quickly and there is an optimization if the number of points making up the shape exceed about 50.  This was a qualitative estimate of the cross-over point between implementing a python solution versus a C compiled solution from qhull.

WARNING

I have code that checks the validity of the file paths.  If you input or output paths contain spaces or other flotsam, then the tool will not produce any results.  Why?  Too many questions where file paths are the problem.  I won't 'enable' the current practice

Download

You can copy the contents of the folder on my GitHub pages.  No fancy install, just create a folder, through the stuff in, load the toolbox and give it a try.

Free_Tools

About the Author
Retired Geomatics Instructor at Carleton University. I am a forum MVP and Moderator. Current interests focus on python-based integration in GIS. See... Py... blog, my GeoNet blog...
Labels