Re: [Numpy-discussion] "Extended" Outer Product

2007-08-21 Thread Robert Kern
Timothy Hochberg wrote: > On 8/21/07, *Anne Archibald* <[EMAIL PROTECTED] > > wrote: > but conceptually it's extremely handy for > doing exactly what the OP wanted. Unfortunately vectorize() does not > yield a sufficiently ufunc-like object to support .outer()

Re: [Numpy-discussion] "Extended" Outer Product

2007-08-21 Thread Timothy Hochberg
On 8/21/07, Anne Archibald <[EMAIL PROTECTED]> wrote: > > On 21/08/07, Timothy Hochberg <[EMAIL PROTECTED]> wrote: > > > This is just a general comment on recent threads of this type and not > > directed specifically at Chuck or anyone else. > > > > IMO, the emphasis on avoiding FOR loops at all co

Re: [Numpy-discussion] "Extended" Outer Product

2007-08-21 Thread Anne Archibald
On 21/08/07, Timothy Hochberg <[EMAIL PROTECTED]> wrote: > This is just a general comment on recent threads of this type and not > directed specifically at Chuck or anyone else. > > IMO, the emphasis on avoiding FOR loops at all costs is misplaced. It is > often more memory friendly and thus faste

Re: [Numpy-discussion] "Extended" Outer Product

2007-08-21 Thread Timothy Hochberg
On 8/21/07, Geoffrey Zhu <[EMAIL PROTECTED]> wrote: > > On 8/21/07, Timothy Hochberg <[EMAIL PROTECTED]> wrote: > > > > > > > > On 8/21/07, Charles R Harris <[EMAIL PROTECTED]> wrote: > > > > > > > > > > > > On 8/20/07, Geoffrey Zhu < [EMAIL PROTECTED]> wrote: > > > > Hi Everyone, > > > > > > > > I

Re: [Numpy-discussion] "Extended" Outer Product

2007-08-21 Thread Geoffrey Zhu
On 8/21/07, Timothy Hochberg <[EMAIL PROTECTED]> wrote: > > > > On 8/21/07, Charles R Harris <[EMAIL PROTECTED]> wrote: > > > > > > > > On 8/20/07, Geoffrey Zhu < [EMAIL PROTECTED]> wrote: > > > Hi Everyone, > > > > > > I am wondering if there is an "extended" outer product. Take the > > > example

Re: [Numpy-discussion] "Extended" Outer Product

2007-08-21 Thread Timothy Hochberg
On 8/21/07, Charles R Harris <[EMAIL PROTECTED]> wrote: > > > > On 8/20/07, Geoffrey Zhu <[EMAIL PROTECTED]> wrote: > > > > Hi Everyone, > > > > I am wondering if there is an "extended" outer product. Take the > > example in "Guide to Numpy." Instead of doing an multiplication, I > > want to call a

Re: [Numpy-discussion] "Extended" Outer Product

2007-08-21 Thread Charles R Harris
On 8/20/07, Geoffrey Zhu <[EMAIL PROTECTED]> wrote: > > Hi Everyone, > > I am wondering if there is an "extended" outer product. Take the > example in "Guide to Numpy." Instead of doing an multiplication, I > want to call a custom function for each pair. > > >>> print outer([1,2,3],[10,100,1000]) >

Re: [Numpy-discussion] Finding a row match within a numpy array

2007-08-21 Thread Mark.Miller
A slightly related question on this topic... Is there a good loopless way to identify all of the unique rows in an array? Something like numpy.unique() is ideal, but capable of extracting unique subarrays along an axis. Thanks, -Mark mark wrote: > Maybe this is not the intended use of where,