Are there any plans for path simplification in any of the non-agg backends? When plotting large numbers of data points (~50k upwards in my case) using the ps backend the resulting file are rather large (several MB). More of a concern is that they take a very long time (~5 minutes) to render with ghostscript on a modern computer with obvious negative implications if sending to a postscript printer / including in publication graphics.
I've added some _very_ simple path simplification to backend_ps.py, which is sufficient for my usage (see attached diff - against 0.98pre, rev 5075). Its pretty ugly though with an arbitrary delta value for determining whether it is safe to skip a point, and a boolean switch to turn it on & off, both currently as module-level variables.
If there is enough interest, and I was pointed in the direction of the necessary info I could try and clean it up a bit for potential inclusion.
I'd need to know the following:
Is the backend itself the best/preferred place to be doing path simplification?
What would be the best method of doing the configuration (turning on/off, setting delta)?
It would obviously be desirable to automagically select a reasonable delta value - although this is potentially difficult as the resulting graph can be arbitrarily scaled - any ideas?
best wishes,
David
Win a MacBook Air or iPod touch with Yahoo!7. http://au.docs.yahoo.com/homepageset
backend_ps.py.diff (590 Bytes)