[Numpy-discussion] numpy all unexpected result (generator)

Warren Weckesser warren.weckesser at enthought.com
Tue Jan 31 17:25:33 EST 2012

On Tue, Jan 31, 2012 at 4:22 PM, Robert Kern <robert.kern at gmail.com> wrote:

> On Tue, Jan 31, 2012 at 22:17, Travis Oliphant <travis at continuum.io>
> wrote:
> > I also agree that an exception should be raised at the very least.
> >
> > It might also be possible to make the NumPy any, all, and sum functions
> > behave like the builtins when given a generator.  It seems worth
> exploring
> > at least.
> I would rather we deprecate the all() and any() functions in favor of
> the alltrue() and sometrue() aliases that date back to Numeric.

+1  (Maybe 'anytrue' for consistency?  (And a royal blue bike shed?))

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/numpy-discussion/attachments/20120131/f4af3d62/attachment.html>

More information about the NumPy-Discussion mailing list