向量数据提取ROI

根据输入图像范围对输入矢量数据进行ROI提取

描述

该应用程序提取属于支持图像包络指定区域的矢量数据特征。任何与支撑区域相交的特征都将被复制到输出。输出几何图形不会被修剪。

参数

输入和输出数据

包含输入和输出参数的组

Input Vector data -io.vd vectorfile Mandatory
Input vector data

Support image -io.in image Mandatory
Support image that specifies the extracted region

Output Vector data -io.out vectorfile Mandatory
Output extracted vector data

高程管理

这组参数允许管理高程值。

DEM directory -elev.dem directory
This parameter allows selecting a directory containing Digital Elevation Model files. Note that this directory should contain only DEM files. Unexpected behaviour might occurs if other images are found in this directory. Input DEM tiles should be in a raster format supported by GDAL.

Geoid File -elev.geoid filename [dtype]
Use a geoid grid to get the height above the ellipsoid in case there is no DEM available, no coverage for some points or pixels with no_data in the DEM tiles. A version of the geoid can be found on the OTB website (egm96.grd and egm96.grd.hdr at https://gitlab.orfeo-toolbox.org/orfeotoolbox/otb/-/tree/master/Data/Input/DEM).

Default elevation -elev.default float Default value: 0
This parameter allows setting the default height above ellipsoid when there is no DEM available, no coverage for some points or pixels with no_data in the DEM tiles, and no geoid file has been set. This is also used by some application as an average elevation value.

实例

从命令行执行以下操作:

otbcli_VectorDataExtractROI -io.in qb_RoadExtract.tif -io.vd qb_RoadExtract_classification.shp -io.out apTvUtVectorDataExtractROIApplicationTest.shp

来自Python的评论:

import otbApplication

app = otbApplication.Registry.CreateApplication("VectorDataExtractROI")

app.SetParameterString("io.in", "qb_RoadExtract.tif")
app.SetParameterString("io.vd", "qb_RoadExtract_classification.shp")
app.SetParameterString("io.out", "apTvUtVectorDataExtractROIApplicationTest.shp")

app.ExecuteAndWriteOutput()