The pdf backend rely on the "tell" method of a given file object,
which (I think) is not supported by stdout.
As a workaround, you may use StringIO.
from cStringIO import StringIO
outs = StringIO()
plt.savefig(outs, format='pdf')
print os.getvalue()
Regards,
-JJ
On Fri, Oct 1, 2010 at 8:59 PM,
hi !
i would like to write a server side python script that generate .pdf
documents.
for the moment i have Python 2.7 installed server side
and matplolib installed server side too.
A simple script that create a simple plot and generate a .png picture
works.
this is the script i use :
#-