python的scikit-learn的安装

来源:互联网 发布:mac pro 强制关闭程序 编辑:程序博客网 时间:2024/05/22 09:03

昨天安装了一天。终于成功了,和大家分享下我的安装路程:

先说一下我的电脑是:windows 64位操作系统

python的版本:python 2.7.6  32位

 

之前没装scikit-learn的时候,对于一些基本的操作都是可行的。由于装scikit-learn我还装了easy_install(刚刚学习安装的人,可以了解下easy_install,网址:http://blog.chinaunix.net/uid-22476414-id-3427831.html)。

装了,easy_install 后看了CSDN中的其他人的网址,包括:

http://blog.csdn.net/caoeryingzi/article/details/20448223

http://www.cnblogs.com/zhuyp1015/archive/2012/07/17/2596495.html

http://blog.csdn.net/wbgxx333/article/details/12168675

(你可以上网百度下,很多关于这个的链接)

 

最后的结果,就是:

>>> import sklearn
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "C:\Python27\lib\site-packages\scikit_learn-0.14.1-py2.7-win32.egg\sklear
n\__init__.py", line 31, in <module>
    from . import __check_build
  File "C:\Python27\lib\site-packages\scikit_learn-0.14.1-py2.7-win32.egg\sklear
n\__check_build\__init__.py", line 46, in <module>
    raise_build_error(e)
  File "C:\Python27\lib\site-packages\scikit_learn-0.14.1-py2.7-win32.egg\sklear
n\__check_build\__init__.py", line 41, in raise_build_error
    %s""" % (e, local_dir, ''.join(dir_content).strip(), msg))
ImportError: DLL load failed: %1 不是有效的 Win32 应用程序。
___________________________________________________________________________
Contents of C:\Python27\lib\site-packages\scikit_learn-0.14.1-py2.7-win32.egg\sk
learn\__check_build:
setup.py                  setup.pyc                 _check_build.py
_check_build.pyc          _check_build.pyd          __init__.py
__init__.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.
>>>
这个scikit-learn不能用。

 

后来我上网找到,CSDN中的这个网址:

scikit-learn的软件链接:http://download.csdn.net/detail/database_zbye/5268640

然后,下载下来了它里面的三个库包,下载了它对应的python32位的然后,安装成功。

(希望,对你们有用)

0 0
原创粉丝点击