Re: [Numpy-discussion] Two questions about PEP 465 dot product

2015-05-21 Thread Nathaniel Smith
On Thu, May 21, 2015 at 6:06 PM, Alexander Belopolsky ndar...@mac.com wrote: 1. Is there a simple expression using existing numpy functions that implements PEP 465 semantics for @? Not yet. 2. Suppose I have a function that takes two vectors x and y, and a matrix M and returns

[Numpy-discussion] Two questions about PEP 465 dot product

2015-05-21 Thread Alexander Belopolsky
1. Is there a simple expression using existing numpy functions that implements PEP 465 semantics for @? 2. Suppose I have a function that takes two vectors x and y, and a matrix M and returns x.dot(M.dot(y)). I would like to vectorize this function so that it works with x and y of any ndim = 1