[yt-users] issue with wx python and matplotlib

Matthew Turk matthewturk at gmail.com
Wed Jun 2 12:44:32 PDT 2010


Hi Eric,

I haven't seen this before, but it is a puzzler -- wx is famous for
having multiple versions concurrently instaleld, however, so I guess
it's not completely surprising.  It might be as simple as looking at
"import wx;print wx,wx.__version__" to see what it's importing.  I'd
recommend that you switch off the wx backend in Matplotlib.  There are
a couple ways to do this:

1)
import matplotlib;matplotlib.use("Agg")

2)
edit ~/.matplotlibrc and set backend to agg.

3)
launch python with -dAgg

-Matt

On Wed, Jun 2, 2010 at 12:41 PM, Eric Hallman <hallman13 at gmail.com> wrote:
> Hello,
>  I am having a problem with yt on ubuntu 9.10 that I haven't seen before,
> wondering if anyone else has this error.  I have wxPython 2.8.10 installed,
> so the error message makes no sense to me.  Thanks for any help.
>
> Python 2.6.3 (r263:75183, Jan 29 2010, 11:07:13)
> [GCC 4.4.1] on linux2
> Type "help", "copyright", "credits" or "license" for more information.
>>>> from matplotlib.pyplot import *
> Traceback (most recent call last):
>  File "<stdin>", line 1, in <module>
>  File
> "/home/hallman/yt/yt-unknown/lib/python2.6/site-packages/matplotlib/pyplot.py",
> line 78, in <module>
>    new_figure_manager, draw_if_interactive, show = pylab_setup()
>  File
> "/home/hallman/yt/yt-unknown/lib/python2.6/site-packages/matplotlib/backends/__init__.py",
> line 25, in pylab_setup
>    globals(),locals(),[backend_name])
>  File
> "/home/hallman/yt/yt-unknown/lib/python2.6/site-packages/matplotlib/backends/backend_wxagg.py",
> line 23, in <module>
>    import backend_wx    # already uses wxversion.ensureMinimal('2.8')
>  File
> "/home/hallman/yt/yt-unknown/lib/python2.6/site-packages/matplotlib/backends/backend_wx.py",
> line 137, in <module>
>    raise ImportError(missingwx)
> ImportError: Matplotlib backend_wx and backend_wxagg require wxPython >=2.8
>>>>
>
> Eric Hallman
> Google Voice: (774) 469-0278
> hallman13 at gmail.com
>
>
>
>
> _______________________________________________
> yt-users mailing list
> yt-users at lists.spacepope.org
> http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
>



More information about the yt-users mailing list