"no display found. Using non-interactive Agg backend" in windows
See original GitHub issueDescribe the bug
First of all, great work with the impedance package. When I import Randles
from impedance.circuits
, it does not let me plot figures using matplotlib. The package is checking environment variable DISPLAY
in curcuits.py. I think windows (I am a window user) does not have a DISPLAY
environment variable, atleast mine does not. Thats why in circuits.py, line mpl.use('Agg')
is executed. There are some potential solutions to check for display in windows in this post
To Reproduce Steps to reproduce the behavior:
- Code which generates the error
import matplotlib.pyplot as plt
from impedance.circuits import Randles
plt.plot([1, 2, 3, 4])
plt.show()
....
- Full error info
I am getting the following message when I am importing
Randles
fromimpedance.circuits
.
no display found. Using non-interactive Agg backend
C:\Users\Sumbal\Documents\atom\data-analysis\antranik\controller\controller.py:193: UserWarning: Matplotlib is currently using agg, which is a non-GUI backend, so cannot show the figure.
plt.show()
Expected behavior This message above should not appear.
Additional context
- how I installed
pip install impedance==0.3.0
- operating system
windows 10
Issue Analytics
- State:
- Created 4 years ago
- Comments:5 (4 by maintainers)
Top Results From Across the Web
Generating a PNG with matplotlib when DISPLAY is undefined
The main problem is that (on your system) matplotlib chooses an x-using backend by default. I just had the same problem on one...
Read more >no display found. using non-interactive agg backend - You.com
Solution: matplotlib is currently using agg a non-gui backend Solution #1 . In matplotlib, to solve this error, install the GUI-backend tk i.e....
Read more >Backends — Matplotlib 3.6.2 documentation
The last, Agg, is a non-interactive backend that can only write to files. It is used on Linux, if Matplotlib cannot connect to...
Read more >From front to backend | Interactive Applications Using Matplotlib
Non-interactive backends are used to produce image files. There are backends to produce Postscript/EPS, Adobe PDF, and Scalable Vector Graphics (SVG) as well...
Read more >Matplotlib missing _tkinter - Build Environment
if os.environ.get('DISPLAY', '') == '': logging.warning('No display found. Using non-interactive Agg backend.') matplotlib.use('Agg').
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Update fixed the issue. Thanks a lot. 👍
This should be fixed in v0.3.1!
You can update with
pip install --upgrade impedance
. Please let me know if you still run into any issues 😄