Skip to content

Commit

Permalink
weights_only
Browse files Browse the repository at this point in the history
  • Loading branch information
hstern2 committed Sep 20, 2024
1 parent ad6f12a commit 5214092
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion amsr/lstm.py
Original file line number Diff line number Diff line change
Expand Up @@ -151,7 +151,7 @@ def train_and_save_model(

@classmethod
def from_saved_model(cls, model_path):
checkpoint = torch.load(model_path, map_location=_device())
checkpoint = torch.load(model_path, map_location=_device(), weights_only=True)
model = cls(
d_model=checkpoint["d_model"],
nhid=checkpoint["nhid"],
Expand Down

0 comments on commit 5214092

Please sign in to comment.