[Numpy-discussion] unique1d and asarray
Sun Jan 4 15:47:37 CST 2009
On Sun, Jan 4, 2009 at 15:44, Pierre GM <email@example.com> wrote:
> Currently, np.unique1d uses np.asarray to ensure the input is an
> array. The problem is that np.asarray transforms a MaskedArray into a
> regular ndarray, the missing information is lost and the result is not
> If we used np.asanyarray instead, subclasses are recognized properly,
> the mask is recognized by argsort and the result correct.
> Is there a reason why we use np.asarray instead of np.asanyarray ?
"I have come to believe that the whole world is an enigma, a harmless
enigma that is made terrible by our own mad attempt to interpret it as
though it had an underlying truth."
-- Umberto Eco
More information about the Numpy-discussion