澳门太阳娱乐集团官网-太阳集团太阳娱乐登录

python pip install 出现错误OSError: [Errno 1] Operation n
分类:脚本专栏

$ pip install --upgrade numpy

减轻方案

1.  $ pip install --upgrade pip

2.  $ sudo pip install numpy --upgrade --ignore-installed  

3.  $ sudo pip install scipy --upgrade --ignore-installed  

4.  $ sudo pip install scikit-learn --upgrade --ignore-installed

化解办法:

$ pip install --upgrade pip$ sudo pip install numpy --upgrade --ignore-installed$ sudo pip install scipy --upgrade --ignore-installed$ sudo pip install scikit-learn --upgrade --ignore-installed
[Errno 1] Operation not permitted: '/tmp/pip-jI1Qog-uninstall/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/pytz'")]

万一还不能够缓和的话

Exception:Traceback (most recent call last): File "/Library/Python/2.7/site-packages/pip-7.1.0-py2.7.egg/pip/basecommand.py", line 223, in main status = self.run(options, args) File "/Library/Python/2.7/site-packages/pip-7.1.0-py2.7.egg/pip/commands/install.py", line 299, in run root=options.root_path, File "/Library/Python/2.7/site-packages/pip-7.1.0-py2.7.egg/pip/req/req_set.py", line 640, in install requirement.uninstall(auto_confirm=True) File "/Library/Python/2.7/site-packages/pip-7.1.0-py2.7.egg/pip/req/req_install.py", line 726, in uninstall paths_to_remove.remove(auto_confirm) File "/Library/Python/2.7/site-packages/pip-7.1.0-py2.7.egg/pip/req/req_uninstall.py", line 125, in remove renames(path, new_path) File "/Library/Python/2.7/site-packages/pip-7.1.0-py2.7.egg/pip/utils/__init__.py", line 314, in renames shutil.move File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/shutil.py", line 302, in move copy2(src, real_dst) File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/shutil.py", line 131, in copy2 copystat File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/shutil.py", line 103, in copystat os.chflags(dst, st.st_flags)OSError: [Errno 1] Operation not permitted: '/tmp/pip-1_nHcH-uninstall/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/numpy-1.8.0rc1-py2.7.egg-info'

设置机器学习的部分库的时候报错

2、重启Computer,不荒谬步向,张开【终端】输入 csrutil  status

结果抛出上面那几个那二个报告

Operation not permitted

谷歌后找到那一个建设方案

那是macosx 10.11 EI Capitan使用了Rootlees,可以知道为八个更加高阶段的木本珍贵,系统会默许锁定/system , /sbin , /usr那四个目录,

方今在弄机器学习的事体,然后看Macbook里面包车型客车Python库有一点旧,就用pip更新一下。

由此地点方法能够将以此保护关闭。

假定未有关闭,安装一些软件时会出现

1、重启计算机,按command+CRUISER步向复苏形式,点击菜单【实用工具】,张开【终端】,输入 csrutil disable

本文由澳门太阳娱乐集团官网发布于脚本专栏,转载请注明出处:python pip install 出现错误OSError: [Errno 1] Operation n

上一篇:布满式 NewSQL 数据库 TiDB 下一篇:没有了
猜你喜欢
热门排行
精彩图文