8000 fix:: replace scipy.misc with imageio and skimage by brendalf · Pull Request #4 · lzhbrian/metrics · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
< 8000 ul class="pagehead-actions flex-shrink-0 d-none d-md-inline" style="padding: 2px 0;">
  • Notifications You must be signed in to change notification settings
  • Fork 23
  • fix:: replace scipy.misc with imageio and skimage #4

    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

    Open
    wants to merge 2 commits into
    base: master
    Choose a base branch
    from

    Conversation

    brendalf
    Copy link
    Contributor
    @brendalf brendalf commented Jan 24, 2021

    As stated by @ML-Chen in #2, scipy.misc.imread and scipy.misc.imresize has been deprecated and is no longer available with recent versions of scipy.

    Instead, we can replace it with from PIL import Image.

    Solves #2.

    8000
    As state by @ML-Chen, `scipy.misc.imread` and `scipy.misc.imresize` has been deprecated and is no longer available with recent versions of scipy. 
    
    Instead, we can replace it with `from imageio import imread` and `from skimage.transform import resize`.
    
    This should close lzhbrian#2.
    @ludgerpaehler
    Copy link

    If I may suggest, I would rather directly replace it with Pillow i.e.

    from PIL import Image
    
    img = Image.open(file)
    img = np.array(img.resize((299, 299), resample=Image.BILINEAR))

    @brendalf
    Copy link
    Contributor Author
    brendalf commented Mar 2, 2021

    Done. Thank you, @ludgerpaehler

    @brendalf
    Copy link
    Contributor Author
    brendalf 7675 commented Aug 6, 2022

    Any news here? @lzhbrian

    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

    Successfully merging this pull request may close these issues.

    2 participants
    0