FAQ Database Discussion Community


cudaMemcpyToSymbol in pycuda

python,cuda,pycuda
I am using pycuda and i would like to know if there is an equivalent to the function cudaMemcpyToSymbol I would like to copy a constant from the host to the device like below import pycuda.driver as cuda import pycuda.autoinit from pycuda.compiler import SourceModule import numpy from sys import path...

Returning to host code in pyCUDA after asynchronous kernel launch

python,python-2.7,cuda,ipython,pycuda
I am trying to launch a kernel in pyCUDA and then terminate the kernel by writing to a GPU global memory location. Here is a simple example kernel that I would like to be able to terminate at some point after it enters the infinite while loop: __global__ void countUp(u16...

using dictionary in pycuda

python,cuda,pycuda
I have a dictionary and i would like to know if is it possible to use it as a parameter of a kernel. for instance i have the cuda kernel signature __global__ void calTab(Tableaux) Tableaux is a C structure corresponding to typedef struct { float *Tab1; float *Tab2; } Tableaux;...

Interfacing cuSOLVER-sparse using PyCUDA

python,cuda,ctypes,pycuda,cusolver
I'm trying to interface the sparse cuSOLVER routine cusolverSpDcsrlsvqr() (>= CUDA 7.0) using PyCUDA and am facing some difficulties: I have tried wrapping the methods the same way the dense cuSolver routines are wrapped in scikits-cuda (https://github.com/lebedov/scikits.cuda/blob/master/scikits/cuda/cusolver.py). However, the code crashes with a segmentation fault when calling the cusolverSpDcsrlsvqr() function....

PyCUDA test_cumath.py fails on cosh

python,numpy,pycuda,tesla
I've installed pycuda on a machine featuring a TESLA C2075. I'm running on Ubuntu 14.04 with the CUDA-6.0 compiler installed. Using python 2.7.9 (via the anaconda distribution) and numpy 1.9.0, I have installed pycuda 2014.1 from the ZIP file that Andreas Kloeckner provides on his website. (http://mathema.tician.de/software/pycuda/) Running the tests...