Should wcsaxes import trigger matplotlib.pyplot import?
See original GitHub issueI see that at the moment
python -c 'import astropy.visualization.wcsaxes'
triggers a matplotlib.pyplot
import and a GUI window popping up.
@astrofrog - Is this intentional? Is it possible / wouldn’t it be better to avoid this?
What if there’s library code or pipeline scripts that wants to import astropy.visualization.wcsaxes
, but doesn’t want to import matplotlib.pyplot
and all the stuff that entails (like setting a backend and by default popping up a GUI window)?
Issue Analytics
- State:
- Created 7 years ago
- Comments:12 (12 by maintainers)
Top Results From Across the Web
Making plots with world coordinates (WCSAxes) — Astropy v5.2
Getting started¶. The following is a very simple example of plotting an image with the WCSAxes package: import matplotlib.pyplot ...
Read more >Event handling and picking — Matplotlib 3.6.2 documentation
On the button release event, just reset all the button press data you stored as None. Here is the solution: import numpy as...
Read more >Plotting in sunpy — SunPy 4.1.0 documentation
import matplotlib.pyplot as plt plt.plot(range(10), ... When you create a plot with peek or plot , sunpy will use astropy.visualization.wcsaxes to represent ...
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 Free
Top 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
http://matplotlib.org/faq/usage_faq.html#non-interactive-example
😃
Ah, I see there’s #5684 by @astrofrog already. 👍