From: Sajec, M. T. <ms...@tq...> - 2004-05-05 18:13:22
|
>>>>> From: John Hunter [SMTP:jdh...@ac...] JDH,> This is something I haven't seen before. JDH,> What platform are you on: windows, linux, os x? Windows (NT4.0 and 2000) JDH,> I recommend the following JDH,> * make sure your hard drive isn't full JDH,> * open up a shell and change into a directory you have write JDH,> permission to and make sure you can write a file to that dir JDH,> * create the following test script JDH,> from matplotlib.matlab import * JDH,> plot([1,2,3]) JDH,> savefig('testfig') JDH,> * run this from the shell with JDH,> python testscript.py -dAgg JDH,> * see if the file testfig.png is created This works fine. The Agg backend work fine for me. JDH,> *see if the file testfig.png is created if so, JDH,> figure out what is different about what you are doing.... I've been using the WXAgg backend interactively from a WX based shell. So, basically I do the following: 1) plot([1,2,3]) and the plot appears 2) click the save icon on the displayed 3) save as "v53WXAggPlot.jpg" 4) No file is saved.... No errors given. I've also tried replacing steps 2-3 with: savefig(d:\v53WXAggPlot.jpg"), but had the same results So, decided to try idle -n with the TkAgg backend (interactive mode = On). 1) plot([1,2,3]), and the plot appears 3) click the save icon on the displayed plot 4) saved as "v53TkAggPlot.png" 5) It saved! I've also tried replacing steps 3-4 with: savefig("d:\v53TkAggPlot2.jpg"), and it saved too! So, finally I decided to go back to matplotlib 0.51 using a wx based shell w/the WX backend with interactive mode Off ( interactive wouldn't work for me in V0.51). 1) plot([1,2,3]) 2) show() and the plot appears 3) click the save icon on the displayed plot 4) saved as "v51WXPlot.jpg" 5) It saved! Could this be an issue isolated to the WXAgg backend in V0.51-3? Mike |