ok thanks a lot. Safe code is often better than over-smart code, so I
would line up with Charles here. There is too much potential for
ambiguity in expected behavior.
Johann
On 08/30/2011 09:06 PM, Robert Kern wrote:
> On Tue, Aug 30, 2011 at 13:58, Johann Cohen-Tanugi
> wrote:
>> I am not sur
On Tue, Aug 30, 2011 at 13:58, Johann Cohen-Tanugi
wrote:
> I am not sure I follow : is the problem the coerce-sequences-to-ndarrays
> behavior, or is it the fact that it applies to division and not
> multiplication?
> I thought the second situation is the more problematic.
> Anyway, you seem to t
I am not sure I follow : is the problem the coerce-sequences-to-ndarrays
behavior, or is it the fact that it applies to division and not
multiplication?
I thought the second situation is the more problematic.
Anyway, you seem to take it as a bug, should I file a ticket somewhere?
thanks,
johann
On Tue, Aug 30, 2011 at 09:52, Charles R Harris
wrote:
>
> On Tue, Aug 30, 2011 at 8:33 AM, Johann Cohen-Tanugi
> wrote:
>>
>> I have numpy version 1.6.1 and I see the following behavior :
>>
>> In [380]: X
>> Out[380]: 1.0476157527896641
>>
>> In [381]: X.__class__
>> Out[381]: numpy.float64
>>
2011/8/30 Charles R Harris
>
>
> On Tue, Aug 30, 2011 at 8:33 AM, Johann Cohen-Tanugi <
> johann.cohentan...@gmail.com> wrote:
>
>> I have numpy version 1.6.1 and I see the following behavior :
>>
>> In [380]: X
>> Out[380]: 1.0476157527896641
>>
>> In [381]: X.__class__
>> Out[381]: numpy.float6
On Tue, Aug 30, 2011 at 8:33 AM, Johann Cohen-Tanugi <
johann.cohentan...@gmail.com> wrote:
> I have numpy version 1.6.1 and I see the following behavior :
>
> In [380]: X
> Out[380]: 1.0476157527896641
>
> In [381]: X.__class__
> Out[381]: numpy.float64
>
> In [382]: (2,3)*X
> Out[382]: (2, 3)
>
I have numpy version 1.6.1 and I see the following behavior :
In [380]: X
Out[380]: 1.0476157527896641
In [381]: X.__class__
Out[381]: numpy.float64
In [382]: (2,3)*X
Out[382]: (2, 3)
In [383]: (2,3)/X
Out[383]: array([ 1.90909691, 2.86364537])
In [384]: X=float(X)
In [385]: (2,3)/X