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

cannot import name 'cached_download' from 'huggingface_hub' #44

Open
terracottahaniwa opened this issue Dec 31, 2024 · 1 comment
Open

Comments

@terracottahaniwa
Copy link

I can't run train_lora.py and get this error.
My solution was appending huggingface-hub==0.25.2 into the requirements.txt.

huggingface/huggingface_hub#2617

@Wauplin
Copy link

Wauplin commented Jan 15, 2025

Hey there, maintainer of huggingface_hub here. Sorry for all the trouble this breaking change introduced. The best
-and future proof- solution to fix this is to upgrade diffusers version to a more recent version (>=0.29.0).

pip install "diffusers>=0.29.0"

This fixed version dates back to June 2024. The issue with pinning huggingface_hub to an old version is that it might conflict with future versions of diffusers/transformers.

Hope this will prove useful 🙏

Wauplin added a commit to Wauplin/LECO that referenced this issue Jan 15, 2025
As mentioned in p1atdev#44 (comment), it is more future-proof to upgrade `diffusers` version rather than downgrading `huggingface_hub` to an old one. This will also fix the `cannot import name 'cached_download' from 'huggingface_hub'` issue without relying on outdated packages.
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