[pythran] Re: dimension-independent functions?

  • From: serge Guelton <sguelton@xxxxxxxxxxxxx>
  • To: pythran@xxxxxxxxxxxxx
  • Date: Fri, 5 Sep 2014 14:33:05 +0200

On Fri, Sep 05, 2014 at 08:28:36AM -0400, Neal Becker wrote:
> Thanks.
> 
> Your version seems much more elegant

I thought you were benchamrking pythran :-)

> def sqrv(x):
>         return x * x
> 
> I didn't know pythran would produce an element-wise iteration over the whole
> array from this code.

That's valid numpy, nothing specific to Pythran.

Other related posts: