On Fri, Mar 27, 2009 at 1:23 PM, Karen Tracey <kmtra...@gmail.com> wrote:
> > Yes, this change appears to fix the problem. I created a standalone script > to recreate the problem. The script starts several threads. Each thread > enters a loop generating a (different) png file. With the original > matplotlib code, the threads seem unable to complete 50 iterations without > the exception being raised. (I tried the script at least a dozen times, it > never finished successfully with 50 iterations. Usually failed before 5, > but once made it as high as 20, so I bumped it up to 50 and that seemed to > ensure it would fail before finishing). With the above change to make the > texd and _fontd caches per-instance, the script has finished successfully 4 > times. Seems pretty convincing evidence that it fixes the problem. > OK, I made this change to svn r7008. We probably do not gain *that much* by caching across renderers anyhow. > > > Also, make sure you have disabled usetex in matplotlibrc, since the use of >> the filesystem for caching the tex datafiles is probably not thread safe. >> My guess is that the font cache on the file system is not thread safe >> either, but this may only affect the first run of mpl after a clean install. >> > > Not sure what matplotlibrc is? I found a file > /usr/share/matplotlib/matplotlib.conf that has usetex set to False. Is that > it? If so I guess it's been disabled all along, this is not something I > have fiddled with. > matplotlib.conf is an experimental config that is no longer in use (but it won't hurt you to have it lying around). See http://matplotlib.sourceforge.net/users/customizing.html for details on the matplotlibrc file > > Understood, and I did make a standalone script (plus a set of pickle files > for the data to graph) to recreate it. I can zip them up and send them > somewhere, or open a ticket and attach it there, or whatever. Let me know > what would be most convenient/helpful. > No need for data files -- just use np.random.rand to make up some random data for plotting. That keeps things simple and small, and you can post the script to the list, and hopefully we can find a home for it in our unit tests. Thanks, JDH
------------------------------------------------------------------------------
_______________________________________________ Matplotlib-devel mailing list Matplotlib-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-devel