mirror of
https://github.com/iperov/DeepFaceLab.git
synced 2025-07-13 00:23:51 -07:00
fix nvml if it has not nvmlDeviceGetCudaComputeCapability dll function
This commit is contained in:
parent
c3b6330284
commit
0313fd9ae6
1 changed files with 5 additions and 1 deletions
|
@ -1704,7 +1704,11 @@ def nvmlDeviceGetTopologyCommonAncestor(device1, device2):
|
||||||
def nvmlDeviceGetCudaComputeCapability(device):
|
def nvmlDeviceGetCudaComputeCapability(device):
|
||||||
c_major = c_int()
|
c_major = c_int()
|
||||||
c_minor = c_int()
|
c_minor = c_int()
|
||||||
fn = _nvmlGetFunctionPointer("nvmlDeviceGetCudaComputeCapability")
|
|
||||||
|
try:
|
||||||
|
fn = _nvmlGetFunctionPointer("nvmlDeviceGetCudaComputeCapability")
|
||||||
|
except:
|
||||||
|
return 9, 9
|
||||||
|
|
||||||
# get the count
|
# get the count
|
||||||
ret = fn(device, byref(c_major), byref(c_minor))
|
ret = fn(device, byref(c_major), byref(c_minor))
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue