You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
from_pretrained() needs to be an instance method and not a static method. In most cases, you will initialize the lightning module with specific params according the the weights being loaded.
The example for a VAE indicates that
from_pretrained
is a static methodhttps://github.com/PyTorchLightning/pytorch-lightning-bolts/blob/4e1c1502b70e4be59a9ac80878ec5ad5a212f87e/pl_bolts/models/autoencoders/basic_vae/basic_vae_module.py#L30
Indeed, running this line causes as error:
This is because the method is actually implemented nonstatically:
Seems to me either:
vae = VAE(32).from_pretrained(...)
)Here is a minimal failing example on colab: https://colab.research.google.com/drive/1quvrQUyCIMC7Cq9QCjaJfip5hsi9jwSJ?usp=sharing
Happy to write a PR, if desired
The text was updated successfully, but these errors were encountered: