tools.fovshift#
- bartorch.tools.fovshift()#
Shift the field of view of k-space data by a linear phase.
Multiplies
inputbyexp(2 pi i k . shift), withkin cycles per field of view andshiftin fields of view (fovshift.c:31, 128; num/filter.c:256). On Cartesian datak = p - n / 2for indexpof the last three axes – zero at the centre of a centred FFT for evenn. The image moves by-shift: underbartorch.fft()’s convention the result is the spectrum ofimage[p + shift * n].- Parameters:
input (torch.Tensor) – Centred Cartesian k-space whose last three axes (or fewer) are
(kz, ky, kx), or withtrajthe samples shaped asbartorch.nufft()returns them.shift (sequence of float) – Shift along the image axes in C order,
(z, y, x)or(y, x)or(x,); in fields of view, or in voxels withpixels.traj (torch.Tensor, default=None) – Trajectory
(..., samples, 3)in grid units,kx, ky, kz, asbartorch.tools.traj()produces.pixels (bool, default=False) –
shiftin voxels rather than fields of view; Cartesian only.