ImportError: No module named matplotlib.pyplot

来源:互联网 发布:淘宝账号注册要求 编辑:程序博客网 时间:2024/05/06 06:11

转自:https://my.oschina.net/letiantian/blog/339901


sklearn的网站上不去,准备编译一下在github中的文档:

$ cd scikit-learn-master/doc$ make html



出现以下错误:

Exception occurred:  File "/home/sunlt/Downloads/scikit-learn-master/doc/sphinxext/gen_rst.py", line 850, in generate_file_rst    import matplotlib.pyplot as pltImportError: No module named matplotlib.pyplotThe full traceback has been saved in /tmp/sphinx-err-7pCJ3k.log, if you want to report the issue to the developers.



用pip安装:
$ sudo pip install matplotlib



依然是这个错误,

使用下面的命令安装,就没有问题了:
$ sudo apt-get install python-matplotlib

0 0
原创粉丝点击