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

Failed loading VAE checkpoint #273

Open
ROGERDJQ opened this issue May 9, 2024 · 1 comment
Open

Failed loading VAE checkpoint #273

ROGERDJQ opened this issue May 9, 2024 · 1 comment

Comments

@ROGERDJQ
Copy link

ROGERDJQ commented May 9, 2024

Thank you for your wonderful contributions! I have some issues with the loading of VAE checkpoint.
when loading the checkpoint (https://huggingface.co/LanguageBind/Open-Sora-Plan-v1.0.0/tree/main/vae), we found that code
vae = CausalVAEModel.from_pretrained('./ckpt/Open-Sora-Plan-v1.0.0/vae/')
raises error
UnpicklingError: invalid load key, '\xb0'.

We also try another solution as
vae = CausalVAEModel.from_config('./ckpt/Open-Sora-Plan-v1.0.0/vae/config.json') model = vae.init_from_ckpt('./ckpt/Open-Sora-Plan-v1.0.0/vae/diffusion_pytorch_model.safetensors')
failed again with same error.

Additionally, directly applying pickle returns the same error. So what could be the reason for that? and how to load the checkpoint?

@LinB203
Copy link
Member

LinB203 commented May 27, 2024

CausalVAEModel.from_pretrained('./ckpt/Open-Sora-Plan-v1.0.0/vae/'). It should be a config.json and weight under the folder.

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

No branches or pull requests

2 participants