skimage2.transform.ifrt2#

skimage2.transform.ifrt2(a)[source]#

Compute the 2-dimensional inverse finite Radon transform (iFRT) for the input array.

Parameters:
andarray of int, shape (M+1, M)

Input array.

Returns:
iFRTndarray of int, shape (M, M)

Inverse Finite Radon Transform coefficients.

See also

frt2

The two-dimensional FRT

Notes

The FRT has a unique inverse if and only if M is prime. See [1] for an overview. The idea for this algorithm is due to Vlad Negnevitski.

References

[1]

A. Kingston and I. Svalbe, “Projective transforms on periodic discrete image arrays,” in P. Hawkes (Ed), Advances in Imaging and Electron Physics, 139 (2006)

Examples

>>> SIZE = 59
>>> img = np.tri(SIZE, dtype=np.int32)

Apply the Finite Radon Transform:

>>> from _skimage2.transform import frt2
>>> f = frt2(img)

Apply the Inverse Finite Radon Transform to recover the input

>>> fi = ifrt2(f)

Check that it’s identical to the original

>>> assert len(np.nonzero(img-fi)[0]) == 0