-
Notifications
You must be signed in to change notification settings - Fork 3.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
disable optimizers setup during testing #3059
Conversation
Hello @rohitgr7! Thanks for updating this PR. There are currently no PEP 8 issues detected in this Pull Request. Cheers! 🍻 Comment last updated at 2020-09-28 21:20:45 UTC |
Codecov Report
@@ Coverage Diff @@
## master #3059 +/- ##
=======================================
+ Coverage 86% 91% +5%
=======================================
Files 110 110
Lines 8220 8206 -14
=======================================
+ Hits 7069 7463 +394
+ Misses 1151 743 -408 |
amp tests are just checking that training is a success or not. There is no test to check whether the model and optimizers are actually configured with apex/native_amp or not. |
@rohitgr7 PR is looking good, just wanted to ask why it is necessary to disable configuration during testing? |
@SkafteNicki if someone wants to use lightning module for the sole purpose of testing or monitoring the performance of their model, then only test part of lightning module is required so I don't think optimizers or schedulers are required here. If we keep it as it is, I might throw an error since .test actually calls .fit |
This pull request is now in conflict... :( |
@rohitgr7 good point. If there is a use case right now on master that produce an error (related to this), we should probably write an test that quantifies that this PR solves that :] |
@SkafteNicki a simple one I can think of is just implement test_step and test_epoch_end and call trainer.test(). Ideally it should work but it throws an error. We definitely need some tests for this. Marked as WIP. |
lots of refactoring going on with accelerators. I guess I'll wait for some time to work on this PR. |
26454fe
to
ba0c80d
Compare
should I write supporting tests for each backend? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I only have a few style comments, but the core looks good to me! Thank you for adding this @rohitgr7 !
0586d5c
to
8179550
Compare
seems some more GPU tests are failing, @rohitgr7 mind check it... |
5d30e1f
to
a0f8680
Compare
@Borda fixed the bug. |
What does this PR do?
Disable configuring optimizers and schedulers during testing.
Before submitting
PR review
Anyone in the community is free to review the PR once the tests have passed.
If we didn't discuss your PR in Github issues there's a high chance it will not be merged.
Did you have fun?
Make sure you had fun coding 🙃