需要 Spatial Analyst 许可。
摘要
定义一个较大输入值隶属度更接近于 1 的模糊隶属度函数。通过一个用户定义的中点(分配的隶属度为 0.5)和定义的散度来定义函数。
讨论
使用 FuzzyLarge 对象的工具:FuzzyMembership。
FuzzyLarge 函数的方程为:
方程的输入为 f1(散度 (spread))和 f2(中点 (midpoint))。增大散度会导致模糊隶属度曲线变得陡峭。
当较大的输入值具有较高的隶属度时,较大值函数十分有用。
输入值可以为整型值或浮点型正值。
语法
FuzzyLarge (midpoint, spread)
参数 | 说明 | 数据类型 |
midpoint | The user-defined value with a fuzzy membership of 0.5. The default is the midpoint of the range of values of the input raster. | Double |
spread | Defines the spread of the Large function. The spread generally ranges from 1 to 10, with the larger the value results in a steeper distribution from the midpoint. (默认值为 5) | Double |
属性
属性 | 说明 | 数据类型 |
midpoint (读写) | 定义隶属度函数中点的用户定义值。 | Double |
spread (读写) | Defines the spread of the membership function. The larger the value results in a steeper distribution from the midpoint. | Double |
代码实例
FuzzyLarge 示例 1(Python 窗口)
演示如何在 Python 窗口下创建 FuzzyLarge 类,并通过 FuzzyMembership 工具使用该类。
import arcpy
from arcpy.sa import *
from arcpy import env
env.workspace = "c:/sapyexamples/data"
outFzyMember = FuzzyMembership("as_std", FuzzyLarge(12, 5))
outFzyMember.save("c:/sapyexamples/fzymemb")
FuzzyLarge 示例 2(独立脚本)
使用 FuzzyLarge 类执行 FuzzyMembership。
# Name: FuzzyLarge_Ex_02.py
# Description: Scales input raster data into values ranging from zero to one
# indicating the strength of a membership in a set.
# Requirements: Spatial Analyst Extension
# Import system modules
import arcpy
from arcpy import env
from arcpy.sa import *
# Set environment settings
env.workspace = "C:/sapyexamples/data"
# Set local variables
inRaster = "as_std"
# Create the FuzzyLarge algorithm object
midpoint = 15
spread = 5
myFuzzyAlgorithm = FuzzyLarge(midpoint, spread)
# Check out the ArcGIS Spatial Analyst extension license
arcpy.CheckOutExtension("Spatial")
# Execute FuzzyMembership
outFuzzyMember = FuzzyMembership(inRaster, myFuzzyAlgorithm)
# Save the output
outFuzzyMember.save("c:/sapyexamples/fzylarge")