Skip to content

Commit

Permalink
update set_device (#216)
Browse files Browse the repository at this point in the history
Signed-off-by: Wenqi Li <[email protected]>
  • Loading branch information
wyli authored Apr 4, 2023
1 parent 4af80e1 commit a3830f4
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@ def __init__(self, output_path, data_stats_file, device_id: int = 0):
parser.read_config(config_file)

self.device = torch.device("cuda:{0:d}".format(device_id))
torch.cuda.set_device(self.device)

self.input_channels = parser.get_parsed_content("training#input_channels")
self.patch_size = parser.get_parsed_content("training#patch_size")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@ def __init__(self, output_path, data_stats_file, device_id: int = 0):
parser.read_config(config_file)

self.device = torch.device("cuda:{0:d}".format(device_id))
torch.cuda.set_device(self.device)

self.input_channels = parser.get_parsed_content("input_channels")
self.num_adjacent_slices = parser.get_parsed_content("num_adjacent_slices")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@ def __init__(self, output_path, data_stats_file, device_id: int = 0):
parser.read_config(config_file)

self.device = torch.device("cuda:{0:d}".format(device_id))
torch.cuda.set_device(self.device)

self.input_channels = parser.get_parsed_content("input_channels")
self.patch_size = parser.get_parsed_content("patch_size")
Expand Down

0 comments on commit a3830f4

Please sign in to comment.