On 09/12/2016 21:14, Jonny Hyman wrote:
> *pyfr.backends.cuda.cublas.CUBLASNotInitialized* Error. This is an error
> code which is documented in the CUDA documentation
> <
http://docs.nvidia.com/cuda/cublas/#cublasstatus_t>.
>
> It hints there that perhaps cublasCreate should be called earlier? Right
> now in PyFr1.5.0, we load the library, wrap it, and THEN we "Create":
> |
> class CUDACUBLASKernels(object):
> def __init__(self, backend):
> # Load and wrap CUBLAS
> self._wrappers = CUBLASWrappers()
>
> # Init
> self._handle = c_void_p()
> self._wrappers.cublasCreate(self._handle)
> |
>
> Is this a bug or am I doing something wrong?
The code ordering is correct. We can not call cublasCreate from
libcublas.so until we have loaded libcublas.so. Thus, the first thing
we do is load it. Next, we make the relevant functions from the library
available to Python. Once cuBLAS is available we proceed to call
cublasCreate.
Thus our first call into the library is one to cublasCreate.
Can you confirm if other cublas applications work with your set-up?
Regards, Freddie.