KenLumod commited on
Commit
9840a2c
·
verified ·
1 Parent(s): cecd2b7

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -37,7 +37,7 @@ def load_model(model_dir: str, device=torch.device("cpu")):
37
  )
38
 
39
  # Load custom weights
40
- state_dict = torch.load(os.path.join(model_dir, "model_state.bin"), map_location=device)
41
  model.load_state_dict(state_dict)
42
 
43
  # Load tokenizer
 
37
  )
38
 
39
  # Load custom weights
40
+ state_dict = torch.load(os.path.join(model_dir, "model_state.bin"))
41
  model.load_state_dict(state_dict)
42
 
43
  # Load tokenizer