FourierOperatorSimple#

class mrinufft.operators.base.FourierOperatorSimple(samples, shape, density=False, n_coils=1, n_batchs=1, n_trans=1, smaps=None, raw_op=None, squeeze_dims=True)[source]#

Bases: FourierOperatorBase

Base class With simple implementation for NUFFT operator.

The NUFFT operation will be done sequentially and looped over coils and batches.

Parameters:
  • samples (NDArray) – The samples used by the operator.

  • shape (tuple) – The shape of the image space (in 2D or 3D)

  • density (bool or NDArray) – If True, the density compensation is estimated from the samples. If False, no density compensation is applied. If NDArray, the density compensation is applied from the array.

  • n_coils (int) – The number of coils.

  • smaps (NDArray) – The sensitivity maps.

  • raw_op (object) – An object implementing the NUFFT API. Ut should be responsible to compute a single type 1 /type 2 NUFFT.

Methods

__init__

adj_op

Non Cartesian MRI adjoint operator.

check_shape

Validate the shapes of the image or k-space data against operator shapes.

compute_density

Compute the density compensation weights and set it.

compute_smaps

Compute the sensitivity maps and set it.

data_consistency

Compute the gradient data consistency.

get_lipschitz_cst

Return the Lipschitz constant of the operator.

make_autograd

Make a new Operator with autodiff support.

make_deepinv_phy

Make a new DeepInv Physics with NUFFT operator.

make_linops

Create a Scipy Linear Operator from the NUFFT operator.

op

Non Cartesian MRI forward operator.

pinv_solver

Solves the linear system Ax = y.

update_samples

Update the samples of the NUFFT operator.

with_autograd

Return a Fourier operator with autograd capabilities.

with_off_resonance_correction

Return a new operator with Off Resonnance Correction.

Attributes

autograd_available

cpx_dtype

Return complex floating precision of the operator.

density

Density compensation of the operator.

dtype

Return floating precision of the operator.

img_full_shape

Full image shape with batch and coil dimensions.

interfaces

ksp_full_shape

Full kspace shape with batch and coil dimensions.

n_batchs

Number of coils for the operator.

n_coils

Number of coils for the operator.

n_samples

Return the number of samples used by the operator.

ndim

Number of dimensions in image space of the operator.

norm_factor

Normalization factor of the operator.

samples

Return the samples used by the operator.

shape

Shape of the image space of the operator.

smaps

Sensitivity maps of the operator.

uses_density

Return True if the operator uses density compensation.

uses_sense

Return True if the operator uses sensitivity maps.

backend

available

Examples using mrinufft.operators.base.FourierOperatorSimple#

Minimal example script

Minimal example script
op(data, ksp=None)[source]#

Non Cartesian MRI forward operator.

Parameters:
  • data (NDArray)

  • space. (The uniform (2D or 3D) data in image)

Return type:

Results array on the same device as data.

Notes

this performs for every coil ell: ..math:: mathcal{F}mathcal{S}_ell x

adj_op(coeffs, img=None)[source]#

Non Cartesian MRI adjoint operator.

Parameters:

coeffs (np.array or GPUArray)

Return type:

Array in the same memory space of coeffs. (ie on cpu or gpu Memory).

data_consistency(image_data, obs_data)[source]#

Compute the gradient data consistency.

This mixes the op and adj_op method to perform F_adj(F(x-y)) on a per coil basis. By doing the computation coil wise, it uses less memory than the naive call to adj_op(op(x)-y)

Parameters:
  • image (array) – Image on which the gradient operation will be evaluated. N_coil x Image shape is not using sense.

  • obs_data (array) – Observed data.