[Numpy-discussion] Change in behavior of np.concatenate for upcoming release

Han Genuit hangenuit at gmail.com
Fri Sep 14 18:25:05 EDT 2012


I think there is something wrong with the implementation.. I would
expect each incoming array in PyArray_ConcatenateFlattenedArrays to be
flattened and the sizes of all of them added into a one-dimensional
shape. Now the shape is two-dimensional, which does not make sense to
me. Also the requirement that all sizes must be equal between the
incoming arrays only makes sense when you want to stack them into a
two-dimensional array, which makes it unnecessarily complicated. The
difficulty here is to use PyArray_CopyAsFlat without having to
transform/copy each incoming array to the priority dtype, because they
can have different item sizes between them, but other than that it
should be pretty straightforward, imo.



More information about the NumPy-Discussion mailing list