autonise / CRAFT-Remade

Implementation of CRAFT Text Detection
MIT License
191 stars 47 forks source link

Error on loading final_model.pkl #40

Closed devloper13 closed 2 years ago

devloper13 commented 3 years ago

I am getting this 'RuntimeError: Error(s) in loading state_dict for DataParallelModel' while loading final_model.pkl

What could this be?

mayank-git-hub commented 2 years ago

@devloper13 sorry for the late reply. This error is usually is seen in the following cases -

  1. You have made changes in the model architecture after saving the model file.
  2. You saved the model as a DataParallel object but are trying to read it without wrapping using DataParallel