python sklearn机器学习库 安装 及 2个spyder的安装
来源:互联网 发布:baocms7.1完整源码 编辑:程序博客网 时间:2024/06/05 04:14
1、准备工作
安装sklearn之前,我们需要先安装numpy,scipy函数库。
Numpy下载地址:http://sourceforge.net/projects/numpy/files/NumPy
Scipy下载地址:http://sourceforge.net/projects/scipy/files/Scipy
下载对应本机的Python版本。
2、安装sklearn机器学习库
下载地址:https://github.com/scikit-learn/scikit-learn
下载压缩包之后,解该压缩包压缩。使用CMD进入sklearn文件夹,执行
python setup.py install
即安装完成。
3、报错解决
我们在导入sklearn时往往会报错。
- >>> import sklearn
- Traceback (most recent call last):
- File "<stdin>", line 1, in <module>
- File "sklearn/__init__.py", line 37, in <module>
- from . import __check_build
- File "sklearn/__check_build/__init__.py", line 46, in <module>
- raise_build_error(e)
- File "sklearn/__check_build/__init__.py", line 41, in raise_build_error
- %s""" % (e, local_dir, ''.join(dir_content).strip(), msg))
- ImportError: No module named _check_build
- ___________________________________________________________________________
- Contents of sklearn/__check_build:
- __init__.py __init__.pyc _check_build.c
- _check_build.pyx setup.py setup.pyc
- ___________________________________________________________________________
- It seems that scikit-learn has not been built correctly.
- If you have installed scikit-learn from source, please do not forget
- to build the package before using it: run `python setup.py install` or
- `make` in the source directory.
- If you have used an installer, please check that it is suited for your
- Python version, your operating system and your platform.
python27\Lib\site-packages\sklearn\utils\sparsefuncs.pyd
当我们遇到类似 “ImportError:cannot import name **”这样的问题时,我们运行
pip install -U scikit-learn
这样问题就解决了。。
2.在anaconda中安装2个spyder的指令
conda create -n py35 python=3.5
conda install -n py35 spyder
conda install -n py35 pyqt=4.10
Windows 64-bit中,我试了“conda install -n py2 spyder”, “py2”为我设置的第二环境!
好文章分享:https://foofish.net/compatible-py2-and-py3.html
1 0
- python sklearn机器学习库 安装 及 2个spyder的安装
- python sklearn 机器学习库的安装
- python sklearn机器学习库 安装
- 安装Python机器学习库sklearn
- 机器学习python库sklearn安装
- 安装sklearn机器学习库
- 安装sklearn机器学习库
- 安装Python的机器学习包Sklearn 出错解决方法
- python机器学习库sklearn与graphlab与opencv的安装
- 基于python的机器学习库Sklearn
- Python机器学习数据挖掘工具sklearn安装和使用
- 【python/机器学习】sklearn安装及其环境配置
- Anaconda Python安装,Spyder汉化及调试
- [机器学习]基于python的机器学习库Sklearn-01
- python中安装机器学习(sklearn)必要的包和模块
- Windows下安装Python机器学习相关的sklearn(scikit-learn)模块
- 【python机器学习】Win10+python3.5+numpy+matplotlib+scipy+sklearn的安装
- python如何安装spyder?
- Intellij idea插入表数据【在UI界面插入出错】
- Java + Spark SQL + Hive + Maven简单实现和异常问题
- 【OpenGL ES】OpenGL ES简介
- Maximum Depth of Binary Tree
- Javascript 数据直接量
- python sklearn机器学习库 安装 及 2个spyder的安装
- 程序设计基础(C)大作业——学籍管理系统(1)
- 【面试题】剑指offer03--判断一个数是否在一个二维数组中
- 推荐资源:sound-of-sorting-0.6.5.exe
- JavaScript简介
- js之【窗口事件和event对象】(有一个追踪鼠标定位的小栗子)
- anaconda下安装scrapy连接mysql
- D
- JAVA实现——单链表