scil_gradients_generate_sampling.py

usage: __main__.py [-h] [--eddy] [--duty]
                   [--no_b0_start NO_B0_START | --b0_every B0_EVERY]
                   [--b0_end] [--b0_value B0_VALUE] [--b0_philips]
                   (--bvals bvals [bvals ...] | --b_lin_max B_LIN_MAX | --q_lin_max Q_LIN_MAX)
                   (--fsl | --mrtrix) [-v [{DEBUG,INFO,WARNING}]] [-f]
                   nb_samples_per_shell [nb_samples_per_shell ...]
                   out_basename

Generate multi-shell gradient sampling with various processing options. Helps
accelerate gradients, optimize duty cycle and avoid artefacts.

Multi-shell gradient sampling is generated as in [1]. The bvecs are then
flipped to maximize spread for eddy current correction, b0s are interleaved at
equal spacing and the non-b0 samples are finally shuffled to minimize the total
diffusion gradient amplitude over a few TR.

Formerly: scil_generate_gradient_sampling.py

positional arguments:
  nb_samples_per_shell  Number of samples on each non b0 shell.
                        If multishell, provide a number per shell.
  out_basename          Gradient sampling output basename (don't include extension).
                        Please add options --fsl and/or --mrtrix below.

options:
  -h, --help            show this help message and exit
  --eddy                If set, we apply eddy optimization.
                        B-vectors are flipped to be well spread without symmetry.
  --duty                If set, we apply duty cycle optimization.
                        B-vectors are shuffled to reduce consecutive colinearity in the samples. [False]
  -v [{DEBUG,INFO,WARNING}]
                        Produces verbose output depending on the provided level.
                        Default level is warning, default when using -v is info.
  -f                    Force overwriting of the output files.

b0 acquisitions:
  Default if you add no option is to have a b0 at the start.

  --no_b0_start NO_B0_START
                        If set, do not add a b0 at the beginning.
  --b0_every B0_EVERY   Interleave a b0 every n=b0_every values. Starts after the first b0
                        (cannot be used with --no_b0_start). Must be an integer >= 1.
  --b0_end              If set, adds a b0 as last sample.
  --b0_value B0_VALUE   b-value of the b0s. [0.0]
  --b0_philips          If set, replaces values of b0s bvecs by existing bvecs for Philips handling.

Non-b0 acquisitions:
  --bvals bvals [bvals ...]
                        bval of each non-b0 shell.
  --b_lin_max B_LIN_MAX
                        b-max for linear bval distribution in *b*.
  --q_lin_max Q_LIN_MAX
                        b-max for linear bval distribution in *q*;
                        the square root of b-values will be linearly distributed..

Save as:
  --fsl                 Save in FSL format (.bvec/.bval).
  --mrtrix              Save in MRtrix format (.b).

References: [1] Emmanuel Caruyer, Christophe Lenglet, Guillermo Sapiro,
Rachid Deriche. Design of multishell gradient sampling with uniform coverage
in diffusion MRI. Magnetic Resonance in Medicine, Wiley, 2013, 69 (6),
pp. 1534-1540. <http://dx.doi.org/10.1002/mrm.24736>