On Tue, 13 Dec 2011 07:53:40 -0800 (PST), ggeo <gg...@windowslive.com> wrote:
> Hello , i am starting to learnd pyCuda and i have a few questions.
> 
> 1) When i create a Cuda project (or PyCuda) how can i handle the threads and
> blocks in order to maximize the efficiency.I mean ,that when i create a
> project i don't now where (in what card ) it would run.Is there a way to
> handle this?

Excellent question. Unfortunately, aside from autotuning (which PyCUDA
will let you do quite easily), nobody has figured out a good solution to
that--at least as far as I know. In general, the answer is very much
problem-specific.

> 2) If i have to include headers or libraries ,for example "#include
> <boost/array.hpp>" is there a way to do this?Because it doesn't accept this. 
> (Ok, one way for the header is to put it in the kernel function)

All your functions/methods must be __device__ methods, so directly using
existing headers (such as boost) is not going to work. That said, using
header files with PyCUDA should be fine, as long as you specify the path
to them (even if they live in the current directory--because PyCUDA
doesn't run nvcc in the current working directory).

HTH,
Andreas

Attachment: pgp3Y10A7tHwJ.pgp
Description: PGP signature

_______________________________________________
PyCUDA mailing list
PyCUDA@tiker.net
http://lists.tiker.net/listinfo/pycuda

Reply via email to