-
Notifications
You must be signed in to change notification settings - Fork 31.1k
Closed
Labels
Description
System Info
transformersversion: 4.55.0.dev0- Platform: Linux-6.6.87.2-microsoft-standard-WSL2-x86_64-with-glibc2.35
- Python version: 3.10.12
- Huggingface_hub version: 0.34.3
- Safetensors version: 0.5.3
- Accelerate version: 1.9.0
- Accelerate config: not found
- DeepSpeed version: not installed
- PyTorch version (accelerator?): 2.7.1+cu126 (NA)
- Tensorflow version (GPU?): not installed (NA)
- Flax version (CPU?/GPU?/TPU?): not installed (NA)
- Jax version: not installed
- JaxLib version: not installed
- Using distributed or parallel set-up in script?:
Who can help?
No response
Information
- The official example scripts
- My own modified scripts
Tasks
- An officially supported task in the
examplesfolder (such as GLUE/SQuAD, ...) - My own task or dataset (give details below)
Reproduction
This bug only occurs in the following scenario:
- The user uses a model that uses a tokenizer that can have
additional_chat_templates - The user runs the code without internet connection
- The user did NOT set HF_HUB_OFFLINE=1, so offline mode is not enabled.
One example is running the train_dreambooth_lora_sdxl.py script without any adaptations, like this:
- Download the SDXL model files and the vae model files into the cache
- Turn off internet
- Check that HF_HUB_OFFLINE is unset
- Run the script
The error signature:
requests.exceptions.ConnectionError: (MaxRetryError('HTTPSConnectionPool(...): Max retries exceeded with url: /api/models/stabilityai/stable-diffusion-xl-base-1.0/tree/main/additional_chat_templates?recursive=False&expand=False (Caused by ...)))
Expected behavior
The script works without issues, because all files exist in the cache.