我想在即将推出的项目中使用scikit-learn,我绝对无法安装它。我可以通过从源代码构建它们或通过pip安装其他软件包而不会出现问题。对于scikit-learn,我尝试在GitHub上克隆项目并通过pip安装但没有成功。有人可以帮忙吗?这是我的pip.log
:
Downloading/unpacking scikit-learn
Running setup.py egg_info for package scikit-learn
Warning: Assuming default configuration (scikits/learn/{setup_scikits.learn,setup}.py was not found)Warning: Assuming default configuration (sklearn/svm/tests/{setup_tests,setup}.py was not found)Appending scikits.learn configuration to
Ignoring attempt to set 'name' (from '' to 'scikits.learn')
Appending sklearn.check_build configuration to sklearn
Ignoring attempt to set 'name' (from 'sklearn' to 'sklearn.check_build')
Appending sklearn.svm.tests configuration to sklearn.svm
Ignoring attempt to set 'name' (from 'sklearn.svm' to 'sklearn.svm.tests')
blas_opt_info:
FOUND:
extra_link_args = ['-Wl,-framework', '-Wl,Accelerate']
define_macros = [('NO_ATLAS_INFO', 3)]
extra_compile_args = ['-faltivec', '-I/System/Library/Frameworks/vecLib.framework/Headers']
答案 0 :(得分:8)
安装SciPy Superpack或EPD以在OSX下一次性获取所有必需的依赖项。
答案 1 :(得分:3)
我遇到了this nice tutorial,只需几个简单的步骤就可以通过PIP安装它,如下所示:
(仅限大纲。有关详细信息,请访问作者页面。)
另请参阅作者页面上有关如何安装PIP和Virtualenv的评论。
答案 2 :(得分:2)
如果您使用Homebrew,那么这两个命令应该为您完成:
brew tap homebrew/python
brew install scipy
答案 3 :(得分:0)
您可以使用pip来安装scikit。