Christopher Barker <Chris.Barker <at> noaa.gov> writes:
>
> Christian Kristukat wrote:
>
> > I just checked that using PlotCanvas with numpy on a Celeron 2.8GHz, plotting
> > a
> > 100000 pts line takes 1.1 seconds. This seems reasonably fast.
>
> that's probably about as good as it gets, until we add the ability for
> wxPython to directly read the data in numpy arrays.
Do you really think a DC implementation that can handle ndarrays will make the
difference? What about the drawing itself? If the conversion ndarray->list is
really the bottleneck then this is one more argument to support Travi's quest on
getting a ndarray object into python.
···
---
You know, finding a bottleneck and improving speed can be quite
a complicate task.
Take the numpy package for exemple. For my calculations, I wrote all
the basic linear algebra stuff, matrix/vector definition, GaussJordan,
LU-decomposition... in pure Python. If I attempt to compare the speed
of my modules with numpy, one get sometimes good suprises.
Inverting 1000 times a 3x3 matrix with my module: 0.48 second
Inverting 1000 times a 3x3 matrix with numpy: 0.46 second
I will not attempt to generalize, depending on the test operations the
difference between "pure Python" modules and numpy vary broadly. Sometimes
"pure Python" wins, sometimes numpy wins.
Jean-Michel Fauth, Switzerland