-
Notifications
You must be signed in to change notification settings - Fork 3.5k
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
EvalResult support for val loop (PR 3/5) #2651
Conversation
Codecov Report
@@ Coverage Diff @@
## master #2651 +/- ##
=======================================
Coverage 91% 92%
=======================================
Files 72 74 +2
Lines 6129 6316 +187
=======================================
+ Hits 5597 5786 +189
+ Misses 532 530 -2 |
Hello @williamFalcon! Thanks for updating this PR. There are currently no PEP 8 issues detected in this Pull Request. Cheers! 🍻 Comment last updated at 2020-07-22 17:31:30 UTC |
yeah that makes sense. I guess for now we can keep global step as is? but for val metrics use this formula: |
@@ -17,6 +17,8 @@ def is_overridden(self, method_name: str, model: LightningModule = None) -> bool | |||
model = self.get_model() | |||
super_object = LightningModule | |||
|
|||
# assert model, 'no model passes' |
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.
just crossed this, what is the case we would pass None
as model
?
cc: @awaelchli @justusschock @williamFalcon
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.
.test()
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.
it is happening also in validation, well in case you call _evalaute
directly with passed model
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.
test(model=None) will take the model the trainer knows from fit, right?
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.
yes but in that walk-around test, the model was not assigned to trainer...
actually... we could do this:
for step metrics. This will make multtiple lines on the same chart. And since val/test loaders are not shuffled, the effect will be a histogram for each batch_idx. |
but let's merge this in and we can make that change in a follow on PR |
Co-authored-by: Jirka Borovec <[email protected]>
Co-authored-by: Jirka Borovec <[email protected]>
Finishes enabling EvalResult in val/test loop (still optional).
Next PR will document all of this.
Additional improvements
Also improves these things:
.test()
results now includes everything returned by the user (not just callback metrics)