Commit 742a2dbc authored by Michiel Cottaar's avatar Michiel Cottaar
Browse files

Replace eddy_cuda with eddy

eddy_cuda is now deprecated
parent b476a1af
......@@ -22,13 +22,14 @@ estimation and eddy-current distortion correction.
import fsl.utils.assertions as asrt
from fsl.utils.deprecated import deprecated
from . import wrapperutils as wutils
@wutils.fileOrImage('imain', 'mask', 'field')
@wutils.fileOrArray('index', 'acqp', 'bvecs', 'bvals', 'field_mat')
@wutils.fslwrapper
def eddy_cuda(imain, mask, index, acqp, bvecs, bvals, out, cuda_version=None, **kwargs):
def eddy(imain, mask, index, acqp, bvecs, bvals, out, **kwargs):
"""Wrapper for the ``eddy_cuda`` command."""
valmap = {
......@@ -60,15 +61,15 @@ def eddy_cuda(imain, mask, index, acqp, bvecs, bvals, out, cuda_version=None, **
'bvals' : bvals,
'out' : out})
if cuda_version is None:
base_cmd = 'eddy_cuda'
else:
base_cmd = 'eddy_cuda' + str(cuda_version)
cmd = [base_cmd] + wutils.applyArgStyle('--=', valmap=valmap, **kwargs)
cmd = ['eddy'] + wutils.applyArgStyle('--=', valmap=valmap, **kwargs)
return cmd
@deprecated("3.11", "4.0", "eddy_cuda has been deprecated in favour of eddy, which will call the appropriate GPU or CPU version of eddy automatically.")
def eddy_cuda(*args, **kwargs):
eddy(*args, **kwargs)
@wutils.fileOrImage('imain', 'fout', 'iout', outprefix='out')
@wutils.fileOrArray('datain', outprefix='out')
@wutils.fslwrapper
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment