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

Weights are not logged when model is watched #1471

Closed
stathius opened this issue Nov 6, 2020 · 9 comments
Closed

Weights are not logged when model is watched #1471

stathius opened this issue Nov 6, 2020 · 9 comments
Labels
ty:bug type of the issue is a bug

Comments

@stathius
Copy link

stathius commented Nov 6, 2020

The gradients of the model are indeed logged but not the parameters.

Using:
pytorch-lightning==1.0.4
torch==1.7.0
torchvision==0.8.1
wandb==0.10.9

mac os x 10.15.7

        logger = pl.loggers.WandbLogger(project=hparams.project_name, save_dir=save_dir)
        logger.log_hyperparams(vars(hparams))
        logger.watch(model, log='all', log_freq=1)
@issue-label-bot issue-label-bot bot added the ty:bug type of the issue is a bug label Nov 6, 2020
@issue-label-bot
Copy link

Issue-Label Bot is automatically applying the label bug to this issue, with a confidence of 0.96. Please mark this comment with 👍 or 👎 to give our bot feedback!

Links: app homepage, dashboard and code for this bot.

@tyomhak
Copy link

tyomhak commented Nov 6, 2020

Hi @stathius , thanks for reporting this issue. We're looking into this.

@tyomhak
Copy link

tyomhak commented Nov 9, 2020

I believe by default it is supposed to log only gradients, but you can change it by using argument log.
Please see the documentation (here) for more details.

@stathius
Copy link
Author

stathius commented Nov 9, 2020 via email

@lukas
Copy link
Contributor

lukas commented Nov 11, 2020

Hm, I tried to replicate this by setting log='all' in https://github.com/wandb/examples/blob/master/examples/pytorch/pytorch-cnn-mnist/main.py and it seemed to work as intended, logging both parameters and gradients - could you try that with your setup

@ariG23498
Copy link
Contributor

Hey @stathius
Did you happen to find the solution to the issue?
It would be great for us if we could close the stale threads if the solution has already been achieved. 😄

@stathius
Copy link
Author

stathius commented Dec 8, 2020

Hi @ariG23498 not really but it's fine to close it.

@sbos
Copy link

sbos commented Mar 25, 2022

I'm experiencing the same problem. Gradients are logged fine, but parameters don't show up in wandb panels. Is there any way to tell why this is silently failing?

@KarlXing
Copy link

I'm having the same issue.

wandb: 0.15.5
torch: 2.1.0.dev20230627+cu121

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ty:bug type of the issue is a bug
Projects
None yet
Development

No branches or pull requests

6 participants