Error importing sklearn

前端 未结 3 1764
孤独总比滥情好
孤独总比滥情好 2021-01-07 15:41

Python version : 3.5.2
I getting started with machine learning and things... So I installed sklearn and some other packages form pip. All of them were able to be instal

相关标签:
3条回答
  • 2021-01-07 15:44

    Various things need to be checked:

    1. Check numpy, scipy installation versions.
    2. If they are correct then try to import numpy and scipy.
    3. If they getting imported correctly, then clear your temp(c:/users/username/Appdata/local/temp)folder. Restart the machine and try again.
    4. Still if doesn't work, then uninstall scipy, numpy , sklearn and reinstall the proper wheel files
    0 讨论(0)
  • 2021-01-07 15:50

    Download and install numpy+mkl file.

    Currently you might have installed only the numpy file.

    1. Go to: https://www.lfd.uci.edu/~gohlke/pythonlibs/#numpy

    2. Download the corresponding wheel file in which is suitable for your python installation

    3. pip install "/path_to_thefile/numpy-1.14.6+mkl-cp36-cp36m-win_amd64.whl"

    This should help you

    0 讨论(0)
  • 2021-01-07 16:01

    The following steps solved my problem :

    1. Uninstalling numpy, sklearn and scipy.
    2. Downloading numpy+mkl and scipy from here.
    3. Firstly installing numpy+mkl and then scipy.
    4. Installing sklearn from pip.
    0 讨论(0)
提交回复
热议问题