I have an arcpy script creating thousands of points in a feature layer, based on a river network. At creation time, I'd like to use the value from a (large) elevation raster corresponding to the new point's location.
It needs to be at creation time, because I want to subtract the value from the previous value, and that information will be difficult to get afterwards.
I've tried using sa.ExtractValueToPoints, but it's very slow and it's a lot of extra overhead to create a point feature with my x,y data, run the function, and then extract the value from the newly created feature. There are a few tens of thousands of points...
Is there some way of getting directly at the raster data (while retaining the spatial information) that I don't know about?
Edit: I managed to work around it as explained below in my comments. I'll explore the NumPy option, as I think this is something I might run into again.