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

ModelSummary fails on the "generative_adversarial_net" example #2211

Closed
johngull opened this issue Jun 16, 2020 · 2 comments
Closed

ModelSummary fails on the "generative_adversarial_net" example #2211

johngull opened this issue Jun 16, 2020 · 2 comments
Labels
bug Something isn't working help wanted Open to be worked on

Comments

@johngull
Copy link

🐛 Bug

When you run this example: https://github.com/PyTorchLightning/pytorch-lightning/blob/master/pl_examples/domain_templates/generative_adversarial_net.py
you got error: RuntimeError: size mismatch, m1: [56 x 28], m2: [100 x 128]

My understanding by quick viewing of callstack:
Seems that problem in ModelSummary, which unfold 2 presented nn.Module to the same list of mods. And then it tries to push result of one module to the input of another layer, but this layers are not part of the same models.

To Reproduce

Just run example https://github.com/PyTorchLightning/pytorch-lightning/blob/master/pl_examples/domain_templates/generative_adversarial_net.py

Environment

Python 3.7
PyTorch 1.3.1
pytorch-lightning 0.7.6

@johngull johngull added bug Something isn't working help wanted Open to be worked on labels Jun 16, 2020
@awaelchli
Copy link
Contributor

I fixed this recently, see #1773. Try the master branch (or the 0.8.0 release in a few days).

@awaelchli
Copy link
Contributor

I'll close this unless you find another issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working help wanted Open to be worked on
Projects
None yet
Development

No branches or pull requests

2 participants