Open au-revoir opened 3 months ago
Hi, thanks for your interest in our work. You can first define a custom model class and call from_pretrained
on this class. I guess you directly call from_pretrained
on Huggingface's AutoModel, which cannot recognize the custom architecture. An alternative is to directly load the saved state dict, and assign it to the model.
Hi, Congratulations on your work. I have saved the model after training using line. However, how do I load this saved model since the architecture is now modified and using
from_pretrained(model_saved_path)
isn't working?