@@ -0,0 +1,1038 @@
+# -*- coding: utf-8 -*-%0A%0Afrom pycublas import *%0Afrom ctypes import *%0A%0A#Test functions%0Ahandle = cublasHandle_t()%0A%0Adef Init():%0A    status = cublasCreate(byref(handle))%0A    print status%0A%0Adef Close():%0A    status = cublasDestroy(handle)%0A    print status%0A%0Adef Version():%0A    version = c_int()%0A    status = cublasGetVersion(handle, byref(version))%0A    print 'version:', version.value%0A    print status%0A  %0Adef GetPointerMode():%0A    mode = c_cublasPointerMode_t()%0A    status = cublasGetPointerMode(handle, byref(mode))%0A    print 'PointerMode:', cublasPointerMode_t(mode.value)%0A    print status%0A%0Adef SetPointerMode(mode):%0A    mode = c_cublasPointerMode_t(mode)%0A    status = cublasSetPointerMode(handle, mode)%0A    print status%0A    %0Adef GetAtomicsMode():%0A    mode = c_cublasAtomicsMode_t()%0A    status = cublasGetAtomicsMode(handle, byref(mode))%0A    print 'AtomicMode:', cublasAtomicsMode_t(mode.value)%0A    print status%0A%0Adef SetAtomicsMode(mode):%0A    mode = c_cublasAtomicsMode_t(mode)%0A    status = cublasSetAtomicsMode(handle, mode)%0A    print status%0A%0A

Test in a new file