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

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

Generalize Shared Features

获得 Production Mapping 许可后可用。

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

描述

Performs the selected Simplify and Smooth operations on a line or polygon feature class. When used with spatially related features, this tool helps to maintain coincidence between shared edges.

使用方法

    警告:

    此工具会修改输入数据。有关详细信息以及避免数据被意外更改的策略,请参阅不创建输出数据集的工具。

  • A warning is raised if the input features are not in a projected coordinate system. This tool relies on linear distance units, which will create unexpected results in an unprojected coordinate system. It is strongly suggested that you run this tool on data in a projected coordinate system to ensure valid results. An error is raised and the tool will not process if the coordinate system is missing or unknown.

  • If feature classes are selected as topology feature classes, features from these feature classes that share a boundary with the main feature class will also be generalized to maintain coincidence.

  • The integrity of the results of this tool relies on the topological integrity of the inputs. Proper coincidence must exist between the edges of the input and topology feature classes. Features may visually look coincident but may not be coincident in the database. Running the Integrate tool to integrate all the input and topology feature classes can help to ensure database coincidence.

  • Extremely large features, especially lines with thousands of vertices, can cause performance issues. Running the Dice tool can subdivide large features into smaller features based on a specified vertex limit.

  • The input features must consist of valid geometries. Running the Repair Bad Geometry tool on each of the inputs removes invalid geometry in the data that could prevent the tool from successfully running.

  • When the Simplify operation is selected, the Simplify Line tool simplifies the feature using one of these algorithms:

    • The POINT_REMOVE method is the faster of the two algorithms; it removes redundant vertices. Use this method for data compression or more coarse simplification. The angularity (sharp corners) of the resulting line increases significantly as the tolerance increases, so the result may be less aesthetically pleasing than the input.
    • The BEND_SIMPLIFY method is slower but typically produces results that are more faithful to the original features; it operates by eliminating insignificant bends along lines. Use this method for more refined simplification.
    • The WEIGHTED_AREA algorithm works by first identifying triangles of effective area for each vertex. Those triangles are then weighted by a set of metrics to compare the flatness, skewness, and convexity of each area. The weighted areas guide the removal of their corresponding vertices to simplify the polygon outline while retaining as much character as possible.

  • When the Smooth operation is selected, the Smooth Line tool smooths the feature.

  • The tool sets a tolerance used by the Polynomial Approximation with Exponential Kernel (PAEK) algorithm. A tolerance must be specified and it must be greater than zero. You can choose a preferred unit; the default is the feature unit.

  • When using the BEZIER_INTERPOLATION smoothing algorithm, you must enter a zero (0) as the placeholder.

  • This tool cannot be run on data in an edit session. If you attempt to run the tool on data during an edit session, the error ERROR 000496: table is being edited appears. When this error appears, stop editing and run the script again.

语法

arcpy.production.GeneralizeSharedFeatures(Input_Features, Generalize_Operation, Simplify_Tolerance, Smooth_Tolerance, {Topology_Feature_Classes}, {Simplification_Algorithm}, {Smoothing_Algorithm})
参数说明数据类型
Input_Features

The features that will be generalized and smoothed. This must be a line or polygon feature class.

Feature Layer
Generalize_Operation

Specifies the type of operation to perform on the line or polygon features. The Simplify and Smooth operations will be run as listed in the selected operation.

  • SIMPLIFY —Runs Simplify only once on the line or polygon features.
  • SMOOTH —Runs Smooth only once on the line or polygon features.
  • SIMPLIFY_SMOOTH —Runs Simplify and Smooth once on the line or polygon features.
  • SIMPLIFY_SMOOTH_SIMPLIFY —Runs Simplify, Smooth, and Simplify on the line or polygon features.
  • SIMPLIFY_SMOOTH_SIMPLIFY_SMOOTH —Runs Simplify and Smooth twice on the line or polygon features in the order listed.
String
Simplify_Tolerance

The tolerance used by the simplification algorithm. When a Simplify operation is used, the tolerance must be greater than zero (0).

Linear unit
Smooth_Tolerance

The tolerance used by the smoothing algorithm. When a Smoothing operation is used, the tolerance must be greater than zero (0).

Linear unit
Topology_Feature_Classes
[Topology_Feature_Classes,...]
(可选)

One or more feature layers that are spatially related to the input features. Features that are coincident with the input features will maintain coincidence after generalization. Only the edges of the features that share a boundary with the input features will be modified.

These must be line or polygon features.

Feature Layer
Simplification_Algorithm
(可选)

Specifies the line simplification algorithm.

  • POINT_REMOVE —Retains critical points that depict the essential shape of a line and removes all other points. This is the default.
  • BEND_SIMPLIFY —Retains the critical bends in a line and removes extraneous bends.
  • WEIGHTED_AREA —Retains vertices that form triangles of the effective area. This algorithm works by first identifying triangles of effective area for each vertex.
String
Smoothing_Algorithm
(可选)

Specifies the smoothing algorithm.

  • PAEK —Acronym for Polynominal Approximation with Exponential Kernel. It calculates a smoothed line that will not pass through the input line vertices. This is the default.
  • BEZIER_INTERPOLATION —Fits Bezier curves between vertices. The resulting line passes through the vertices of the input line. This algorithm does not require a tolerance. Bezier curves will be approximated when the output is a shapefile.
String

代码示例

GeneralizeSharedFeatures example (stand-alone script)

The following stand-alone sample script demonstrates how to use GeneralizeSharedFeatures.

# Name: GeneralizeSharedFeaturesExample.py
# Description: Simplifies and smooths line or polygon features based on the selected
# operation. 
# Author: Esri
# Date: May 2017

# Import arcpy module
import arcpy

# Check out Production Mapping license
arcpy.CheckOutExtension("Foundation")

# set environment
arcpy.env.workspace="c:/data/Edit_Sample.gdb"

# Define variables
inFeatures="Features/CoastA"
topoFeatures="Features/CoastL"

# Generalize polygon feature and maintain coincidence with shared edges 
arcpy.GeneralizeSharedFeatures_production(inFeatures,"SIMPLIFY_SMOOTH","10 Meters","10 Meters",topoFeatures)

# Check in Production Mapping license
arcpy.CheckInExtension("Foundation")

环境

  • 当前工作空间
  • 临时工作空间
  • 制图分区

许可信息

  • Basic: 否
  • Standard: 否
  • Advanced: 需要 Production Mapping

相关主题

  • An overview of the Generalization toolset

ArcGIS Desktop

  • 主页
  • 文档
  • 支持

ArcGIS

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

关于 Esri

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