[Numpy-discussion] view of recarray issue

Ondřej Čertík ondrej.certik at gmail.com
Mon Aug 20 15:40:10 EDT 2012


On Wed, Jul 25, 2012 at 10:29 AM, Jay Bourque <jay.bourque at continuum.io> wrote:
> I'm actively looking at this issue since it was my pull request that broke
> this (https://github.com/numpy/numpy/pull/350). We definitely don't want to
> break this functionality for 1.7. The problem is that even though indexing
> with a subset of fields still returns a copy (for now), it now returns a
> copy of a view of the original array. When you call copy() on a view, it
> copies the entire original structured array with the view dtype. A short
> term fix would be to "manually" create a proper copy to return similar to
> what _index_fields() did before my change, but since the idea is to
> eventually return the view instead of a copy, long term we need a way to do
> a proper copy of a structured array view that doesn't copy the unwanted
> fields.

This should be fixed for 1.7.0. However, I am going to release beta now,
and then see what we can do about this.

Ondrej



More information about the NumPy-Discussion mailing list