ArcGIS Desktop

  • ArcGIS Pro
  • ArcMap

  • My Profile
  • 帮助
  • Sign Out
ArcGIS Desktop

ArcGIS Online

专为贵组织打造的制图平台

ArcGIS Desktop

全面的专业性 GIS

ArcGIS Enterprise

面向企业的 GIS

ArcGIS Developers

用于构建位置感知应用程序的工具

ArcGIS Solutions

适用于行业的免费模板地图和应用程序

ArcGIS Marketplace

获取适用于组织的应用程序和数据

  • 文档
  • 支持
Esri
  • 登录
user
  • 我的个人资料
  • 登出

ArcMap

  • 主页
  • 入门
  • 地图
  • 分析
  • 管理数据
  • 工具
  • 扩展模块

表面坡度

  • 描述
  • 插图
  • 使用方法
  • 语法
  • 代码示例
  • 环境
  • 许可信息

描述

创建表示不规则表面的坡度值范围的面要素。

插图

表面坡度

使用方法

  • 每个三角形的表面法线(由两条三角形边的矢量叉积计算得出)用于以百分比或度为单位确定坡度。坡度百分比描述了表面法线的高度变化与水平距离变化之间的比率,而以度为单位的坡度是表面法线和水平面之间的倾角。

  • 产生的每个面都表示一个坡度值范围,这些坡度值均基于执行工具时所使用的分类间隔。默认分类间隔将坡度测量分为九组,如下所示:

    坡度代码百分比 角度范围

    1

    0.00 - 1.00

    0.00 - 0.57

    2

    1.00 - 2.15

    0.57 - 1.43

    3

    2.15 - 4.64

    1.43 - 2.66

    4

    4.64 - 10.0

    2.66 - 5.71

    5

    10.00 - 21.50

    5.71 - 12.13

    6

    21.50 - 46.40

    12.13 - 24.89

    7

    46.40 - 100.0

    24.89 - 45.00

    8

    100.0 - 1000.0

    45.00 - 84.29

    9

    1000.0 <

    84.29 - 90.0

  • 可通过在分类间隔表参数中指定最多含两个数值字段的表来自定义坡度分类。第一列标识出坡度分类的中断点。如果提供了第二列,则将其值用于关联属于各个面要素的代码。如果使用下表,0 到 10 的所有坡度值将由代码 1 表示,10 到 25 的所有坡度值将由代码 2 表示,以此类推。表的分类间隔单位在坡度单位 (units) 参数中设置。

    分类间隔代码

    10.0

    1

    25.0

    2

    40.0

    3

    70.0

    4

    该表可以是任何受支持的格式(.dbf、.txt 或地理数据库表)。字段的名称不重要,因为第一个始终用于分类间隔,第二个始终用于坡向编码。

语法

arcpy.ddd.SurfaceSlope(in_surface, out_feature_class, {units}, {class_breaks_table}, {slope_field}, {z_factor}, {pyramid_level_resolution})
参数说明数据类型
in_surface

TIN、terrain 或 LAS 数据集,其坡度测量值将写入输出面要素。

LAS Dataset Layer; Terrain Layer; TIN Layer
out_feature_class

将由此工具生成的要素类。

Feature Class
units
(可选)

在计算坡度中所用的测量单位。

  • PERCENT —坡度以百分比值形式表示。这是默认设置。
  • DEGREE —坡度以相对于水平面的倾角形式表示。
String
class_breaks_table
(可选)

包含分类间隔的表,将用于分组输出要素。此表格的第一列指示中断点,而第二列提供分类代码。

Table
slope_field
(可选)

包含坡度值的字段。

String
z_factor
(可选)

Z 值将乘上的系数。此值通常用于转换 Z 线性单位来匹配 XY 线性单位。默认值为 1,此时高程值保持不变。如果输入表面的空间参考具有已指定线性单位的 Z 基准,则将禁用此参数。

Double
pyramid_level_resolution
(可选)

此工具将使用 terrain 金字塔等级的 z 容差或窗口大小分辨率。默认值为 0(z 容差),或全分辨率(窗口大小)。

Double

代码示例

表面坡度 (SurfaceSlope) 示例 1(Python 窗口)

下面的示例演示了如何在 Python 窗口中使用此工具。

import arcpy
from arcpy import env

arcpy.CheckOutExtension("3D")
env.workspace = "C:/data"
arcpy.SurfaceSlope_3d("sample.gdb/featuredataset/terrain", "s_slope.shp", "PERCENT")
表面坡度 (SurfaceSlope) 示例 2(独立脚本)

下面的示例演示了如何在独立 Python 脚本中使用此工具。

'''****************************************************************************
Name: SurfaceSlope Example
Description: This script demonstrates how to use the 
             SurfaceAspect and SurfaceSlope tools to generate a polygon
             that contains the intersection of both 
****************************************************************************'''

# Import system modules
import arcpy
from arcpy import env

# Obtain a license for the ArcGIS 3D Analyst extension
arcpy.CheckOutExtension("3D")

# Set environment settings
env.workspace = "C:/data"

try:
    # List all TINs in workspace
    listTINs = arcpy.ListDatasets("","TIN")
    # Determine whether the list contains any TINs
    if len(listTINs) > 0:
        for dataset in listTINs:
            print dataset
            # Set Local Variables
            aspect = arcpy.CreateUniqueName("Aspect.shp")
            slope = arcpy.CreateUniqueName("Slope.shp")
            outFC = dataset + "_Aspect_Slope.shp"
            #Execute SurfaceAspect
            arcpy.SurfaceAspect_3d(dataset, aspect)
            #Execute SurfaceSlope
            arcpy.SurfaceSlope_3d(dataset, slope)
            #Execute SurfaceSlope
            print "Starting Intersect"
            arcpy.Intersect_analysis(aspect + " #;" + slope + " #", outFC, "ALL")
            print "Completed intersect for " + dataset
            del aspect, slope, outFC
    else:
        print "There are no TINs in the " + env.workspace + " directory."
except:
    # Returns any other error messages
    print arcpy.GetMessages(2)

del arcpy, listTINs

环境

  • 当前工作空间
  • 临时工作空间
  • 范围
  • 输出坐标系
  • 地理变换
  • XY 分辨率
  • XY 容差
  • 输出 XY 属性域
  • 输出配置关键字
  • 自动提交
  • Terrain 内存使用

许可信息

  • Basic: 需要 3D Analyst
  • Standard: 需要 3D Analyst
  • Advanced: 需要 3D Analyst

相关主题

  • 表面三角化工具集概述
  • 有关使用 ArcGIS 3D Analyst 扩展模块进行地理处理的基础知识
  • 有关表面的基础知识
  • 了解表面的形状
  • 什么是 TIN 表面?

ArcGIS Desktop

  • 主页
  • 文档
  • 支持

ArcGIS

  • ArcGIS Online
  • ArcGIS Desktop
  • ArcGIS Enterprise
  • ArcGIS
  • ArcGIS Developer
  • ArcGIS Solutions
  • ArcGIS Marketplace

关于 Esri

  • 关于我们
  • 招贤纳士
  • Esri 博客
  • 用户大会
  • 开发者峰会
Esri
分享您的想法。
Copyright © 2021 Esri. | 隐私政策 | 法律声明