skbold.core.convert_to_mni module

convert2mni(file2transform, reg_dir, out_dir=None, interpolation='trilinear', suffix=None, overwrite=False, apply_warp=True)[source]

Transforms a nifti to mni152 (2mm) format. Assuming that reg_dir is a directory with transformation-files (warps) including example_func2standard warps, this function uses nipype’s fsl interface to flirt a nifti to mni format.

Parameters:
  • file2transform (str or list) – Absolute path to nifti file(s) that needs to be transformed
  • reg_dir (str) – Absolute path to registration directory with warps
  • out_dir (str) – Absolute path to desired out directory. Default is same directory as the to-be transformed file.
  • interpolation (str) – Interpolation used by flirt. Default is ‘trilinear’.
  • suffix (str) – What to append to name when converted (default : basename file2transform).
  • overwrite (bool) – Whether to overwrite already existing transformed file(s)
  • apply_warp (bool) – Whether to use the non-linear warp transform (if available).
Returns:

out_all – Absolute path(s) to newly transformed file(s).

Return type:

list