Does .predict() also use the best weights? #10795
Answered
by
rohitgr7
kaare-mikkelsen
asked this question in
Lightning Trainer API: Trainer, LightningModule, LightningDataModule
-
On https://pytorch-lightning.readthedocs.io/en/latest/starter/converting.html, it says that ".test() loads the best checkpoint automatically". Is that also the case for .predict()? |
Beta Was this translation helpful? Give feedback.
Answered by
rohitgr7
Nov 28, 2021
Replies: 1 comment
-
yes, by default it does load the best checkpoint if you don't provide the model, you can set it too if you want! trainer.predict(ckpt_path='best') |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
kaare-mikkelsen
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
yes, by default it does load the best checkpoint if you don't provide the model, you can set it too if you want!