com.supermap.analyst.spatialanalyst
类 InterpolationRBFParameter
- java.lang.Object
-
- com.supermap.data.InternalHandle
-
- com.supermap.data.InternalHandleDisposable
-
- com.supermap.analyst.spatialanalyst.InterpolationParameter
-
- com.supermap.analyst.spatialanalyst.InterpolationRBFParameter
-
- 所有已实现的接口:
- IDisposable
public class InterpolationRBFParameter extends InterpolationParameter
径向基函数 RBF(Radial Basis Function)插值法(也叫样条插值)参数类,继承自InterpolationParameter
类。该类为 RBF 插值算法提供必要的参数信息,继承自InterpolationParameter
类。样条插值提供了设置障碍数据集的方法,设置setBarrierDataset即可。- 示范代码:
- 以下代码示范了对点数据集进行插值分析,并且选择径向基函数 RBF 插值法进行插值。假设名为 ElevationPoints 数据源中存在一个名称为 elevationpoints 的点数据集,数据集中的 “ELEV” 字段存储了点数据的高程信息。
public void interpolationRBF() { //返回用来进行插值分析的点数据集 Workspace workspace = new Workspace(); DatasourceConnectionInfo datasourceConnectionInfo = new DatasourceConnectionInfo("G:\\Data\\ElevationPoints.udb", "ElevationPoints", ""); Datasource targetDatasource = workspace.getDatasources().open(datasourceConnectionInfo); DatasetVector datasetElevPoints = (DatasetVector)targetDatasource.getDatasets().get("elevationpoints"); //返回一个合法的名称作为结果数据集的的名称 String resultDatasetName = targetDatasource.getDatasets().getAvailableDatasetName("resultDatasetGrid"); //设置径向基函数RBF插法参数 InterpolationRBFParameter interpolationMethodRBFParam = new InterpolationRBFParameter(); interpolationMethodRBFParam.setExpectedCount( 5); interpolationMethodRBFParam.setBounds ( datasetElevPoints.getBounds()); interpolationMethodRBFParam.setResolution ( 285); interpolationMethodRBFParam.setSearchMode ( SearchMode.KDTREE_FIXED_COUNT); //调用插值分析类的插值分析方法实现对点数据集的插值,并返回分析结果 DatasetGrid resultInterpolationGrid = Interpolator.interpolate(interpolationMethodRBFParam, datasetElevPoints, "ELEV", 0.7, targetDatasource, resultDatasetName, PixelFormat.SINGLE); //释放工作空间占有的资源 workspace.dispose(); }
-
-
构造器概要
构造器 构造器和说明 InterpolationRBFParameter()
构造一个新的 InterpolationRBFParameter 对象。InterpolationRBFParameter(double tension, double smooth, double resolution)
根据指定的参数构造一个 InterpolationRBFParameter 的新对象。InterpolationRBFParameter(double tension, double smooth, double resolution, SearchMode mode, double searchRadius, int expectedCount)
根据指定的参数构造一个 InterpolationRBFParameter 的新对象。
-
方法概要
所有方法 实例方法 具体方法 限定符和类型 方法和说明 DatasetVector
getBarrierDataset()
获取障碍线数据集。double
getSmooth()
返回光滑系数,值域为 [0,1]。double
getTension()
返回张力系数。InterpolationAlgorithmType
getType()
返回插值算法类型。void
setBarrierDataset(DatasetVector barrierDataset)
设置障碍线数据集。void
setSmooth(double value)
设置光滑系数,值域为 [0,1]。void
setTension(double value)
设置张力系数。String
toString()
返回一个表示 InterpolationRBFParameter 对象的字符串。-
从类继承的方法 com.supermap.analyst.spatialanalyst.InterpolationParameter
dispose, getBounds, getExpectedCount, getMaxPointCountForInterpolation, getMaxPointCountInNode, getResolution, getSearchMode, getSearchRadius, setBounds, setExpectedCount, setMaxPointCountForInterpolation, setMaxPointCountInNode, setResolution, setSearchMode, setSearchRadius
-
-
-
-
构造器详细资料
-
InterpolationRBFParameter
public InterpolationRBFParameter()
构造一个新的 InterpolationRBFParameter 对象。
-
InterpolationRBFParameter
public InterpolationRBFParameter(double tension, double smooth, double resolution)
根据指定的参数构造一个 InterpolationRBFParameter 的新对象。- 参数:
tension
- 指定的张力系数。smooth
- 指定的光滑系数。resolution
- 指定的插值运算时使用的分辨率。
-
InterpolationRBFParameter
public InterpolationRBFParameter(double tension, double smooth, double resolution, SearchMode mode, double searchRadius, int expectedCount)
根据指定的参数构造一个 InterpolationRBFParameter 的新对象。- 参数:
tension
- 指定的张力系数。smooth
- 指定的光滑系数。resolution
- 指定的插值运算时使用的分辨率。mode
- 指定的插值运算时使用的查找方式。searchRadius
- 指定的插值运算时使用的查找的范围。expectedCount
- 指定的插值运算时待查找的点数。
-
-
方法详细资料
-
getTension
public double getTension()
返回张力系数。- 返回:
- 张力系数。
- 默认值:
- 默认值为 40.0。
-
setTension
public void setTension(double value)
设置张力系数。- 参数:
value
- 张力系数。
-
getSmooth
public double getSmooth()
返回光滑系数,值域为 [0,1]。- 返回:
- 光滑系数。
- 默认值:
- 默认值为 0.100000001490116。
-
setSmooth
public void setSmooth(double value)
设置光滑系数,值域为 [0,1]。- 参数:
value
- 光滑系数。
-
getBarrierDataset
public DatasetVector getBarrierDataset()
获取障碍线数据集。- 返回:
- 获取障碍线数据集。
-
setBarrierDataset
public void setBarrierDataset(DatasetVector barrierDataset)
设置障碍线数据集。- 参数:
barrierDataset
- 障碍线数据集。
-
getType
public InterpolationAlgorithmType getType()
返回插值算法类型。- 指定者:
getType
在类中InterpolationParameter
- 返回:
- 插值算法的类型。
- 另请参阅:
InterpolationAlgorithmType
-
toString
public String toString()
返回一个表示 InterpolationRBFParameter 对象的字符串。格式为{Tension =,Smooth =}。- 覆盖:
toString
在类中InterpolationParameter
- 返回:
- 一个表示 InterpolationRBFParameter 对象的字符串。
-
-
Copyright © 2021–2024 SuperMap. All rights reserved.