相关疑难解决方法(0)

"UserWarning: Matplotlib is currently using agg, which is a non-GUI backend, so cannot show the figure." when plotting figure with pyplot on Pycharm

I am trying to plot a simple graph using pyplot, e.g.:

import matplotlib.pyplot as plt
plt.plot([1,2,3],[5,7,4])
plt.show()
Run Code Online (Sandbox Code Playgroud)

but the figure does not appear and I get the following message:

UserWarning: Matplotlib is currently using agg, which is a non-GUI backend, so cannot show the figure.
Run Code Online (Sandbox Code Playgroud)

I saw in several places that one had to change the configuration of matplotlib using the following:

import matplotlib
matplotlib.use('TkAgg')
import matplotlib.pyplot as plt
Run Code Online (Sandbox Code Playgroud)

I did this, but then got an error message because it …

python matplotlib pycharm

34
推荐指数
10
解决办法
2万
查看次数

调试pycharm中的python代码

这个问题与类似.我正在尝试 使用以下配置调试pyethapp:

debug_app

入口点位于app.py中.没有被调试时代码运行正常,但是一旦我启动调试器,就抛出以下异常:

Failed to import scrypt. This is not a fatal error but does
mean that you cannot create or decrypt privkey jsons that use
scrypt

/usr/local/lib/python2.7/dist-packages/cffi/model.py:526: UserWarning: 'point_conversion_form_t' has no values explicitly defined; next version will refuse to guess which integer type it is meant to be (unsigned/signed, int/long)
  % self._get_c_name())
Traceback (most recent call last):
  File "/home/user/Utils/pycharm-community-2016.1/helpers/pydev/pydevd.py", line 1530, in <module>
    globals = debugger.run(setup['file'], None, None, is_module)
  File "/home/user/Utils/pycharm-community-2016.1/helpers/pydev/pydevd.py", line 937, …
Run Code Online (Sandbox Code Playgroud)

python debugging pycharm

14
推荐指数
1
解决办法
4349
查看次数

标签 统计

pycharm ×2

python ×2

debugging ×1

matplotlib ×1