arcpy获取多面体类型及其高度

获取矢量类型

代码:

shppath = "矢量路径"
shpdescribe= arcpy.Describe(shppath)
print(shpdescribe.shapeType)

结果:

获取多面体高度

代码:

import arcpy
shppath = "多面体路径"
rows=arcpy.UpdateCursor(shppath)
for row in rows:
    g=row.shape
    print(g.type)
    print(g.getPart(0)[0].Z)

结果:

高度的单位为m

你可能感兴趣的:(arcpy,arcpy)