-
Notifications
You must be signed in to change notification settings - Fork 3.6k
Fix mypy errors attributed to pytorch_lightning.trainer.connectors.callback_connector.py
#13750
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
Fix mypy errors attributed to pytorch_lightning.trainer.connectors.callback_connector.py
#13750
Conversation
for more information, see https://pre-commit.ci
…ytorch-lightning into mypy_callback_connector
otaj
left a comment
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.
There are still couple parts that are not working well for mypy, even with applied suggestions. In the method _configure_accumulated_gradients, this could be solved by differentiating between grad_accum_callbacks and grad_accum_callback (i.e. two separate variables, one for the case when it's a list and second for when it's a single instance)
|
I think that |
Co-authored-by: otaj <[email protected]>
Co-authored-by: otaj <[email protected]>
Co-authored-by: otaj <[email protected]>
|
Thank you for the reviews @otaj |
Codecov Report
@@ Coverage Diff @@
## master #13750 +/- ##
=========================================
+ Coverage 61% 75% +14%
=========================================
Files 335 341 +6
Lines 26301 28040 +1739
=========================================
+ Hits 16048 21111 +5063
+ Misses 10253 6929 -3324 |
…ytorch-lightning into mypy_callback_connector
Co-authored-by: otaj <[email protected]>
Co-authored-by: Rohit Gupta <[email protected]>
Part of #13445