On 02/16/2011 10:13 PM, Maxim wrote: > But this workaround seems to prevent me from saving the fig in pdf (or > svg): > > File "/opt/SAGE/local/lib/python2.6/site-packages/matplotlib/ > dviread.py", line 727, in _register > assert encoding is None > AssertionError > > Here's the code: > # -*- coding: utf-8 -*- > from sage.all import * > import matplotlib as mpl > mpl.rcParams['text.usetex'] = True > plt = plot(sin, -pi, pi) > plt.axes_labels([ 'Valeur', r"\'{E}chantillon" ]) > save(plt,filename='/home/maxim/test.pdf') > > Same thing happens if I try to use pyplot instead. > Any clues or other ideas? > > Thanks, > Maxim
Try replacing `dviread.py' with the latest version from matplotlib's source code repository (svn trunk revision 8956 or later) and let me know if this fixes your issue. This smells of the issue I was having not so long ago. See here: https://groups.google.com/d/topic/sage-support/3UqXw-Bugx8/discussion -- To post to this group, send email to sage-support@googlegroups.com To unsubscribe from this group, send email to sage-support+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sage-support URL: http://www.sagemath.org