wenkai commited on
Commit
d038e6a
1 Parent(s): 0bdefca

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -22,7 +22,7 @@ def get_model(type='Molecule Function'):
22
  model.to('cuda')
23
  elif type == 'Biological Process':
24
  model.load_checkpoint("model/checkpoint_bp1.pth")
25
- model.Qformer.bert.load_state_dict(torch.load('model/bp1_bert.pth').state_dict())
26
  model.to('cuda')
27
  elif type == 'Cellar Component':
28
  model.load_checkpoint("model/checkpoint_cc2.pth")
 
22
  model.to('cuda')
23
  elif type == 'Biological Process':
24
  model.load_checkpoint("model/checkpoint_bp1.pth")
25
+ model.Qformer.bert.load_state_dict(torch.load('model/bp1_bert.pth', map_location=torch.device('cpu')).state_dict())
26
  model.to('cuda')
27
  elif type == 'Cellar Component':
28
  model.load_checkpoint("model/checkpoint_cc2.pth")