Robert wrote:
Neil Martinsen-Burrell wrote:
On 2009-09-07 07:11 , Robert wrote:
Is there a reason why ndarray truth tests (except scalars)
deviates from the convention of other Python iterables
list,array.array,str,dict,... ?
Furthermore there is a surprising strange exception for arrays
On 9/13/2009 7:46 AM, Robert wrote:
2 ways seem to be consistently Pythonic and logical: size
0; or any(a) (*); and the later option may be more 'numerical'.
Well, *there's* the problem.
As a user I have felt more than once that a
length based test, like other containers, would
be natural, so
On Sun, Sep 13, 2009 at 9:05 AM, Alan G Isaac ais...@american.edu wrote:
On 9/13/2009 7:46 AM, Robert wrote:
2 ways seem to be consistently Pythonic and logical: size
0; or any(a) (*); and the later option may be more 'numerical'.
Well, *there's* the problem.
As a user I have felt more than
On Sun, Sep 13, 2009 at 05:30, Robert kxrobe...@googlemail.com wrote:
Neil Martinsen-Burrell wrote:
On 2009-09-07 07:11 , Robert wrote:
Is there a reason why ndarray truth tests (except scalars)
deviates from the convention of other Python iterables
list,array.array,str,dict,... ?
Is there a reason why ndarray truth tests (except scalars)
deviates from the convention of other Python iterables
list,array.array,str,dict,... ?
Furthermore there is a surprising strange exception for arrays
with size 1 (!= scalars).
I often run into exceptions and unexpected bahavior like
On 2009-09-07 07:11 , Robert wrote:
Is there a reason why ndarray truth tests (except scalars)
deviates from the convention of other Python iterables
list,array.array,str,dict,... ?
Furthermore there is a surprising strange exception for arrays
with size 1 (!= scalars).
Historically,