1
0
mirror of https://github.com/microsoft/qlib.git synced 2026-07-16 17:12:20 +08:00

Update devices

This commit is contained in:
Jactus
2020-12-02 13:28:32 +08:00
parent 7f385345bb
commit 745b93138d
6 changed files with 6 additions and 6 deletions

View File

@@ -83,7 +83,7 @@ class GATs(Model):
self.base_model = base_model
self.with_pretrain = with_pretrain
self.model_path = model_path
self.device = "cuda:%d" % (GPU) if torch.cuda.is_available() else "cpu"
self.device = torch.device("cuda:%d" % (GPU) if torch.cuda.is_available() else "cpu")
self.use_gpu = torch.cuda.is_available()
self.seed = seed