Skip to content
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

BYOL weight update callback #867

Merged
merged 5 commits into from
Aug 25, 2022
Merged

Conversation

matsumotosan
Copy link
Contributor

@matsumotosan matsumotosan commented Aug 19, 2022

What does this PR do?

Fixes part of #839

  • pl_bolts.callbacks.byol_updates.BYOLMAWeightUpdate

Summary

  • Modify update_tau method to update tau value inside method instead of returning new tau value
  • Add more tests for initial values of tau
    • Invalid values (<0, >1) -> raises ValueError
    • Edge cases (0, 1) -> equal to online/target, respectively
    • In between 0 and 1 -> test for exact value of parameters

Before submitting

  • Was this discussed/approved via a Github issue? (no need for typos and docs improvements)
  • Did you read the contributor guideline, Pull Request section?
  • Did you make sure your PR does only one thing, instead of bundling different changes together?
  • Did you make sure to update the documentation with your changes?
  • Did you write any new necessary tests? [not needed for typos/docs]
  • Did you verify new and existing tests pass locally with your changes?
  • If you made a notable change (that affects users), did you update the CHANGELOG?

PR review

  • Is this pull request ready for review? (if not, please submit in draft mode)

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 🙃

@otaj otaj mentioned this pull request Aug 23, 2022
Copy link
Contributor

@otaj otaj left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It looks good, only one major comment regarding catch_warnings. Once that's solved (and no warnings are raised, I'll be happy to give final approval :)

Thank you! ⚡

tests/callbacks/test_param_update_callbacks.py Outdated Show resolved Hide resolved
@mergify mergify bot added the ready label Aug 23, 2022
@otaj otaj merged commit 9619d5f into Lightning-Universe:master Aug 25, 2022
@matsumotosan matsumotosan deleted the byol_update branch August 25, 2022 14:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants