ENH: FILMGLS gifti output support in surface mode #3652
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
Fixes # .
FILMGLS is an interface for the FSL utility (film_gls) that fits GLM models to fMRI data. Most of FSL is only compatible with NIFTI files and NIFTI variants (e.g. NIFTI_GZ), but modern versions of film_gls in particular support gifti processing and output .func.gii files if a surface mode argument is included when invoking film_gls. Surface mode selection is supported by nipype but cannot be used in nipype workflows due to automated substitution of supported extensions for FSL outputs. With most FSL utilities the extension used to specify output files on the command line automatically selects the output format FSL uses, but film_gls in surface mode produces *.func.gii file in spite of this substitution. When workflow nodes downstream of FILMGLS then attempt to use the outputs of a FILMGLS node they're given the wrong filenames, namely files with NIFTI extensions rather than GIFTI extensions. This produces an error because such files do not exist. This enhancement addresses this issue in two ways.