xdem.coreg.VerticalShift

xdem.coreg.VerticalShift#

class xdem.coreg.VerticalShift(vshift_func=<function average>, subsample=1.0)[source]#

DEM vertical shift correction.

Estimates the mean (or median, weighted avg., etc.) vertical offset between two DEMs.

__init__(vshift_func=<function average>, subsample=1.0)[source]#

Instantiate a vertical shift correction object.

Parameters:
  • vshift_func (Callable[[ndarray[Any, dtype[floating[Any]]]], floating[Any]]) – The function to use for calculating the vertical shift. Default: (weighted) average.

  • subsample (float | int) – Subsample the input for speed-up. <1 is parsed as a fraction. >1 is a pixel count.

Methods

__init__([vshift_func, subsample])

Instantiate a vertical shift correction object.

apply(elev[, bias_vars, resample, ...])

Apply the estimated transform to a DEM.

centroid()

Get the centroid of the coregistration, if defined.

copy()

Return an identical copy of the class.

error(reference_elev, to_be_aligned_elev[, ...])

Calculate the error of a coregistration approach.

fit(reference_elev, to_be_aligned_elev[, ...])

Estimate the coregistration transform on the given DEMs.

from_matrix(matrix)

Instantiate a generic Coreg class from a transformation matrix.

from_translation([x_off, y_off, z_off])

Instantiate a generic Coreg class from a X/Y/Z translation.

residuals(reference_elev, to_be_aligned_elev)

Calculate the residual offsets (the difference) between two DEMs after applying the transformation.

to_matrix()

Convert the transform to a 4x4 transformation matrix.

Attributes

is_affine

Check if the transform be explained by a 3D affine transform.