Re: [Numpy-discussion] alterdot and restoredot

2008-07-09 Thread Robert Kern
On Wed, Jul 9, 2008 at 06:36, Anne Archibald <[EMAIL PROTECTED]> wrote:
> 2008/7/9 Robert Kern <[EMAIL PROTECTED]>:
>
>>> - Which operations do the functions exactly affect?
>>>  It seems that alterdot sets the "dot" function slot to a BLAS
>>>  version, but what operations does this affect?
>>
>> dot(), vdot(), and innerproduct() on C-contiguous arrays which are
>> Matrix-Matrix, Matrix-Vector or Vector-Vector products.
>
> Really? Not, say, tensordot()?

If the ultimate dot() call inside tensordot() is one of the above
forms, then yes. If it's a 3D-3D product, for example, or one where
the shape manipulations leave the arrays discontiguous, then no.

-- 
Robert Kern

"I have come to believe that the whole world is an enigma, a harmless
enigma that is made terrible by our own mad attempt to interpret it as
though it had an underlying truth."
 -- Umberto Eco
___
Numpy-discussion mailing list
Numpy-discussion@scipy.org
http://projects.scipy.org/mailman/listinfo/numpy-discussion


Re: [Numpy-discussion] alterdot and restoredot

2008-07-09 Thread Anne Archibald
2008/7/9 Robert Kern <[EMAIL PROTECTED]>:

>> - Which operations do the functions exactly affect?
>>  It seems that alterdot sets the "dot" function slot to a BLAS
>>  version, but what operations does this affect?
>
> dot(), vdot(), and innerproduct() on C-contiguous arrays which are
> Matrix-Matrix, Matrix-Vector or Vector-Vector products.

Really? Not, say, tensordot()?

Anne
___
Numpy-discussion mailing list
Numpy-discussion@scipy.org
http://projects.scipy.org/mailman/listinfo/numpy-discussion


Re: [Numpy-discussion] alterdot and restoredot

2008-07-09 Thread Robert Kern
On Wed, Jul 9, 2008 at 02:53, Pauli Virtanen <[EMAIL PROTECTED]> wrote:
>
> Tue, 08 Jul 2008 23:03:52 -0500, Robert Kern wrote:
>> On Tue, Jul 8, 2008 at 14:01, Keith Goodman <[EMAIL PROTECTED]> wrote:
>>> I don't know what to write for a doc string for alterdot and
>>> restoredot.
>>
>> Then maybe you're the best one to figure it out. What details do you
>> think are missing from the current docstrings? What questions do they
>> leave you with?
>
> I have the following for starters:
>
> - Are these meant as user-visible functions?

Yes, with the caveats below.

> - Should the user call them? When? What is the advantage?

Typically, one would only want to call them when trying to
troubleshoot an installation problem, benchmark their installation, or
otherwise need complete control over what code is used. Most users
will never need to touch them.

> - Are BLAS routines used by default? (And if not, why not?)

If numpy.core._blasdot was built and imports, then yes.

> - Which operations do the functions exactly affect?
>  It seems that alterdot sets the "dot" function slot to a BLAS
>  version, but what operations does this affect?

dot(), vdot(), and innerproduct() on C-contiguous arrays which are
Matrix-Matrix, Matrix-Vector or Vector-Vector products.

-- 
Robert Kern

"I have come to believe that the whole world is an enigma, a harmless
enigma that is made terrible by our own mad attempt to interpret it as
though it had an underlying truth."
 -- Umberto Eco
___
Numpy-discussion mailing list
Numpy-discussion@scipy.org
http://projects.scipy.org/mailman/listinfo/numpy-discussion


Re: [Numpy-discussion] alterdot and restoredot

2008-07-09 Thread Pauli Virtanen

Tue, 08 Jul 2008 23:03:52 -0500, Robert Kern wrote:
> On Tue, Jul 8, 2008 at 14:01, Keith Goodman <[EMAIL PROTECTED]> wrote:
>> I don't know what to write for a doc string for alterdot and
>> restoredot.
> 
> Then maybe you're the best one to figure it out. What details do you
> think are missing from the current docstrings? What questions do they
> leave you with?

I have the following for starters:

- Are these meant as user-visible functions?

- Should the user call them? When? What is the advantage?

- Are BLAS routines used by default? (And if not, why not?)

- Which operations do the functions exactly affect?
  It seems that alterdot sets the "dot" function slot to a BLAS
  version, but what operations does this affect?

Pauli

___
Numpy-discussion mailing list
Numpy-discussion@scipy.org
http://projects.scipy.org/mailman/listinfo/numpy-discussion


Re: [Numpy-discussion] alterdot and restoredot

2008-07-08 Thread Robert Kern
On Tue, Jul 8, 2008 at 14:01, Keith Goodman <[EMAIL PROTECTED]> wrote:
> I don't know what to write for a doc string for alterdot and
> restoredot.

Then maybe you're the best one to figure it out. What details do you
think are missing from the current docstrings? What questions do they
leave you with?

-- 
Robert Kern

"I have come to believe that the whole world is an enigma, a harmless
enigma that is made terrible by our own mad attempt to interpret it as
though it had an underlying truth."
 -- Umberto Eco
___
Numpy-discussion mailing list
Numpy-discussion@scipy.org
http://projects.scipy.org/mailman/listinfo/numpy-discussion


[Numpy-discussion] alterdot and restoredot

2008-07-08 Thread Keith Goodman
I don't know what to write for a doc string for alterdot and
restoredot. Any ideas?
___
Numpy-discussion mailing list
Numpy-discussion@scipy.org
http://projects.scipy.org/mailman/listinfo/numpy-discussion