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

from diffusers.loaders.autoencoder import FromOriginalVAEMixin fails with ImportError #8432

Closed
juancamilog opened this issue Jun 7, 2024 · 6 comments

Comments

@juancamilog
Copy link

juancamilog commented Jun 7, 2024

On 0.28.2, this

from diffusers.loaders.autoencoder import FromOriginalVAEMixin

will fail with this error

ImportError: cannot import name 'create_diffusers_vae_model_from_ldm' from 'diffusers.loaders.single_file_utils' (/usr/local/lib/python3.10/dist-packages/diffusers/loaders/single_file_utils.py)

If you look at the source code, create_diffusers_vae_model_from_ldm imported here:

create_diffusers_vae_model_from_ldm,

does not exist here: https://github.com/huggingface/diffusers/blob/0d68ddf3275b20b0d12cfd3d0a9f002fecfe001c/src/diffusers/loaders/single_file_utils.py

This commit removed it: cb0f3b4#diff-46dbaee212aec178869ccc3db97f026579819d5fbffbd4321e7063cf472139f8

@sayakpaul
Copy link
Member

Cc: @DN6

@NeoGriever
Copy link

Possible Fix:

from diffusers.loaders.autoencoder import FromOriginalVAEMixin

to

from diffusers.loaders.single_file_model import FromOriginalModelMixin

because in the commit is it replaced with it at the same way?

@sayakpaul
Copy link
Member

@DN6 a gentle reminder :)

@DN6
Copy link
Collaborator

DN6 commented Jul 3, 2024

Hi sorry this should have been removed in 0.28. This PR: #8754 removes these deprecated classes in favour of FromOrignalModelMixin

Copy link

This issue has been automatically marked as stale because it has not had recent activity. If you think this still needs to be addressed please comment on this thread.

Please note that issues that do not follow the contributing guidelines are likely to be ignored.

@github-actions github-actions bot added the stale Issues that haven't received updates label Sep 14, 2024
@a-r-r-o-w a-r-r-o-w removed the stale Issues that haven't received updates label Oct 20, 2024
@a-r-r-o-w
Copy link
Member

Closing due to inactivity and because it looks like this was answered. Feel free to re-open if there's anything else not addressed sufficiently

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

5 participants