1

I updated my mac OS system to El Capitan two days ago after its release. However, since then I saw the following error when I tried to import cvxopt (which is working well previously in Yosemite OS.) This error persists even after I reinstall anaconda as well as cvxopt. I am not sure if this is a problem from the OS, anaconda or cvxopt itself. Can anyone help me on this problem? Thanks a lot.

---------------------------------------------------------------------  ------
NameError                                 Traceback (most recent call      last)
<ipython-input-4-14abf1b564a4> in <module>()
----> 1 import cvxopt

/Applications/anaconda/lib/python2.7/site-         packages/cvxopt/__init__.pyc in <module>()
    240         return +reduce(base.ediv, args)
    241 
--> 242 base.normal, base.uniform = normal, uniform
    243 base.setseed, base.getseed = setseed, getseed
    244 base.mul, base.div = mul, div

NameError: name 'base' is not defined
4

1 回答 1

1

我有同样的问题。这对我有用(尽管我远非专家):

  1. 从系统中卸载 cvxopt(使用 anaconda 或 pip)
  2. 将 xcode 和命令行工具升级到版本 7(这不是通过 el capitan 安装自动完成的,它不会出现在更新中)
  3. 从http://cvxopt.org/download/index.html下载 cvxopt 包并使用 anaconda python 构建它: python setup.py build 后跟 python setup.py install
于 2015-10-14T17:25:51.443 回答