torchbp.ops.coherence module

torchbp.ops.coherence.coherence_2d(img0, img1, Navg)[source]

Coherence of two complex images over moving window Navg.

Parameters:
  • img0 (Tensor) – Complex valued 2D image. If 3D then the first dimension is batch dimension.

  • img1 (Tensor) – Complex valued 2D image. If 3D then the first dimension is batch dimension.

  • Navg (tuple) – Number of averaged cells in 2D (N1, N0).

Returns:

out – Real valued coherence image with same shape as input calculated over the moving window.

Return type:

Tensor

torchbp.ops.coherence.power_coherence_2d(img0, img1, Navg, corr_output=True)[source]

Coherence of two complex images over moving window Navg. Calculated from squared absolute value of the images. [1]

Parameters:
  • img0 (Tensor) – Complex valued 2D image. If 3D then the first dimension is batch dimension.

  • img1 (Tensor) – Complex valued 2D image. If 3D then the first dimension is batch dimension.

  • Navg (tuple) – Number of averaged cells in 2D (N1, N0).

  • corr_output (bool) – Return ordinary correlation coefficient by calculating sqrt(2*v-1) for all output values if v > 0.5 and else 0.

Return type:

Tensor

References

[1]

A. M. Guarnieri and C. Prati, “SAR interferometry: a “Quick and dirty” coherence estimator for data browsing,” in IEEE Transactions on Geoscience and Remote Sensing, vol. 35, no. 3, pp. 660-669, May 1997.

Returns:

out – Real valued coherence image with same shape as input calculated over the moving window.

Return type:

Tensor

Parameters:
  • img0 (Tensor)

  • img1 (Tensor)

  • Navg (tuple)

  • corr_output (bool)