AlexSychovUN commited on
Commit
1d227ed
·
1 Parent(s): e54496d

Fix torch load weights_only error

Browse files
Files changed (1) hide show
  1. utils.py +1 -1
utils.py CHANGED
@@ -60,7 +60,7 @@ def get_inference_data(ligand_smiles, protein_sequence, model_path=MODEL_PATH):
60
  model = BindingAffinityModel(
61
  num_features, hidden_channels=HIDDEN_CHANNELS, gat_heads=GAT_HEADS
62
  ).to(DEVICE)
63
- model.load_state_dict(torch.load(model_path, map_location=DEVICE))
64
  model.eval()
65
 
66
  with torch.no_grad():
 
60
  model = BindingAffinityModel(
61
  num_features, hidden_channels=HIDDEN_CHANNELS, gat_heads=GAT_HEADS
62
  ).to(DEVICE)
63
+ model.load_state_dict(torch.load(model_path, map_location=DEVICE, weights_only=False))
64
  model.eval()
65
 
66
  with torch.no_grad():