[Numpy-discussion] Silent Broadcasting considered harmful

Benjamin Root ben.root at ou.edu
Sun Feb 8 16:56:53 EST 2015


numpy is like Tesla. Everybody else has been doing it wrong...

Ben Root

On Sun, Feb 8, 2015 at 4:39 PM, Simon Wood <sgwoodjr at gmail.com> wrote:

>
>
> On Sun, Feb 8, 2015 at 4:24 PM, Stefan Reiterer <domors at gmx.net> wrote:
>
>> I don't think this is a good comparison, especially since broadcasting is
>> a feature not a necessity ...
>> It's more like turning off/on driving assistance.
>>
>> And as already mentioned: other matrix languages also allow it, but they
>> warn about it's usage.
>> This has indeed it's merits.
>>  *Gesendet:* Sonntag, 08. Februar 2015 um 22:17 Uhr
>> *Von:* "Charles R Harris" <charlesr.harris at gmail.com>
>> *An:* "Discussion of Numerical Python" <numpy-discussion at scipy.org>
>> *Betreff:* Re: [Numpy-discussion] Silent Broadcasting considered harmful
>>
>>
>> On Sun, Feb 8, 2015 at 2:14 PM, Stefan Reiterer <domors at gmx.net> wrote:
>>>
>>>   Yeah I'm aware of that, that's the reason why I suggested a warning
>>> level as an alternative.
>>> Setting no warnings as default would avoid breaking existing code.
>>>  *Gesendet:* Sonntag, 08. Februar 2015 um 22:08 Uhr
>>> *Von:* "Eelco Hoogendoorn" <hoogendoorn.eelco at gmail.com>
>>> *An:* "Discussion of Numerical Python" <numpy-discussion at scipy.org>
>>> *Betreff:* Re: [Numpy-discussion] Silent Broadcasting considered harmful
>>> > I personally use Octave and/or Numpy  for several years now and never
>>> ever needed braodcasting.
>>> But since it is still there there will be many users who need it, there
>>> will be some use for it.
>>>
>>>  Uhm, yeah, there is some use for it. Im all for explicit over
>>> implicit, but personally current broadcasting rules have never bothered me,
>>> certainly not to the extent of justifying massive backwards compatibility
>>> violations. Take It from someone who relies on broadcasting for every other
>>> line of code.
>>>
>>>
>>
>> It's how numpy works. It would be like getting into your car and being
>> warned that it has wheels.
>>
>> Chuck
>>   _______________________________________________ NumPy-Discussion
>> mailing list NumPy-Discussion at scipy.org
>> http://mail.scipy.org/mailman/listinfo/numpy-discussion
>>
>>
> I agree, I do not think this is a good comparison. All cars have wheels,
> there are no surprises there. This is more like a car that decides to do
> something completely different from everything that you learned about in
> driving school.
>
> I find the broadcasting aspect of Numpy a turn off. If I go to add a 1x3
> vector to a 3x1 vector, I want the program to warn me or error out. I don't
> want it to do something under the covers that has no mathematical basis or
> definition. Also, Octave may provide a warning, but Matlab errors
> out..."Matrix dimensions must agree". Which they must, at least in my world.
> _______________________________________________
>
>> NumPy-Discussion mailing list
>> NumPy-Discussion at scipy.org
>> http://mail.scipy.org/mailman/listinfo/numpy-discussion
>>
>>
>
> _______________________________________________
> NumPy-Discussion mailing list
> NumPy-Discussion at scipy.org
> http://mail.scipy.org/mailman/listinfo/numpy-discussion
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/numpy-discussion/attachments/20150208/8a1228c6/attachment.html>


More information about the NumPy-Discussion mailing list