Update config.py
This commit is contained in:
parent
2789b8e8f4
commit
b4c10ce37d
@ -168,10 +168,11 @@ class Config:
|
|||||||
)
|
)
|
||||||
except:
|
except:
|
||||||
pass
|
pass
|
||||||
import torch_directml
|
if(self.device!="cpu"):
|
||||||
|
import torch_directml
|
||||||
|
|
||||||
self.device = torch_directml.device(torch_directml.default_device())
|
self.device = torch_directml.device(torch_directml.default_device())
|
||||||
self.is_half = False
|
self.is_half = False
|
||||||
else:
|
else:
|
||||||
if self.instead:
|
if self.instead:
|
||||||
print(f"use {self.instead} instead")
|
print(f"use {self.instead} instead")
|
||||||
|
Loading…
x
Reference in New Issue
Block a user