On Thu, Feb 8, 2018 at 3:25 AM, Pierrick Bruneau <pbrun...@gmail.com> wrote:
> Hi all,
>
> This may sound as dumb to some of you, but is it possible to use numpy
> functions in code compiled by compiler.SourceModule in some way ? (e.g.
> included API)
>
> I'm wondering this as there seems to be a close bind between numpy arrays,
> gpuarrays, and int/float arrays in C++ code.
>
> If numpy is not an option, there are maybe good practices in terms of
> included libraries that play well with pycuda? To avoid recoding every
> possible vector/matrix and utility stats functions :)
>
> Best regards,
> Pierrick Bruneau

One can make API calls to shared GPU-based libraries (CUBLAS, CUFFT,
etc.) that access GPU memory allocated by pycuda in between (but not
directly from) CUDA kernels compiled with compiler.SourceModule - see
http://scikit-cuda.rtfd.io. You may also want to take a look at
numba's GPU support (http://numba.pydata.org).
-- 
Lev E. Givon, PhD
http://lebedov.github.io


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

Reply via email to