deepmr.fft.nufft_adj#
- deepmr.fft.nufft_adj(kspace, coord, shape, basis=None, device='cpu', threadsperblock=128, width=4, oversamp=1.25)[source]#
N-dimensional adjoint Non-Uniform Fast Fourier Transform.
- Parameters:
kspace (torch.Tensor) – Input Non-Cartesian kspace of shape
(..., ncontrasts, nviews, nsamples)
.coord (torch.Tensor) – K-space coordinates of shape
(ncontrasts, nviews, nsamples, ndims)
. Coordinates must be normalized between(-0.5 * shape, 0.5 * shape)
.shape (int | Iterable[int]) – Cartesian grid size of shape
(ndim,)
. If scalar, isotropic matrix is assumed.basis (torch.Tensor, optional) – Low rank subspace projection operator of shape
(ncontrasts, ncoeffs)
; can beNone
. The default isNone
.device (str, optional) – Computational device (
cpu
orcuda:n
, withn=0, 1,...nGPUs
). The default iscpu
.threadsperblock (int) – CUDA blocks size (for GPU only). The default is
128
.width (int | Iterable[int], optional) – Interpolation kernel full-width of shape
(ndim,)
. If scalar, isotropic kernel is assumed. The default is2
.oversamp (float | Iterable[float], optional) – Grid oversampling factor of shape
(ndim,)
. If scalar, isotropic oversampling is assumed. The default is1.125
.
- Returns:
image – Output image of shape
(..., ncontrasts, ny, nx)
(2D) or(..., ncontrasts, nz, ny, nx)
(3D).- Return type:
Notes
Non-uniform coordinates axes ordering is assumed to be
(x, y)
for 2D signals and(x, y, z)
for 3D. Conversely, axes ordering for grid shape, kernel width and Kaiser Bessel parameters are assumed to be(z, y, x)
.Coordinates tensor shape is
(ncontrasts, nviews, nsamples, ndim)
. If there are less dimensions (e.g., single-shot or single contrast trajectory), assume singleton for the missing ones:coord.shape = (nsamples, ndim) -> (1, 1, nsamples, ndim)
coord.shape = (nviews, nsamples, ndim) -> (1, nviews, nsamples, ndim)