Skip to content

Commit 60c3316

Browse files
committed
BF: fix use of renamed as_xyz_affable from merge
Nifti conversion was using ``as_xyz_affable`` which we have since renamed to ``as_xyz_image``.
1 parent 64cc26d commit 60c3316

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

nipy/io/nifti_ref.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,7 @@
143143
product as cm_product)
144144
from ..core.reference import spaces as ncrs
145145
from ..core.image.image import Image
146-
from ..core.image.image_spaces import as_xyz_affable
146+
from ..core.image.image_spaces import as_xyz_image
147147

148148

149149
XFORM2SPACE = {'scanner': ncrs.scanner_space,
@@ -273,7 +273,7 @@ def nipy2nifti(img, strict=None, fix0=False):
273273
for c in 'xyz':
274274
known_names[c] = c
275275
try:
276-
img = as_xyz_affable(img, known_names)
276+
img = as_xyz_image(img, known_names)
277277
except (ncrs.AxesError, ncrs.AffineError):
278278
# Python 2.5 / 3 compatibility
279279
e = sys.exc_info()[1]

nipy/io/tests/test_nifti_ref.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ def test_xyz_affines():
8888
aimg = copy_of(anatfile)
8989
adata = aimg.get_data()
9090
assert_array_equal(nipy2nifti(aimg).get_data(), adata)
91-
# For now, always error on 2D (this depends on as_xyz_affable)
91+
# For now, always error on 2D (this depends on as_xyz_image)
9292
assert_raises(NiftiError, nipy2nifti, aimg[:, :, 1])
9393
assert_raises(NiftiError, nipy2nifti, aimg[:, 1, :])
9494
assert_raises(NiftiError, nipy2nifti, aimg[1, :, :])

0 commit comments

Comments
 (0)