解决Pycharm中matplotlib画图出错问题(AttributeError: module 'matplotlib' has no attribute 'verbose')
最近在Linux中使用pycharm过程中使用matplotlib无法画图,总是提示错误
/usr/bin/python3. /home/leo/PycharmProjects/untitled1/Euler.py
Traceback (most recent call last):
File "/home/leo/PycharmProjects/untitled1/Euler.py", line , in <module>
import matplotlib.pyplot as plt
File "/usr/local/lib/python3.5/dist-packages/matplotlib/pyplot.py", line , in <module>
_backend_mod, new_figure_manager, draw_if_interactive, _show = pylab_setup()
File "/usr/local/lib/python3.5/dist-packages/matplotlib/backends/__init__.py", line , in pylab_setup
[backend_name], )
File "/home/leo/pycharm-2017.3.4/helpers/pycharm_matplotlib_backend/backend_interagg.py", line , in <module>
verbose = matplotlib.verbose
AttributeError: module 'matplotlib' has no attribute 'verbose'
根据提示出错的文件,进入最后一行提示的文件,进入文件,
from matplotlib.backend_bases import FigureManagerBase, ShowBase
from matplotlib.backends.backend_agg import FigureCanvasAgg
from matplotlib.figure import Figure HOST = 'localhost'
PORT = os.getenv("PYCHARM_MATPLOTLIB_PORT")
PORT = int(PORT) if PORT is not None else None
PORT = PORT if PORT != - else None
index = int(os.getenv("PYCHARM_MATPLOTLIB_INDEX", )) rcParams = matplotlib.rcParams
verbose = matplotlib.verbose
出错在verbose=matplotlib.verbose这里
因为在Python3中matplotlib中是Verbose
!!!!!!!!!!注意:大写的V
将其改过来,然后运行。问题完美解决。
解决Pycharm中matplotlib画图出错问题(AttributeError: module 'matplotlib' has no attribute 'verbose')的更多相关文章
- Pycharm安装package报错:AttributeError: module 'pip' has no attribute 'main'
Pycharm安装package报错:AttributeError: module 'pip' has no attribute 'main' 确认pip已经升级到目前最新版本了. 在网上搜寻后,解决 ...
- python中提取位图信息(AttributeError: module 'struct' has no attribute 'unstack')
前言 今天这篇博文有点意思,它是从一个例子出发,从而体现出在编程中的种种细节和一些知识点的运用.和从前一样,我是人,离成神还有几十万里,所以无可避免的出现不严谨的地方甚至错误,请酌情阅读. 0x00 ...
- 解决:pipenv shell报错:AttributeError: 'module' object has no attribute 'run'
利用pipenv shell切换到虚拟环境时,显示报错:AttributeError: 'module' object has no attribute 'run' 可以看到是d:\program\p ...
- matplotlib显示AttributeError: 'module' object has no attribute 'verbose'
解决办法:file-settings-tools-python scientific,将show plots in toolwindow前面的对号去掉即可.
- [已解决]pycharm报错:AttributeError: module 'pip' has no attribute 'main'
> 更新pip后,pycharm更新模块报错,经过一番查找,现提供两种解决办法. 报错片段信息如下: AttributeError: module 'pip' has no attribute ...
- python文件名不要跟模块名相同,报错AttributeError: 'module' object has no attribute 'Differ'
python中的文件都会生成pyc文件,包括模块也是这样,所以调用模块的时候,实际上会调用模块.pyc文件:在这个前提下,如果将文件名命名成跟模块名一样,在同一目录下就会生成一个跟模块名一样的pyc文 ...
- AttributeError: module 'matplotlib' has no attribute 'verbose' (pycharm中使用matplotlib 2.2.0的坑)
AttributeError: module 'matplotlib' has no attribute 'verbose' 环境信息 本地系统:win10 本地开发环境:python(3.6.3), ...
- python中引入包的时候报错AttributeError: module 'sys' has no attribute 'setdefaultencoding'解决方法?
python中引入包的时候报错:import unittestimport smtplibimport timeimport osimport sysimp.reload(sys)sys.setdef ...
- 【pycharm】pycharm上安装tensorflow,报错:AttributeError: module 'pip' has no attribute 'main' 解决方法
pycharm上安装tensorflow,报错:AttributeError: module 'pip' has no attribute 'main' 解决方法 解决方法: 在pycharm的安装目 ...
随机推荐
- python学习【第八篇】python模块
模块与包 模块的概念 在python中一个.py文件就是一个模块. 使用模块可以提高代码的可维护性. 模块分为三种: python标准库 第三方模块 自定义模块 模块的导入方法 1.import语句 ...
- Codeforces Round #324 (Div. 2) (快速判断素数模板)
蛋疼的比赛,当天忘了做了,做的模拟,太久没怎么做题了,然后C题这么简单的思路却一直卡到死,期间看了下D然后随便猜了下,暴力了下就过了. A.找一个能被t整除的n位数,那么除了<=10以外,其他都 ...
- IDEA : Git Pull Failed 解决(IDEA中使用stash功能)
一.问题: 本地要commit代码,commit之前需pull代码,但pull提示冲突.如下 Git Pull Failed Your local changes would be overwritt ...
- 将方法定义在prototype上的好处
通常js类定义和使用的是这样的: var Class=function(){}; Class.prototype.sharedFn=function(){}; var instanceA=new Cl ...
- linux下tmp目录里很多php开头的文件
cd /tmp; ll -ash; 51M -rw------- 1 nginx nginx 51M Sep 17 09:33 php3p7FPA 51M -rw------- 1 nginx ngi ...
- VS的编译选项
转载下,对于VS的编译选项介绍蛮清楚的!! 1. 静态链接库.动态链接库.CRT.STL 我们要到一个函数,要么是需要该函数的源代码,要么是知道该函数的声明并有该函数的实现,这里的“实现”又分为静态链 ...
- Hadoop “Name node is in safe mode” 错误解决方法
Hadoop 解除 "Name node is in safe mode" 运行hadoop程序时,有时候会报以下错误:org.apache.hadoop.dfs.SafeMode ...
- where VS having
where 和 having 的区别: WHERE 子句不能包含聚集函数: 因为试图用聚集函数判断那些行输入给聚集运算是没有意义的.相反,HAVING 子句总是包含聚集函数 hav ...
- 20170401 ABAP调用CIS webservice
问题: SAP abap SRM java 调webservice 不通, CIS java 这边的webservice 可以通, WHY? key:请求头,系统框架的问题, LF:因为请求头的 ...
- Python爬虫:爬取自己博客的主页的标题,链接,和发布时间
代码 # -*- coding: utf-8 -*- """ ------------------------------------------------- File ...