在python发行版之外使用python库

时间:2016-08-29 11:35:11

标签: python scikit-learn anaconda

我已经通过Anaconda发行版安装了Python 2.7。现在我想使用Anaconda以外的一些包含的库。使用sklearn可以从Anaconda提示中正常工作。但是,在运行时

import sklearn

来自Rhino的.py脚本,我收到以下错误:

Message: No module named _check_build
___________________________________________________________________________
Contents of C:\Users\tsawen\AppData\Local\Continuum\Anaconda2\Lib\site-packages\sklearn\__check_build:
setup.py                  setup.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.

Traceback:
  line 31, in raise_build_error, "C:\Users\tsawen\AppData\Local\Continuum\Anaconda2\Lib\site-packages\sklearn\__check_build\__init__.py"
  line 46, in <module>, "C:\Users\tsawen\AppData\Local\Continuum\Anaconda2\Lib\site-packages\sklearn\__check_build\__init__.py"
  line 56, in <module>, "C:\Users\tsawen\AppData\Local\Continuum\Anaconda2\Lib\site-packages\sklearn\__init__.py"
  line 1, in <module>, "C:\Users\tsawen\AppData\Local\Temp\TempScript.py"

此前的一些讨论指出安装有问题。但是,由于在Anaconda中导入sklearn工作正常,Python似乎已正确安装。

任何人都可以帮助在分发之外使用包吗?

0 个答案:

没有答案