簡體   English   中英

無法使用 pip 在 OS X El Capitan 上安裝 Matplotlib

[英]Can not install Matplotlib on OS X El Capitan with pip

當我嘗試通過鍵入“pip install matplotlib”來安裝 matplotlib 時

它不斷拋出以下錯誤消息。 誰能幫我?

  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pip/basecommand.py", line 211, in main
status = self.run(options, args)
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pip/commands/install.py", line 311, in run
root=options.root_path,
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pip/req/req_set.py", line 646, in install
**kwargs
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pip/req/req_install.py", line 803, in install
self.move_wheel_files(self.source_dir, root=root)
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pip/req/req_install.py", line 998, in move_wheel_files
isolated=self.isolated,
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pip/wheel.py", line 339, in move_wheel_files
clobber(source, lib_dir, True)
  File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pip/wheel.py", line 323, in clobber
os.utime(destfile, (st.st_atime, st.st_mtime))
OSError: [Errno 1] Operation not permitted: '/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages/pytz/__init__.py'

我正在使用 OS X El Captain 並且遇到了同樣的問題。 我用了 :-

conda install -c conda-forge matplotlib=1.5.2 

Matplot lib 已安裝並且沒有導入錯誤。 但是仍然存在與 pyplot 相關的錯誤,我猜這更多是 OS X El Captain 兼容性問題。

您可以在此處找到與錯誤相關的更多信息,也可以幫助我解決它:-

ipython/pylab/matplotlib安裝初始化報錯

sudo pip install matplotlib

給我解決!

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM