Background
libcuda.so.1
is the library for interacting with the CUDA driver (as opposed to CUDA's "Runtime API", for which you need libcudart.so.*
).
Now, it's quite possible to have the CUDA Toolkit properly installed, without the driver being properly installed. And this error could be the result of building a (non-statically-linked) CUDA application in this situation.
Alternatively, it could be the case that there's some misconfiguration of the library search path - because normally, libcuda.so.*
are supposed to be installed in some directory on that path!
So, what's on that search path? As explained here, it is:
- directories from
$LD_LIBRARY_PATH
- directories from
/etc/ld.so.conf
/lib
/usr/lib
A typical scenario would be for /etc/ld.so.conf
to add, say, /usr/lib/x86_64-linux-gnu
; and for libcuda.so.*
to be there.
Bottom line
Here's what you should do:
- Make sure a(n up-to-date) CUDA driver has been properly installed. If it hasn't, download and install it, problem solved.
- Locate the
libcuda.so.1
file (e.g. using locate
). If it's been placed somewhere weird that's not in the library search path - act as in step 1.
- If you wanted the driver library installed someplace weird, then add that path to your user's
$LD_LIBRARY_PATH
.
import cupy
– Bluebottle