Skip to content

Commit

Permalink
fix torch warning
Browse files Browse the repository at this point in the history
  • Loading branch information
segasai committed Jul 30, 2024
1 parent aaa649f commit ea3f3de
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion py/rvspecfit/nn/RVSInterpolator.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,8 @@ def __init__(self, kwargs):
self.device = torch.device(device_env)
self.nni.load_state_dict(
torch.load(kwargs['template_lib'] + '/' + kwargs['nn_file'],
map_location=self.device))
map_location=self.device,
weights_only=True))
# self.device = list(self.nni.children())[0][0].pc_layer.weight.device

self.nni.to(self.device)
Expand Down

0 comments on commit ea3f3de

Please sign in to comment.