Re: [Numpy-discussion] Suggestion: prevent silent downcast in np.full_like

2020-02-24 Thread Stefan van der Walt
Hi Alexis, On Mon, Feb 24, 2020, at 12:00, A T wrote: > Here is a summarized code example of how unsafe downcasting in np.full_like() > resulted in issues in our scientific toolbox: > > t0 = 20.5 > # We're trying to make a constant-valued "ufunc" > temperature = lambda x: np.full_like(x, t0) >

[Numpy-discussion] Suggestion: prevent silent downcast in np.full_like

2020-02-24 Thread A T
Hello, This is my first activity on this mailing list, please let me know if I am doing anything improperly. I recently opened issue #15635 and it was suggested to me that it could be worth discussing here. Here is a summarized code example of how