Skip to content

Commit 77d75f8

Browse files
author
Victor Saase
committed
bug fixes
1 parent 1020c80 commit 77d75f8

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

nipype/workflows/dmri/fsl/utils.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -248,7 +248,7 @@ def hmc_split(in_file, in_bval, ref_num=0, lowbval=5.0):
248248

249249
volid = lowbs[0]
250250
if (isdefined(ref_num) and (ref_num < len(lowbs))):
251-
volid = [ref_num]
251+
volid = ref_num
252252

253253
if volid == 0:
254254
data = data[..., 1:]
@@ -265,8 +265,8 @@ def hmc_split(in_file, in_bval, ref_num=0, lowbval=5.0):
265265
out_mov = op.abspath('hmc_mov.nii.gz')
266266
out_bval = op.abspath('bval_split.txt')
267267

268-
hdr.set_data_shape(refdata.shape)
269268
refdata = data[..., volid]
269+
hdr.set_data_shape(refdata.shape)
270270
nb.Nifti1Image(refdata, im.get_affine(), hdr).to_filename(out_ref)
271271

272272
hdr.set_data_shape(data.shape)

0 commit comments

Comments
 (0)