Select to view content in your preferred language

Is the "Summarize Elevation" geoprocessing tool actually implemented in python?

267
1
03-21-2024 06:56 AM
Labels (3)
DanielRubianes
New Contributor

I am attempting to write a python script that utilizes the "Summarize Elevation" geoprocessing tool.

 

result: arcpy.Result = arcpy.agolservices.SummarizeElevation(<feature_class>)

 

 

This function call does not  create an output summary in the default GDB where the geoprocessing tool would.

 After pouring through documentation I found that the function call returns an "arcpy.Result" object which has a function called "getOutput(index)". This is the result of that function call:

Traceback (most recent call last):
  File "<python tool path>", line 214, in execute
    print(result.getOutput(0))
  File "C:\Program Files\ArcGIS\Pro\Resources\ArcPy\arcpy\arcobjects\arcobjects.py", line 2465, in getOutput
    return convertArcObjectToPythonObject(self._arc_object.GetOutput(*gp_fixargs(args)))
IndexError: ResultObject: Error in getting output

 

 

I also tried to run "arcpy.management.PackageResult" on this Result object to get some sort of output, but this does not support the "Ready to Use" toolbox

 

ERROR 001378: Tool Summarize Elevation is unsupported on server
Failed to execute (PackageResult).

 

Is this function actually implemented in python? All I need is the elevation value for each point feature in a feature class I am working in. Thank you in advance for any help.

 

0 Kudos
1 Reply
DanielRubianes
New Contributor

RESOLVED:

I did not realize that this geoprocessing tool runs on Esri's servers and is thus asynchronous. I need to wait until Result.status == 4.

0 Kudos