rohithk-03 commited on
Commit
b98361b
·
1 Parent(s): 4676214

update model code

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -299,7 +299,7 @@ def predict():
299
 
300
  def remove_module_from_checkpoint(checkpoint):
301
  new_state_dict = {}
302
- for key, value in checkpoint["model_state_dict"].items():
303
  new_key = key.replace("module.", "")
304
  new_state_dict[new_key] = value
305
  checkpoint["model_state_dict"] = new_state_dict
 
299
 
300
  def remove_module_from_checkpoint(checkpoint):
301
  new_state_dict = {}
302
+ for key, value in checkpoint.items():
303
  new_key = key.replace("module.", "")
304
  new_state_dict[new_key] = value
305
  checkpoint["model_state_dict"] = new_state_dict