How to Restore Best Model #1397
Unanswered
skumarlabs
asked this question in
Q&A - get help using NeuralProphet
Replies: 1 comment
-
Did you try this: https://lightning.ai/docs/pytorch/stable/common/checkpointing_basic.html |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi Team,
I trained an AR model as below
and I got below train metrics after early stopping stopped the training after 29th Epoch.
I can see that the best epoch is #8 with
Loss_val=0.0892
but when I test the model I getLoss_val=0.0958
i.e. the model after last epoch which is not optimal. Could you please help me restore the model from 8th Epoch? SInce I have enabled the checkpointing, I do see files['last.ckpt', 'epoch=8-step=2178.ckpt']
but I am not sure how to restore using these checkpoint files.PS: I am aware that I can retrain the model only till 8th epoch to get the optimal model state. But I wondering since we already have checkpoint, if we can use that?
Beta Was this translation helpful? Give feedback.
All reactions