Closed patnr closed 1 year ago
I would suggest TkAgg.
Tkinter is part of the standard library and I also found some online info:
So I think tk
is bundled with Python instead of Anaconda.
I tested with a very clean windows installation and tk
is already there.
With a clean conda environment in my Ubuntu system, tk is installed automatically with Python installation as well.
I'm not sure about the situation on OS X, but I hope it's the same there.
Good points for TkAgg. But it's painfully slow on my Mac with liveplotting. And prone to crash. Same goes for Qt5Agg actually (although it's really smooth on Linux). I think it's so bad that's it's almost unusable. I guess that's why Anaconda provides MacOSX by default.
Therefore I think we need to need to let it be platform dependent. It seems Anaconda figures this out quite well by itself. But I would still like to be able to guarantee that an interactive backend is installed. I will dig a little deeper into Anaconda to find out.
I now think that:
With cross-platform compatibility in mind, and the messy world/state of GUI mpl
backends, guaranteeing an interactive backend seems too complicated.
The installation instructions suggest using Jupyter, which will always provide an interactive backend. Most other relevant platforms and python distributions also tend to result in an interactive backend.
Thus, simply emitting a warning when we detect that mpl
is non-interactive (and non-inline) should be sufficient.
Right now QtAgg is among the "extras" of setup.py. That could mean an interactive matplotlib (mpl) backend might not get installed unless using
pip install -e .[Qt]
.However, I almost always seem to get an interactive backend installed anyways. My recent fresh install came with both MacOSX and TkAgg backends. I have a feeling it is because the environment was created with Anaconda, which provides some things to begin with, but I'm not sure.
So:
@yumengch Thoughts?