Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

'LazyITKModule' object has no attribute 'AnalyzeImageIO' #41

Closed
JourneyWoo opened this issue Sep 10, 2017 · 2 comments
Closed

'LazyITKModule' object has no attribute 'AnalyzeImageIO' #41

JourneyWoo opened this issue Sep 10, 2017 · 2 comments

Comments

@JourneyWoo
Copy link

from medpy.io import load
import SimpleITK
import vtk

image_data, image_header = load('/Users/N01-T2.mha')
print image_data.shape

Traceback (most recent call last):
File "", line 1, in
File "/Users/wuzhenglin/anaconda/lib/python2.7/site-packages/spyder/utils/site/sitecustomize.py", line 880, in runfile
execfile(filename, namespace)
File "/Users/wuzhenglin/anaconda/lib/python2.7/site-packages/spyder/utils/site/sitecustomize.py", line 94, in execfile
builtins.execfile(filename, *where)
File "/Users/wuzhenglin/Python_nice/SAL_LUNG/test.py", line 140, in
changeage()
File "/Users/wuzhenglin/Python_nice/SAL_LUNG/test.py", line 42, in changeage
image_data, image_header = load('/Users/wuzhenglin/Python_nice/SAL_BRAIN/brain_healthy_dataset/Normal001-T2.mha')
File "/Users/wuzhenglin/anaconda/lib/python2.7/site-packages/medpy/io/load.py", line 201, in load
raise err
medpy.core.exceptions.ImageLoadingError: Failes to load image /Users/wuzhenglin/Python_nice/SAL_BRAIN/brain_healthy_dataset/Normal001-T2.mha as
Itk/Vtk MetaImage (.mhd, .mha/.raw). Reason signaled by third-party module:
'LazyITKModule' object has no attribute 'AnalyzeImageIO'

@loli
Copy link
Owner

loli commented Sep 14, 2017

Which version of MedPy are you using? The one in the cheeseshop/PyPi does not support ITK4. Please load the newest version from GitHub, as this issue was fixed in #15.

It the problem persists, please write again.

@loli
Copy link
Owner

loli commented Sep 20, 2017

Closing since no follow-up came.

@loli loli closed this as completed Sep 20, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants