fmeobjects.FMERasterTools.calculateSlope

FMERasterTools.calculateSlope(slopeType, raster, parms)

Calculate the slope (maximum rate of change in z) for each selected band of a raster.

Parameters:

Possible parms are:

kFME_CalculateSlope_interpolateNodata

  • Yes or No (Default is No)

  • Whether to calculate values at raster edges and near nodata values. When this is set to No, there will be a one pixel border around the edge of the raster set to the nodata value. Additionally, when any pixel in the 3x3 window used to calculate the slope value is equal to nodata, the output pixel will also be set to nodata. If the input band does not have a nodata value, the output band nodata value will be set to -1. When this is set to Yes, values around the edge and near nodata values will be estimated by interpolating missing values.

kFME_CalculateSlope_algorithm

  • (Default) Use Horn’s method for slope/aspect calculation. Better suited to rougher terrain.

  • Use Zevenbergen & Thorne’s method for slope/aspect calculation. Better suited to smooth terrain.

Return type:

FMERaster

Returns:

The raster after calculating the slope.

Raises:

FMEException – An exception is raised if an error occurred.