[Numpy-discussion] in the NA discussion, what can we agree on?

Nathaniel Smith njs at pobox.com
Thu Nov 3 15:44:06 EDT 2011

Hi Lluís,

On Thu, Nov 3, 2011 at 7:28 AM, Lluís <xscript at gmx.net> wrote:
> Well, maybe it's too low level, but I'd rather decouple the two concepts into
> two orthogonal properties that can be composed:
> * Destructiveness: whether the previous data value is lost whenever you assign a
>  "special" value.
> * Propagation: whether any of these "special" values is propagated or just
>  skipped when performing computations.
> I think we can all agree on the definition of these two properties (where
> bit-patters are destructive and masks are non-destructive), so I'd say that the
> first discussion is establishing whether to expose them as separate properties
> or just expose specific combinations of them:
> * MISSING: destructive + propagating
> * IGNORED: non-destructive + non-propagating

Thanks, that's an interesting idea that I'd forgotten about. I added a
link to your message to the "proposals" section, and to the list of
proposed solutions in point (3).

I'm tempted to respond in more depth, but I'm worried that if we start
digging into specific proposals like this right now then we'll start
going in circles again -- that's why I'm trying to establish some
common ground on what our goals are, so we have more of a basis for
comparing different ideas.

So obviously your suggestion of breaking things down into
finer-grained orthogonal features has merits in terms of simplicity,
elegance, etc. Before we get into those, though, I want to ask: do you
feel that the extra ability to have values that are
destructive+non-propagating and non-destructive+propagating is a major
*practical* benefit, or are you more motivated by the simplicity and
elegance, and the extra flexibility is just something kind of cool
that we'd get for free?

Or put another way, do you think that the MISSING and IGNORED concepts
are adequate to cover practical use cases, or do you have an example
where what's really wanted is say non-destructive + propagating? I can
see how it would work, but I don't think I'd ever use it, so I'm

-- Nathaniel

More information about the NumPy-Discussion mailing list