Skip to content

Commit 28d0bd1

Browse files
authored
Merge pull request #4 from mgxd/enh/antsupdate
RF+FIX: small tweaks
2 parents 91472ae + 03555b8 commit 28d0bd1

File tree

1 file changed

+3
-16
lines changed

1 file changed

+3
-16
lines changed

mindboggle/mindboggle123

Lines changed: 3 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -247,29 +247,24 @@ def mindboggle(subjectid, fsdir, antsdir, antsseg, out, prov, args,
247247
248248
"""
249249
import os
250-
251250
from nipype.interfaces.base import CommandLine
252251

253252
DATA = os.path.join(fsdir, subjectid)
254253
ants = os.path.join(antsdir, subjectid, antsseg)
255254

256255
all_args = ' '.join([DATA, '--out', out, '--ants', ants,
257256
'--working', os.getcwd()] +
258-
['--prov'] if prov else [] +
259-
[args])
257+
[args] + ['--prov'] if prov else [])
260258

261259
if num_threads > 1:
262260
all_args += ' --plugin MultiProc --plugin_args "dict(n_procs={0})"'.\
263261
format(num_threads)
264-
command = "{0} {1}".format('mindboggle', all_args)
265-
print(command)
266262

267-
from nipype import config
268263
cli = CommandLine(command='mindboggle')
269264
cli.inputs.args = all_args
270-
cli.cmdline
265+
command = cli.cmdline
266+
print(command)
271267
cli.run()
272-
273268
return command
274269

275270
# ----------------------------------------------------------------------------
@@ -280,14 +275,6 @@ def mindboggle(subjectid, fsdir, antsdir, antsseg, out, prov, args,
280275
# ----------------------------------------------------------------------------
281276
Mindboggle = Node(name='mindboggle',
282277
interface=Fn(function=mindboggle,
283-
input_names=['subjectid',
284-
'fsdir',
285-
'antsdir',
286-
'antsseg',
287-
'out',
288-
'prov',
289-
'args',
290-
'num_threads'],
291278
output_names=['command']))
292279
Mindboggle.inputs.subjectid = ID
293280
if args.skip_freesurfer:

0 commit comments

Comments
 (0)