From 38830e76ff11ac574391ba033270e87a0579cd89 Mon Sep 17 00:00:00 2001 From: "Daniel.Frisinghelli" <daniel.frisinghelli@eurac.edu> Date: Thu, 4 Feb 2021 17:17:51 +0100 Subject: [PATCH] Fixed a bug: Correct gpu id is now used for model evaluation. --- pysegcnn/core/trainer.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pysegcnn/core/trainer.py b/pysegcnn/core/trainer.py index 8b46194..502676b 100644 --- a/pysegcnn/core/trainer.py +++ b/pysegcnn/core/trainer.py @@ -2106,7 +2106,7 @@ class NetworkInference(BaseConfig): # the device to compute on, use gpu if available self.device = torch.device( - 'cuda:' if torch.cuda.is_available() else 'cpu') + 'cuda:0' if torch.cuda.is_available() else 'cpu') # the output paths for the different graphics self.base_path = pathlib.Path(HERE) -- GitLab