Hi,

On Thu, Apr 16, 2015 at 3:19 PM, Neil Girdhar <[email protected]> wrote:
> Actually, looking at the docs, numpy.outer is *only* defined for 1-d
> vectors.  Should anyone who used it with multi-dimensional arrays have an
> expectation that it will keep working in the same way?
>
> On Thu, Apr 16, 2015 at 10:53 AM, Neil Girdhar <[email protected]>
> wrote:
>>
>> Would it be possible to deprecate np.outer's usage on non one-dimensional
>> vectors for a few versions, and then reintroduce it with definition np.outer
>> == np.multiply.outer?

I think the general idea is that

a) people often miss deprecation warnings
b) there is lots of legacy code out there, and
c) it's very bad if legacy code silently gives different answers in
newer numpy versions
d) it's not so bad if newer numpy gives an intelligible error for code
that used to work.

So, how about a slight modification of your proposal?

1) Raise deprecation warning for np.outer for non 1D arrays for a few
versions, with depraction in favor of np.multiply.outer, then
2) Raise error for np.outer on non 1D arrays

Best,

Matthew
_______________________________________________
NumPy-Discussion mailing list
[email protected]
http://mail.scipy.org/mailman/listinfo/numpy-discussion

Reply via email to