yanyichu commited on
Commit
8e2cf76
1 Parent(s): 711fba0

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -150,8 +150,8 @@ def predict_raw(raw_input):
150
  _, dataloader = generate_dataset_dataloader(ids, seqs)
151
 
152
  model = CNN_linear()
153
- print(model.state_dict().keys())
154
- print(torch.load(modelfile, map_location=torch.device('cpu')).keys())
155
  model.esm2.load_state_dict({k.replace('module.', ''):v for k,v in torch.load(modelfile, map_location=torch.device('cpu')).items()}, strict = False)
156
  # model.load_state_dict(torch.load(modelfile, map_location=torch.device('cpu')), strict = False)
157
 
 
150
  _, dataloader = generate_dataset_dataloader(ids, seqs)
151
 
152
  model = CNN_linear()
153
+ st.write(model.state_dict().keys())
154
+ st.write(torch.load(modelfile, map_location=torch.device('cpu')).keys())
155
  model.esm2.load_state_dict({k.replace('module.', ''):v for k,v in torch.load(modelfile, map_location=torch.device('cpu')).items()}, strict = False)
156
  # model.load_state_dict(torch.load(modelfile, map_location=torch.device('cpu')), strict = False)
157