fslpy

The fslpy package is a collection of utilities and data abstractions used within FSL and by FSLeyes.

The top-level Python package for fslpy is called fsl. It is broadly split into the following sub-packages:

fsl.data

contains data abstractions and I/O routines for a range of FSL and neuroimaging file types. Most I/O routines use nibabel extensively.

fsl.utils

contains a range of miscellaneous utilities, including fsl.utils.path, fsl.utils.run, and fsl.utils.bids

fsl.scripts

contains a range of scripts which are installed as FSL commands.

fsl.transform

contains functions and classes for working with FSL-style linear and non-linear transformations.

fsl.version

simply contains the fslpy version number.

fsl.wrappers

contains Python functions which can be used to invoke FSL commands.

The fsl package provides the top-level Python package namespace for fslpy, and for other FSL python libaries. It is a native namespace package, which means that there is no fsl/__init__.py file.

Other libraries can use the fsl package namepace simply by also omitting a fsl/__init__.py file, and by ensuring that there are no naming conflicts with any sub-packages of fslpy or any other projects which use the fsl package namespace.