0

I created a virtual environment and installed scikitimage but when i use jupyter notebook it says no modules named skimage.

I installed scikitimage without using virtual enviroment but still jupyter can't find it.

from skimage import color, io
    def load(image_path):

        out = image_path

        out = skimage.io.imread(image_path)
        pass


    image1 = load(image1_path)

NameError                                 Traceback (most recent call last)
<ipython-input-3-08b9c4b0aed1> in <module>
----> 1 image1 = load(image1_path)
      2 image2 = load(image2_path)
      3 
      4 display(image1)
      5 display(image2)

~\Suleman\imageOperations.py in load(image_path)
     21     ### YOUR CODE HERE
     22     # Use skimage io.imread
---> 23     out = skimage.io.imread(image_path)
     24     pass
     25     ### END YOUR CODE

NameError: name 'skimage' is not defined
suleman butt
  • 11
  • 1
  • 5

2 Answers2

1
  1. first of all you need to uninstall scikit-image.Then

  2. install it via shell/command prompt:

    pip install scikit-image

  3. If you are running Anaconda or miniconda, open anaconda prompt then run this

    conda install -c conda-forge scikit-image

  4. if these steps aren't working upgrade your pip using

    python -m pip install –upgrade pip

  5. then follow again from step 1 to 3 that I have mentioned

If these aren't work uninstall scikit-image from both pip and conda then try this in anaconda prompt

  1. conda config --add channels conda-forge
  2. conda install scikit-image
  3. conda search scikit-image --channel conda-forge
Community
  • 1
  • 1
Kalana
  • 5,631
  • 7
  • 30
  • 51
  • uninstall `scikit-image` again and run this command in anaconda prompt `conda install scikit-image -c scikit-image` hope it will work – Kalana Sep 24 '19 at 14:00
  • If this isn't work. I have edited my answer.Please try that new one – Kalana Sep 24 '19 at 14:08
0
  1. Open CMD (the command prompt)
  2. Type pip install scikit-image in the CMD window
  3. Type py in the CMD window
  4. Type import skimage
  5. Go back to your Jupyter notebook for image processing issues
ChrisGPT was on strike
  • 127,765
  • 105
  • 273
  • 257