Skip to content
Snippets Groups Projects
Commit a95870fe authored by Paul McCarthy's avatar Paul McCarthy :mountain_bicyclist:
Browse files

RF: Don't use nibabel get_data method

parent 6f9ecfa5
No related branches found
No related tags found
No related merge requests found
...@@ -12,6 +12,7 @@ Freesurfer ``mgh``/``mgz`` image files. ...@@ -12,6 +12,7 @@ Freesurfer ``mgh``/``mgz`` image files.
import os.path as op import os.path as op
import six import six
import numpy as np
import nibabel as nib import nibabel as nib
import fsl.utils.path as fslpath import fsl.utils.path as fslpath
...@@ -54,7 +55,7 @@ class MGHImage(fslimage.Image): ...@@ -54,7 +55,7 @@ class MGHImage(fslimage.Image):
name = 'MGH image' name = 'MGH image'
filename = None filename = None
data = image.get_data() data = np.asanyarray(image.dataobj)
xform = image.affine xform = image.affine
vox2surf = image.header.get_vox2ras_tkr() vox2surf = image.header.get_vox2ras_tkr()
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment