描述
利用指定的橡皮页变换链接,通过橡皮页变换对输入要素进行空间调整修改,从而使输入要素更好地与所需目标要素对齐。
插图
使用方法
该工具旨在结合生成橡皮页变换链接工具使用。橡皮页变换根据指定的橡皮页变换连接线进行空间校正,从而使输入要素位置更加准确的与目标要素位置对齐。输入链接要素表示常规链接;输入点要素表示在橡皮页变换过程中保持源位置不动的标识链接。输入链接要素与标识链接要素均必须具有 SRC_FID 与 TGT_FID 字段。
方法参数确定用于在橡皮页变换过程中创建临时 TIN 的插值方法。
- 线性 - 该方法用于创建快速的 TIN 表面,但并不真正考虑邻域。此方法速度稍快,并且当许多橡皮页变换链接均匀分布在要调整的数据上时,将生产优质结果。
- 自然邻域 - 该方法稍慢,但当橡皮页变换连接线不是很多并且在数据集中较为分散时,得出的结果会更加精确。在这种情况下使用线性法则不够精确。
警告:
此工具会修改输入数据。有关详细信息以及避免数据被意外更改的策略,请参阅修改或更新输入数据的工具。
注:
所有输入必须处于同一坐标系。
语法
arcpy.edit.RubbersheetFeatures(in_features, in_link_features, {in_identity_links}, {method})
参数 | 说明 | 数据类型 |
in_features | 要调整的输入要素。可以为点、线、面或注记。 | Feature Layer |
in_link_features | 表示橡皮页变换常规链接的输入线要素。 | Feature Layer |
in_identity_links (可选) | 表示橡皮页变换识别链接的输入点要素。 | Feature Layer |
method (可选) | 指定校正要素所用到的橡皮页变换法。
| String |
派生输出
名称 | 说明 | 数据类型 |
out_feature_class | 更新后的输入要素。 | 要素图层 |
代码示例
以下 Python 窗口脚本演示了如何在即时模式下使用 RubbersheetFeatures 函数。
import arcpy
arcpy.env.workspace = "C:/data"
arcpy.RubbersheetFeatures_edit("source_Roads.shp","rubbersheet_Links.shp",
"rubbersheet_Links_pnt.shp", "LINEAR")
以下独立脚本演示了如何在脚本环境中应用 RubbersheetFeatures 函数。
# Name: RubbersheetFeatures_example_script2.py
# Description: Performs rubbersheeting spatial adjustment using links produced by
# GenerateRubbersheetLinks, assuming newly updated roads are more
# accurate than existing base roads. The links go from base road data
# to corresponding newly updated road data. The links are then
# analyzed for potential errors; they are finally used to adjust the
# base roads (a copy is made) to better align with the updated roads.
# Author: Esri
# -----------------------------------------------------------------------
# Import system modules
import arcpy
from arcpy import env
# Set environment settings
env.overwriteOutput = True
env.workspace = r"D:\conflationTools\ScriptExamples\data.gdb"
# Set local variables
sourceFeatures = "baseRoads"
targetFeatures = "updateRoads"
grlOutput = "grlinks_out"
grlOutputPts = "grlinks_out_pnt"
search_distance = "300 Feet"
match_fields = "FULLNAME RD_NAME"
qaLocations = "qa_locations"
# Generate rubbersheet links
arcpy.GenerateRubbersheetLinks_edit(sourceFeatures, targetFeatures, grlOutput, search_distance, match_fields)
# ====================================================================================
# Note 1: The result of GenerateRubbersheetLinks may contain errors; see tool reference.
# Inspection and editing may be necessary to ensure correct links before using
# them for rubbersheeting.
#
# One of the common errors are intersecting or touching links. Their locations
# can be found by the process below.
# ====================================================================================
# Find locations where links intersect or touch; the result contains coincident points
arcpy.Intersect_analysis(grlOutput, qaLocations, "", "", "POINT")
# Delete coincident points
arcpy.DeleteIdentical_management(qaLocations, "Shape")
# ====================================================================================
# Note 2: At this point you can manually inspect locations in qaLocations; delete or
# modify links as needed.
# ====================================================================================
# Make a copy of the sourceFeatures for rubbersheeting
arcpy.CopyFeatures_management(sourceFeatures, "sourceFeatures_Copy")
# Use the links for rubbersheeting
arcpy.RubbersheetFeatures_edit("sourceFeatures_Copy", grlOutput, grlOutputPts, "LINEAR")
许可信息
- Basic: 否
- Standard: 否
- Advanced: 是