OrthoRectification¶
该应用程序允许对来自受支持传感器的光学和雷达图像进行正射校正。
描述¶
这个应用程序使用逆传感器建模,结合选择的内插函数,将传感器几何图像重采样为地面几何规则网格。地面几何体规则栅格是相对于地图投影定义的(请参见地图参数)。该应用程序提供了几种模式来估计输出网格参数(原点和地面采样距离),包括从图像元数据、用户定义的ROI角点或其他正射图像自动估计图像大小、地面采样距离或两者。可以指定数字高程模型和大地水准面文件来考虑地形变形。对于SPOT5图像,可以使用RPC模型近似传感器模型,以加快计算速度。
参数¶
输入和输出数据¶
这组参数允许设置输入和输出图像。
Input Image -io.in image
Mandatory
The input image to ortho-rectify
Output Image -io.out image [dtype]
Mandatory
The ortho-rectified output image
Map Projection -map [utm|lambert2|lambert93|wgs|epsg]
Default value: utm
Defines the map projection to be used.
- Universal Trans-Mercator (UTM)
A system of transverse mercator projections dividing the surface of Earth between 80S and 84N latitude. - Lambert II Etendu
This is a Lambert Conformal Conic projection mainly used in France. - Lambert93
This is a Lambert 93 projection mainly used in France. - WGS 84
This is a Geographical projection - EPSG Code
This code is a generic way of identifying map projections, and allows specifying a large amount of them. See www.spatialreference.org to find which EPSG code is associated to your projection;
通用跨墨卡托(UTM)选项¶
Zone number -map.utm.zone int
Default value: 31
The zone number ranges from 1 to 60 and allows defining the transverse mercator projection (along with the hemisphere)
Northern Hemisphere -map.utm.northhem bool
Default value: false
The transverse mercator projections are defined by their zone number as well as the hemisphere. Activate this parameter if your image is in the northern hemisphere.
EPSG代码选项¶
EPSG Code -map.epsg.code int
Default value: 4326
See www.spatialreference.org to find which EPSG code is associated to your projection
输出图像网格¶
这组参数允许定义将在其上对输入图像进行重采样的网格。
Parameters estimation modes -outputs.mode [auto|autosize|autospacing|outputroi|orthofit]
Default value: auto
- User Defined
This mode allows you to fully modify default values. - Automatic Size from Spacing
This mode allows you to automatically compute the optimal image size from given spacing (pixel size) values - Automatic Spacing from Size
This mode allows you to automatically compute the optimal image spacing (pixel size) from the given size - Automatic Size from Spacing and output corners
This mode allows you to automatically compute the optimal image size from spacing (pixel size) and output corners - Fit to ortho
Fit the size, origin and spacing to an existing ortho image (uses the value of outputs.ortho)
Upper Left X -outputs.ulx float
Mandatory
Cartographic X coordinate of upper-left corner (meters for cartographic projections, degrees for geographic ones)
Upper Left Y -outputs.uly float
Mandatory
Cartographic Y coordinate of the upper-left corner (meters for cartographic projections, degrees for geographic ones)
Size X -outputs.sizex int
Mandatory
Size of projected image along X (in pixels)
Size Y -outputs.sizey int
Mandatory
Size of projected image along Y (in pixels)
Pixel Size X -outputs.spacingx float
Mandatory
Size of each pixel along X axis (meters for cartographic projections, degrees for geographic ones)
Pixel Size Y -outputs.spacingy float
Mandatory
Size of each pixel along Y axis (meters for cartographic projections, degrees for geographic ones)
Lower right X -outputs.lrx float
Cartographic X coordinate of the lower-right corner (meters for cartographic projections, degrees for geographic ones)
Lower right Y -outputs.lry float
Cartographic Y coordinate of the lower-right corner (meters for cartographic projections, degrees for geographic ones)
Model ortho-image -outputs.ortho image
A model ortho-image that can be used to compute size, origin and spacing of the output
Force isotropic spacing by default -outputs.isotropic bool
Default value: true
Default spacing (pixel size) values are estimated from the sensor modeling of the image. It can therefore result in a non-isotropic spacing. This option allows you to force default values to be isotropic (in this case, the minimum of spacing in both direction is applied. Values overridden by user are not affected by this option.
Default pixel value -outputs.default float
Default value: 0
Default value to write when outside of input image.
高程管理¶
这组参数允许管理高程值。
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.
Interpolation -interpolator [bco|nn|linear]
Default value: bco
This group of parameters allows one to define how the input image will be interpolated during resampling.
- Bicubic interpolation
- Nearest Neighbor interpolation
Nearest neighbor interpolation leads to poor image quality, but it is very fast. - Linear interpolation
Linear interpolation leads to average image quality but is quite fast
双三次插值选项¶
Radius for bicubic interpolation -interpolator.bco.radius int
Default value: 2
This parameter allows one to control the size of the bicubic interpolation filter. If the target pixel size is higher than the input pixel size, increasing this parameter will reduce aliasing artifacts.
速度优化参数¶
这组参数允许优化处理时间。
RPC modeling (points per axis) -opt.rpc int
Default value: 10
Enabling RPC modeling allows one to speed-up SPOT5 ortho-rectification. Value is the number of control points per axis for RPC estimation
Available RAM (MB) -opt.ram int
Default value: 256
This allows setting the maximum amount of RAM available for processing. As the writing task is time consuming, it is better to write large pieces of data, which can be achieved by increasing this parameter (pay attention to your system capabilities)
Resampling grid spacing -opt.gridspacing float
Default value: 4
Resampling is done according to a coordinate mapping deformation grid, whose pixel size is set by this parameter, and expressed in the coordinate system of the output image The closer to the output spacing this parameter is, the more precise will be the ortho-rectified image,but increasing this parameter will reduce processing time.
实例¶
从命令行执行以下操作:
otbcli_OrthoRectification -io.in QB_TOULOUSE_MUL_Extract_500_500.tif -io.out QB_Toulouse_ortho.tif
来自Python的评论:
import otbApplication
app = otbApplication.Registry.CreateApplication("OrthoRectification")
app.SetParameterString("io.in", "QB_TOULOUSE_MUL_Extract_500_500.tif")
app.SetParameterString("io.out", "QB_Toulouse_ortho.tif")
app.ExecuteAndWriteOutput()
局限性¶
- 支持的传感器(光学和雷达)包括:GeoEye、Ikonos、昂宿星、Quickbird、Radarsat、Sentinel-1、SPOT5(TIF格式)、SPOT6/7、TerraSAR-X、WorldView 1/2/3以及任何嵌入了RPC标签的TIF图像。
- 另请注意,opt.gridspace的默认值可能并不适用于所有传感器。特别是,如果此值低于目标地面采样距离,处理时间可能会增加很多。在这种情况下,会发出警告。典型值应为DEM地面采样距离的一半。