anjikum commited on
Commit
238f695
·
verified ·
1 Parent(s): 44c5184

changed invalid argument in model load

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -37,7 +37,7 @@ checkpoint = torch.load('model.pth', map_location='cpu')
37
  print(checkpoint.keys())
38
 
39
  # Load the model weights
40
- model.load_state_dict(checkpoint['model'], strict=False, map_location=device)
41
 
42
  # If you need to resume training, load optimizer and scheduler states
43
  optimizer.load_state_dict(checkpoint['optimizer_state_dict'])
 
37
  print(checkpoint.keys())
38
 
39
  # Load the model weights
40
+ model.load_state_dict(checkpoint['model'], strict=False)
41
 
42
  # If you need to resume training, load optimizer and scheduler states
43
  optimizer.load_state_dict(checkpoint['optimizer_state_dict'])