I have a script that takes a point featureclass (FC) through the following workflow:
- Select points that lie within individual polygons
- From the selected points within each polygon, randomly subset X% of points
- Merge the selected points from each polygon feature sub-selection
- Erase the original points with the merged subset and write to a new FC
I am using arcpy.Erase_analysis()
to do the point deletion.
The subset of data I am testing this script on has ~35000 point features. The point subset that I would like to use as the erase feature has ~3000 point features. It takes approximately 3-5 minutes to complete processing. Seeing that I will be scaling this up to a dataset containing ~30 million points, is there a more efficient method to delete points than by using the arcpy.Erase_analysis()
method? Perhaps, programmatically deleting points in an editing session? Or, a method that does not involve writing a new point FC?