Skip to content

Commit da9daad

Browse files
josephmjeoesteban
andcommitted
Update dmriprep/utils/images.py
Co-Authored-By: Oscar Esteban <[email protected]>
1 parent 2bfe9bb commit da9daad

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

dmriprep/utils/images.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,7 @@ def median(in_file, dtype=None, out_path=None):
6161

6262
hdr = img.header.copy()
6363
hdr.set_xyzt_units('mm')
64-
hdr.set_data_dtype(np.float32)
64+
if dtype is not None:
65+
hdr.set_data_dtype(dtype)
6566
nb.Nifti1Image(median_data, img.affine, hdr).to_filename(out_path)
6667
return out_path

0 commit comments

Comments
 (0)