From: Darren D. <dar...@co...> - 2008-01-09 14:41:55
|
On Wednesday 09 January 2008 09:27:39 am Francesco Pretto wrote: > 2008/1/9, Charlie Moad <cw...@gm...>: > > You need to set a different backend in your matplotlibrc or specify it > > first. > > > > import matplotlib > > matplotlib.use('Agg') > > > > You can also run scripts passing the backend: > > > > python lab1_ex2.py -dAgg > > Oh, thanks. That really seems a RTFM... > > However, in linux i hadn't to select the backend, i just configure > "setup.cfg" to exclude backends and, after compiling, matplotlib was > running just fine choosing the right backend (gtk or gtkagg). Isn't > this a sign that matplotlib isn't able to detect the correct default > backend at compile time (at least on windows)? > > However, thanks again. As promised, now I'll try to be more autonomous ;-) setup.py attempts to select the appropriate backend for you, based on what backends were available at build time. That selection is written into the default matplotlibrc file, which resides in site-packages/matplotlib/mpl-data. If matplotlib finds another matplotlibrc file (for example, in the current working directory, in $HOME/.matplotlib, etc), then it will use those settings instead. I would guess that is the source of the problem. Darren |