gelnesr commited on
Commit
16f71d3
·
verified ·
1 Parent(s): 5dc395e

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -163,10 +163,10 @@ def predict_dynamics(sequence=None, pdb_input=None, chain_id='A', use_pdb_seq=Fa
163
  protein = None
164
  if model_version == "ESM3":
165
  model = ESM_model(method='esm3')
166
- model.load_state_dict(torch.load('Dyna-1/model/weights/dyna1.pt'), strict=False)
167
  else:
168
  model = ESM_model(method='esm2', nheads=8, nlayers=12, layer=30).to(DEVICE)
169
- model.load_state_dict(torch.load('Dyna-1/model/weights/dyna1-esm2.pt'), strict=False)
170
 
171
  model.eval()
172
 
 
163
  protein = None
164
  if model_version == "ESM3":
165
  model = ESM_model(method='esm3')
166
+ model.load_state_dict(torch.load('Dyna-1/model/weights/dyna1.pt', map_location=torch.device('cpu')), strict=False)
167
  else:
168
  model = ESM_model(method='esm2', nheads=8, nlayers=12, layer=30).to(DEVICE)
169
+ model.load_state_dict(torch.load('Dyna-1/model/weights/dyna1-esm2.pt', map_location=torch.device('cpu')), strict=False)
170
 
171
  model.eval()
172