Skip to content

4D minc2 image #448

@klarcher

Description

@klarcher

Hi,
Does nibabel read minc2 4D image ?
Below is the error I got when trying to upload it :

.../python2.7/site-packages/nibabel-2.0.0-py2.7.egg/nibabel/loadsave.pyc in load(filename, *_kwargs)
42 Image of guessed type
43 '''
---> 44 return guessed_image_type(filename).from_filename(filename, *_kwargs)
45
46

.../python2.7/site-packages/nibabel-2.0.0-py2.7.egg/nibabel/spatialimages.pyc in from_filename(klass, filename)
697 def from_filename(klass, filename):
698 file_map = klass.filespec_to_file_map(filename)
--> 699 return klass.from_file_map(file_map)
700
701 @classmethod

.../python2.7/site-packages/nibabel-2.0.0-py2.7.egg/nibabel/minc2.pyc in from_file_map(klass, file_map)
150 if holder.filename is None:
151 raise MincError('MINC2 needs filename for load')
--> 152 minc_file = Minc2File(h5py.File(holder.filename, 'r'))
153 affine = minc_file.get_affine()
154 if affine.shape != (4, 4):

.../python2.7/site-packages/nibabel-2.0.0-py2.7.egg/nibabel/minc2.pyc in init(self, mincfile)
62 for dim in self.dims:
63 if dim.spacing != b'regular
_':
---> 64 raise ValueError('Irregular spacing not supported')
65 self._spatial_dims = [name for name in self._dim_names
66 if name.endswith('space')]

ValueError: Irregular spacing not supported

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions