Re: [Numpy-discussion] Casting to np.byte before clearing values

2016-12-27 Thread Nicolas P. Rougier
Yes, clearing is not the proper word but the "trick" works only work for 0 (I'll get the same result in both cases). Nicolas > On 27 Dec 2016, at 20:52, Chris Barker wrote: > > On Mon, Dec 26, 2016 at 1:34 AM, Nicolas P. Rougier > wrote: > > I'm trying to understand why viewing an array

Re: [Numpy-discussion] Casting to np.byte before clearing values

2016-12-27 Thread Chris Barker
On Mon, Dec 26, 2016 at 1:34 AM, Nicolas P. Rougier < nicolas.roug...@inria.fr> wrote: > > I'm trying to understand why viewing an array as bytes before clearing > makes the whole operation faster. > I imagine there is some kind of special treatment for byte arrays but I've > no clue. > I notice