cartesian

Create sampling patterns for Cartesian k-space trajectories.

mr_utils.sim.traj.cartesian.cartesian_gaussian(shape, undersample=(0.5, 0.5), reflines=20)[source]

Undersample in Gaussian pattern.

Parameters:
  • shape (tuple) – Shape of the image to be sampled.
  • undersample (tuple, optional) – Undersampling factor in x and y (0 < ux, uy <= 1).
  • reflines (int, optional) – Number of lines in the center to collect regardless.
Returns:

mask – Boolean mask of sample locations on Cartesian grid.

Return type:

array_like

Raises:

AssertionError – If undersample factors are outside of interval (0, 1].

mr_utils.sim.traj.cartesian.cartesian_pe(shape, undersample=0.5, reflines=20)[source]

Randomly collect Cartesian phase encodes (lines).

Parameters:
  • shape (tuple) – Shape of the image to be sampled.
  • undersample (float, optional) – Undersampling factor (0 < undersample <= 1).
  • reflines (int, optional) – Number of lines in the center to collect regardless.
Returns:

mask – Boolean mask of sample locations on Cartesian grid.

Return type:

array_like

Raises:

AssertionError – If undersample factor is outside of interval (0, 1].