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

AttributeError: module 'skimage' has no attribute 'measure' #5484

Closed
wusaifei opened this issue Jul 21, 2021 · 3 comments
Closed

AttributeError: module 'skimage' has no attribute 'measure' #5484

wusaifei opened this issue Jul 21, 2021 · 3 comments

Comments

@wusaifei
Copy link

According to the official website tutorial, pip and conda are installed. The installation result is successful, and you can import skimage, but skimage.measure will report an error. Test the 0.18.1, 0.17.2 and other versions.

@wusaifei
Copy link
Author

@sergeyk @rtack @zeroth @adamw523 Looking forward to your reply, thank you very much!

@jni
Copy link
Member

jni commented Jul 21, 2021

The submodules are not imported by default. This means you need to either:

import skimage.measure

result = skimage.measure.regionprops(...)  # for example

or

from skimage import measure

result = measure.regionprops(...)  # for example

After #5101 is merged, import skimage; skimage.measure.regionprops(...) will work. But not yet.

@jni jni closed this as completed Jul 21, 2021
@wusaifei
Copy link
Author

@jni Thank you very much for your reply! This means that in order to improve the loading speed of skimage, the default is not to load sub modules such as measure.

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