[Numpy-discussion] ndarray and lazy evaluation

James Bergstra bergstrj@iro.umontreal...
Mon Feb 20 14:30:23 CST 2012

On Mon, Feb 20, 2012 at 2:57 PM, Lluís <xscript@gmx.net> wrote:

> James Bergstra writes:
> [...]
> > I should add that the biggest benefit of expressing things as compound
> > expressions in this way is not in saving temporaries (though that is
> nice) it's
> > being able to express enough computation work at a time that it offsets
> the time
> > required to ship the arguments off to a GPU for evaluation!
> Right, that's exacly what you need for an "external computation" to pay
> off.
> Just out of curiosity (feel free to respond with a RTFM or a RTFP :)), do
> you
> support any of these? (sorry for the made-up names)
> * automatic transfer double-buffering

Not currently, but it would be quite straightforward to do it. Email
theano-dev and ask how if you really want to know.

> * automatic problem partitioning into domains (e.g., multiple GPUs; even
> better
>  if also supports nodes - MPI -)

Not currently, and it would be hard.

> * point-specific computations (e.g., code dependant on the thread id,
> although
>  this can also be expressed in other ways, like index ranges)

> * point-relative computations (the most common would be a stencil)
No, but I think theano provides a decent expression language to tackle
this. The "Composite" element-wise code generator is an example of how I
would think about this. It provides point-relative computations across
several arguments.  You might want something different that applies a
stencil computation across one or several arguments... the "scan" operator
was another foray into this territory, and it got tricky when the stencil
operation could have side-effects (like random number generation) and could
define it's own input domain (stencil shape), but the result is quite

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.scipy.org/pipermail/numpy-discussion/attachments/20120220/d5d2ad86/attachment.html 

More information about the NumPy-Discussion mailing list