Hi,
I am trying to use matplotlib non-interactively but if I don't have
DISPLAY set then wx barfs even though I have tried forcing the backend,
etc..
eg..
[midget 16:51] ~/projects/beermon >python
Python 2.5.1 (r251:54863, Aug 14 2007, 11:27:14)
[GCC 3.4.6 [FreeBSD] 20060305] on freebsd6
Type "help", "copyright", "credits" or "license" for more information.
import pylab, matplotlib
matplotlib.use>>> matplotlib.use('agg')
fig = pylab.figure()
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/usr/local/lib/python2.5/site-packages/matplotlib/pylab.py", line 859, in figure
figManager = new_figure_manager(num, figsize=figsize, dpi=dpi, facecolor=facecolor, edgecolor=edgecolor, frameon=frameon, FigureClass=FigureClass, **kwargs)
File "/usr/local/lib/python2.5/site-packages/matplotlib/backends/backend_wxagg.py", line 134, in new_figure_manager
backend_wx.wxapp = wx.PySimpleApp()
File "/usr/local/lib/python2.5/site-packages/wx-2.6-gtk2-unicode/wx/_core.py", line 7791, in __init__
wx.App.__init__(self, redirect, filename, useBestVisual, clearSigInt)
File "/usr/local/lib/python2.5/site-packages/wx-2.6-gtk2-unicode/wx/_core.py", line 7700, in __init__
self._BootstrapApp()
File "/usr/local/lib/python2.5/site-packages/wx-2.6-gtk2-unicode/wx/_core.py", line 7352, in _BootstrapApp
return _core_.PyApp__BootstrapApp(*args, **kwargs)
SystemError: wxEntryStart failed, unable to initialize wxWidgets! (Is DISPLAY set properly?)
Same problem if I try Cairo.
I had a google but no luck, can anyone help me out?
Thanks.
···
--
Daniel O'Connor software and network engineer
for Genesis Software - http://www.gsoft.com.au
"The nice thing about standards is that there
are so many of them to choose from."
-- Andrew Tanenbaum
GPG Fingerprint - 5596 B766 97C0 0E94 4347 295E E593 DC20 7B3F CE8C