I'll spend some time with the profiler looking for some low
> hanging fruit.
God bless the profiler. It turns out over half of the time to display
this image is spent in the normalizer, which takes image data in an
arbitrary scale and maps into the unit interval
The normalizer handles a lot of special cases that you may not need.
In fact, your data may already be normalized. So you can write a
from pylab import *
def mynorm(X): # do nothing, it's already normalized
X = rand(1600,1600)
figimage(X, cmap=cm.hot, norm=mynorm)
This change alone gives me more than a 2x speedup. So with GTKAgg + a
custom normalizer (in this case a do nothing normalizer) you'll be
running 4-5 times faster than you were before, me thinks.
peds-pc311:~/python/projects/matplotlib> time python ~/test.py --numarray
1.650u 0.450s 0:02.13 98.5% 0+0k 0+0io 4746pf+0w
I'll keep digging through the profiler...