[Numpy-discussion] VIGRA, NumPy and Fortran-order (again)
Pauli Virtanen
pav+sp at iki.fi
Fri Jul 17 16:15:31 EDT 2009
On 2009-07-17, Hans Meine <meine at informatik.uni-hamburg.de> wrote:
[clip]
> As discussing in-depth in [1], numpy does not support Fortran order very well.
> First, there are performance issues, but even more important: the order is not
> preserved when performing simple operations. :-(
[clip]
> The specs would be: preserve the *ordering* of the strides (i.e. we're using
> mixed-order for RGB images to be able to write image[x, y] = (r, g, b)), and
> in the case of multiple input arguments, use the same rules (i.e. array
> priority) as for the output type determination.
>
> If I understood Travis' comments in the above-mentioned thread [1] correctly,
> this would already fix some of the performance issues along the way (since it
> would suddenly allow the use of special, optimized code paths).
I was wondering about this too, when working on improving the
cache coherency of the reduction operations. Also these would be
more efficient if the striding of the output array could be
chosen freely.
I wonder if it would be OK to make this change...
--
Pauli Virtanen
More information about the NumPy-Discussion
mailing list