How to test in low version #8103
Answered
by
awaelchli
AIhang427
asked this question in
Lightning Trainer API: Trainer, LightningModule, LightningDataModule
-
There is no train.test () in the lower version. How to test the test data set? |
Beta Was this translation helpful? Give feedback.
Answered by
awaelchli
Jun 24, 2021
Replies: 1 comment 1 reply
-
Hi for inp, target in test_dataloader:
pred = model(inp)
test_loss = loss(pred, target)
... |
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
AIhang427
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi
PyTorch Lightning 0.4.6 is extremely old. You should consider upgrading.
That being said, you can always test your model as you would in plain pytorch, because the LightningModule is also just a nn.Module: