In an effort to reduce processing time, I am looking for ways to pre-process data within my script. I have ~18,000 featureclasses with ~500 features each (all simple circle polygons) from which I want to eliminate coastal land area (another simplified polygon) using the Erase function.
My idea for reducing overall processing time is to check for overlap between each feature class and the coastline polygon. If there is overlap, the script should erase the land from the features. If there is no overlap, the script should move on, and look at the next feature class.
Specific questions:
What is the most efficient, Pythonic way to say "if there is overlap, do XX?" I cannot find documentation to do something similar to "if Overlap == True" besides the method:
MakeFeatureLayer-->SelectFeatureByLocation-->CopyFeature-->GetRowCount--> if RowCount>0
Would this actually reduce processing time or am I crazy?
I'm working locally on my machine, running the script in IDLE, with ArcGIS 10.1 (with all licenses) on a 32-bit Windows 7, 3.33GHz Intel DuoCore, 4GB RAM computer.