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

ignore configure_optimizers warning #1064

Merged
merged 4 commits into from
May 24, 2021
Merged

Conversation

mjayasur
Copy link
Contributor

closes #1057

@codecov
Copy link

codecov bot commented May 15, 2021

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 90.69%. Comparing base (a9da914) to head (083dba1).

Additional details and impacted files
@@           Coverage Diff           @@
##           master    #1064   +/-   ##
=======================================
  Coverage   90.69%   90.69%           
=======================================
  Files          90       90           
  Lines        6736     6740    +4     
=======================================
+ Hits         6109     6113    +4     
  Misses        627      627           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Contributor

@wukathy wukathy left a comment

Choose a reason for hiding this comment

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

lgtm

@@ -156,4 +156,9 @@ def fit(self, *args, **kwargs):
category=UserWarning,
message="One of given dataloaders is None and it will be skipped",
)
warnings.filterwarnings(
Copy link
Member

Choose a reason for hiding this comment

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

let's only filter it if the model passed to fit is an instance of:

https:/YosefLab/scvi-tools/blob/a9da914764d311ff18b4b557b78d9550a3b940af/scvi/train/_trainingplans.py#L581

See the pylit API here, model should be the first arg.

https://pytorch-lightning.readthedocs.io/en/latest/common/trainer.html#fit

scvi/train/_trainer.py Outdated Show resolved Hide resolved
@adamgayoso adamgayoso merged commit 9fcda8f into master May 24, 2021
@adamgayoso adamgayoso deleted the michael/configure_optimizers branch May 24, 2021 16:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Weird message when training pyro model this fit will run with no optimizer
3 participants