From f963d7f929c9c3ebd6b96fb03db676afc04e6040 Mon Sep 17 00:00:00 2001 From: bpinsard Date: Wed, 24 Oct 2012 11:43:51 +0200 Subject: [PATCH 1/3] adding fsl6 options (bbr) --- nipype/interfaces/fsl/preprocess.py | 35 +++++++++++++++++++++++++++-- 1 file changed, 33 insertions(+), 2 deletions(-) diff --git a/nipype/interfaces/fsl/preprocess.py b/nipype/interfaces/fsl/preprocess.py index d3ccc9c28d..df572661e3 100644 --- a/nipype/interfaces/fsl/preprocess.py +++ b/nipype/interfaces/fsl/preprocess.py @@ -398,13 +398,13 @@ class FLIRTInputSpec(FSLCommandInputSpec): argstr='-datatype %s', desc='force output data type') cost = traits.Enum('mutualinfo', 'corratio', 'normcorr', 'normmi', - 'leastsq', 'labeldiff', + 'leastsq', 'labeldiff','bbr', argstr='-cost %s', desc='cost function') # XXX What is the difference between 'cost' and 'searchcost'? Are # these both necessary or do they map to the same variable. cost_func = traits.Enum('mutualinfo', 'corratio', 'normcorr', 'normmi', - 'leastsq', 'labeldiff', + 'leastsq', 'labeldiff','bbr', argstr='-searchcost %s', desc='cost function') uses_qform = traits.Bool(argstr='-usesqform', @@ -464,6 +464,37 @@ class FLIRTInputSpec(FSLCommandInputSpec): verbose = traits.Int(argstr='-verbose %d', desc='verbose mode, 0 is least') + # BBR options + wm_seg = File( + argstr='-wmseg %s', + desc='white matter segmentation volume needed by BBR cost function') + wmcoords = File( + argstr='-wmcoords %s', + desc='white matter boundary coordinates for BBR cost function') + wmnorms = File( + argstr='-wmnorms %s', + desc='white matter boundary normals for BBR cost function') + fieldmap = File( + argstr='-fieldmap %s', + desc='fieldmap image in rads/s - must be already registered to the reference image') + fieldmapmask = File( + argstr='-fieldmapmask %s', + desc='mask for fieldmap image') + pedir = traits.Int( + argstr='-pedir %d', + desc='phase encode direction of EPI - 1/2/3=x/y/z & -1/-2/-3=-x/-y/-z') + echospacing = traits.Float( + argstr='echospacing %f', + desc='value of EPI echo spacing - units of seconds') + bbrtype = traits.Enum( + 'signed', 'global_abs', 'local_abs', + argstr='-bbrtype %s', + desc='type of bbr cost function: signed [default], global_abs, local_abs') + bbrslope = traits.Float( + argstr='-bbrslope %f', + desc='value of bbr slope') + + class FLIRTOutputSpec(TraitedSpec): out_file = File(exists=True, From 2acc46e293d29de92384ad93083aebd151e78383 Mon Sep 17 00:00:00 2001 From: bpinsard Date: Wed, 24 Oct 2012 15:26:17 +0200 Subject: [PATCH 2/3] typo --- nipype/interfaces/fsl/preprocess.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nipype/interfaces/fsl/preprocess.py b/nipype/interfaces/fsl/preprocess.py index df572661e3..7c18b59c29 100644 --- a/nipype/interfaces/fsl/preprocess.py +++ b/nipype/interfaces/fsl/preprocess.py @@ -484,7 +484,7 @@ class FLIRTInputSpec(FSLCommandInputSpec): argstr='-pedir %d', desc='phase encode direction of EPI - 1/2/3=x/y/z & -1/-2/-3=-x/-y/-z') echospacing = traits.Float( - argstr='echospacing %f', + argstr='-echospacing %f', desc='value of EPI echo spacing - units of seconds') bbrtype = traits.Enum( 'signed', 'global_abs', 'local_abs', From d6195e9308fa7c35360e2d1f0bb37801456c95ed Mon Sep 17 00:00:00 2001 From: bpinsard Date: Thu, 28 Mar 2013 09:37:58 +0100 Subject: [PATCH 3/3] add min version for bbr options --- nipype/interfaces/fsl/preprocess.py | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/nipype/interfaces/fsl/preprocess.py b/nipype/interfaces/fsl/preprocess.py index d015e1a1ff..5c9de2341e 100644 --- a/nipype/interfaces/fsl/preprocess.py +++ b/nipype/interfaces/fsl/preprocess.py @@ -477,32 +477,32 @@ class FLIRTInputSpec(FSLCommandInputSpec): # BBR options wm_seg = File( - argstr='-wmseg %s', + argstr='-wmseg %s', min_ver='5.0.0', desc='white matter segmentation volume needed by BBR cost function') wmcoords = File( - argstr='-wmcoords %s', + argstr='-wmcoords %s', min_ver='5.0.0', desc='white matter boundary coordinates for BBR cost function') wmnorms = File( - argstr='-wmnorms %s', + argstr='-wmnorms %s', min_ver='5.0.0', desc='white matter boundary normals for BBR cost function') fieldmap = File( - argstr='-fieldmap %s', + argstr='-fieldmap %s', min_ver='5.0.0', desc='fieldmap image in rads/s - must be already registered to the reference image') fieldmapmask = File( - argstr='-fieldmapmask %s', + argstr='-fieldmapmask %s', min_ver='5.0.0', desc='mask for fieldmap image') pedir = traits.Int( - argstr='-pedir %d', + argstr='-pedir %d', min_ver='5.0.0', desc='phase encode direction of EPI - 1/2/3=x/y/z & -1/-2/-3=-x/-y/-z') echospacing = traits.Float( - argstr='-echospacing %f', + argstr='-echospacing %f', min_ver='5.0.0', desc='value of EPI echo spacing - units of seconds') bbrtype = traits.Enum( 'signed', 'global_abs', 'local_abs', - argstr='-bbrtype %s', + argstr='-bbrtype %s', min_ver='5.0.0', desc='type of bbr cost function: signed [default], global_abs, local_abs') bbrslope = traits.Float( - argstr='-bbrslope %f', + argstr='-bbrslope %f', min_ver='5.0.0', desc='value of bbr slope')