Skip to content

Commit 774906a

Browse files
committed
Merge branch 'master' into enh/ETSConfigTookit
2 parents 9cafde5 + 1262955 commit 774906a

File tree

5 files changed

+11
-11
lines changed

5 files changed

+11
-11
lines changed

nipype/interfaces/dipy/preprocess.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,6 @@
2323
package_check('dipy', version='0.6.0')
2424
except Exception as e:
2525
have_dipy = False
26-
else:
27-
from dipy.align.aniso2iso import resample
28-
from dipy.core.gradients import GradientTable
2926

3027

3128
class ResampleInputSpec(TraitedSpec):
@@ -172,6 +169,7 @@ def resample_proxy(in_file, order=3, new_zooms=None, out_file=None):
172169
"""
173170
Performs regridding of an image to set isotropic voxel sizes using dipy.
174171
"""
172+
from dipy.align.aniso2iso import resample
175173

176174
if out_file is None:
177175
fname, fext = op.splitext(op.basename(in_file))

nipype/interfaces/freesurfer/tests/test_auto_Surface2VolTransform.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ def test_Surface2VolTransform_inputs():
1616
usedefault=True,
1717
),
1818
mkmask=dict(argstr='--mkmask',
19+
xor=['source_file'],
1920
),
2021
projfrac=dict(argstr='--projfrac %s',
2122
),
@@ -26,6 +27,7 @@ def test_Surface2VolTransform_inputs():
2627
source_file=dict(argstr='--surfval %s',
2728
copyfile=False,
2829
mandatory=True,
30+
xor=['mkmask'],
2931
),
3032
subject_id=dict(argstr='--identity %s',
3133
xor=['reg_file'],

nipype/interfaces/freesurfer/utils.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -390,7 +390,7 @@ def _gen_filename(self, name):
390390

391391
class Surface2VolTransformInputSpec(FSTraitedSpec):
392392
source_file = File(exists=True, argstr='--surfval %s',
393-
copyfile=False, mandatory=True,
393+
copyfile=False, mandatory=True, xor=['mkmask'],
394394
desc='This is the source of the surface values')
395395
hemi = traits.Str(argstr='--hemi %s', mandatory=True,
396396
desc='hemisphere of data')
@@ -404,7 +404,7 @@ class Surface2VolTransformInputSpec(FSTraitedSpec):
404404
template_file = File(exists=True, argstr='--template %s',
405405
desc='Output template volume')
406406
mkmask = traits.Bool(desc='make a mask instead of loading surface values',
407-
argstr='--mkmask')
407+
argstr='--mkmask', xor=['source_file'])
408408
vertexvol_file = File(name_template="%s_asVol_vertex.nii",
409409
desc=('Path name of the vertex output volume, which '
410410
'is the same as output volume except that the '

nipype/pipeline/plugins/ipython.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
IPython_not_loaded = False
1414
try:
1515
from IPython import __version__ as IPyversion
16-
from IPython.parallel.error import TimeoutError
16+
from ipyparallel.error import TimeoutError
1717
except:
1818
IPython_not_loaded = True
1919

@@ -47,7 +47,7 @@ class IPythonPlugin(DistributedPluginBase):
4747

4848
def __init__(self, plugin_args=None):
4949
if IPython_not_loaded:
50-
raise ImportError('IPython parallel could not be imported')
50+
raise ImportError('ipyparallel could not be imported')
5151
super(IPythonPlugin, self).__init__(plugin_args=plugin_args)
5252
self.iparallel = None
5353
self.taskclient = None
@@ -56,11 +56,11 @@ def __init__(self, plugin_args=None):
5656

5757
def run(self, graph, config, updatehash=False):
5858
"""Executes a pre-defined pipeline is distributed approaches
59-
based on IPython's parallel processing interface
59+
based on IPython's ipyparallel processing interface
6060
"""
6161
# retrieve clients again
6262
try:
63-
name = 'IPython.parallel'
63+
name = 'ipyparallel'
6464
__import__(name)
6565
self.iparallel = sys.modules[name]
6666
except ImportError:

nipype/pipeline/plugins/ipythonx.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,14 +22,14 @@ class IPythonXPlugin(DistributedPluginBase):
2222

2323
def __init__(self, plugin_args=None):
2424
if IPython_not_loaded:
25-
raise ImportError('IPython parallel could not be imported')
25+
raise ImportError('ipyparallel could not be imported')
2626
super(IPythonXPlugin, self).__init__(plugin_args=plugin_args)
2727
self.ipyclient = None
2828
self.taskclient = None
2929

3030
def run(self, graph, config, updatehash=False):
3131
"""Executes a pre-defined pipeline is distributed approaches
32-
based on IPython's parallel processing interface
32+
based on IPython's ipyparallel processing interface
3333
"""
3434
# retrieve clients again
3535
try:

0 commit comments

Comments
 (0)