We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent c311043 commit d91a43eCopy full SHA for d91a43e
src/Python/ccpi/filters/utils.py
@@ -1,5 +1,6 @@
1
import platform
2
import ctypes
3
+import os
4
5
if platform.system() == 'Linux':
6
dll = 'libcilreg.so'
@@ -11,7 +12,7 @@
11
12
else:
13
raise ValueError('Not supported platform, ', platform.system())
14
-cilreg = ctypes.cdll.LoadLibrary(dll)
15
+cilreg = ctypes.cdll.LoadLibrary(os.path.join(os.path.dirname(__file__), dll))
16
17
try:
18
@@ -23,8 +24,8 @@
23
24
gpudll = 'libcilregcuda.dylib'
25
26
-
27
- cilregcuda = ctypes.cdll.LoadLibrary(gpudll)
+
28
+ cilregcuda = ctypes.cdll.LoadLibrary(os.path.join(os.path.dirname(__file__), gpudll))
29
except OSError as ose:
30
print(ose)
- cilregcuda = None
31
+ cilregcuda = None
0 commit comments