Unverified Commit edcbe803 authored by Álvaro Somoza's avatar Álvaro Somoza Committed by GitHub
Browse files

Fix huggingface-hub failing tests (#11994)

* login

* more logins

* uploads

* missed login

* another missed login

* downloads

* examples and more logins

* fix

* setup

* Apply style fixes

* fix

* Apply style fixes
parent c02c4a6d
...@@ -101,7 +101,7 @@ accelerate launch train_dreambooth_lora_lumina2.py \ ...@@ -101,7 +101,7 @@ accelerate launch train_dreambooth_lora_lumina2.py \
For using `push_to_hub`, make you're logged into your Hugging Face account: For using `push_to_hub`, make you're logged into your Hugging Face account:
```bash ```bash
huggingface-cli login hf auth login
``` ```
To better track our training experiments, we're using the following flags in the command above: To better track our training experiments, we're using the following flags in the command above:
......
...@@ -101,7 +101,7 @@ accelerate launch train_dreambooth_lora_sana.py \ ...@@ -101,7 +101,7 @@ accelerate launch train_dreambooth_lora_sana.py \
For using `push_to_hub`, make you're logged into your Hugging Face account: For using `push_to_hub`, make you're logged into your Hugging Face account:
```bash ```bash
huggingface-cli login hf auth login
``` ```
To better track our training experiments, we're using the following flags in the command above: To better track our training experiments, we're using the following flags in the command above:
......
...@@ -8,7 +8,7 @@ The `train_dreambooth_sd3.py` script shows how to implement the training procedu ...@@ -8,7 +8,7 @@ The `train_dreambooth_sd3.py` script shows how to implement the training procedu
> As the model is gated, before using it with diffusers you first need to go to the [Stable Diffusion 3 Medium Hugging Face page](https://huggingface.co/stabilityai/stable-diffusion-3-medium-diffusers), fill in the form and accept the gate. Once you are in, you need to log in so that your system knows you’ve accepted the gate. Use the command below to log in: > As the model is gated, before using it with diffusers you first need to go to the [Stable Diffusion 3 Medium Hugging Face page](https://huggingface.co/stabilityai/stable-diffusion-3-medium-diffusers), fill in the form and accept the gate. Once you are in, you need to log in so that your system knows you’ve accepted the gate. Use the command below to log in:
```bash ```bash
huggingface-cli login hf auth login
``` ```
This will also allow us to push the trained model parameters to the Hugging Face Hub platform. This will also allow us to push the trained model parameters to the Hugging Face Hub platform.
......
...@@ -807,7 +807,7 @@ def main(args): ...@@ -807,7 +807,7 @@ def main(args):
if args.report_to == "wandb" and args.hub_token is not None: if args.report_to == "wandb" and args.hub_token is not None:
raise ValueError( raise ValueError(
"You cannot use both --report_to=wandb and --hub_token due to a security risk of exposing your token." "You cannot use both --report_to=wandb and --hub_token due to a security risk of exposing your token."
" Please use `huggingface-cli login` to authenticate with the Hub." " Please use `hf auth login` to authenticate with the Hub."
) )
logging_dir = Path(args.output_dir, args.logging_dir) logging_dir = Path(args.output_dir, args.logging_dir)
......
...@@ -1013,7 +1013,7 @@ def main(args): ...@@ -1013,7 +1013,7 @@ def main(args):
if args.report_to == "wandb" and args.hub_token is not None: if args.report_to == "wandb" and args.hub_token is not None:
raise ValueError( raise ValueError(
"You cannot use both --report_to=wandb and --hub_token due to a security risk of exposing your token." "You cannot use both --report_to=wandb and --hub_token due to a security risk of exposing your token."
" Please use `huggingface-cli login` to authenticate with the Hub." " Please use `hf auth login` to authenticate with the Hub."
) )
if torch.backends.mps.is_available() and args.mixed_precision == "bf16": if torch.backends.mps.is_available() and args.mixed_precision == "bf16":
......
...@@ -756,7 +756,7 @@ def main(args): ...@@ -756,7 +756,7 @@ def main(args):
if args.report_to == "wandb" and args.hub_token is not None: if args.report_to == "wandb" and args.hub_token is not None:
raise ValueError( raise ValueError(
"You cannot use both --report_to=wandb and --hub_token due to a security risk of exposing your token." "You cannot use both --report_to=wandb and --hub_token due to a security risk of exposing your token."
" Please use `huggingface-cli login` to authenticate with the Hub." " Please use `hf auth login` to authenticate with the Hub."
) )
logging_dir = Path(args.output_dir, args.logging_dir) logging_dir = Path(args.output_dir, args.logging_dir)
......
...@@ -1051,7 +1051,7 @@ def main(args): ...@@ -1051,7 +1051,7 @@ def main(args):
if args.report_to == "wandb" and args.hub_token is not None: if args.report_to == "wandb" and args.hub_token is not None:
raise ValueError( raise ValueError(
"You cannot use both --report_to=wandb and --hub_token due to a security risk of exposing your token." "You cannot use both --report_to=wandb and --hub_token due to a security risk of exposing your token."
" Please use `huggingface-cli login` to authenticate with the Hub." " Please use `hf auth login` to authenticate with the Hub."
) )
if torch.backends.mps.is_available() and args.mixed_precision == "bf16": if torch.backends.mps.is_available() and args.mixed_precision == "bf16":
......
...@@ -1199,7 +1199,7 @@ def main(args): ...@@ -1199,7 +1199,7 @@ def main(args):
if args.report_to == "wandb" and args.hub_token is not None: if args.report_to == "wandb" and args.hub_token is not None:
raise ValueError( raise ValueError(
"You cannot use both --report_to=wandb and --hub_token due to a security risk of exposing your token." "You cannot use both --report_to=wandb and --hub_token due to a security risk of exposing your token."
" Please use `huggingface-cli login` to authenticate with the Hub." " Please use `hf auth login` to authenticate with the Hub."
) )
if torch.backends.mps.is_available() and args.mixed_precision == "bf16": if torch.backends.mps.is_available() and args.mixed_precision == "bf16":
......
...@@ -936,7 +936,7 @@ def main(args): ...@@ -936,7 +936,7 @@ def main(args):
if args.report_to == "wandb" and args.hub_token is not None: if args.report_to == "wandb" and args.hub_token is not None:
raise ValueError( raise ValueError(
"You cannot use both --report_to=wandb and --hub_token due to a security risk of exposing your token." "You cannot use both --report_to=wandb and --hub_token due to a security risk of exposing your token."
" Please use `huggingface-cli login` to authenticate with the Hub." " Please use `hf auth login` to authenticate with the Hub."
) )
if torch.backends.mps.is_available() and args.mixed_precision == "bf16": if torch.backends.mps.is_available() and args.mixed_precision == "bf16":
......
...@@ -859,7 +859,7 @@ def main(args): ...@@ -859,7 +859,7 @@ def main(args):
if args.report_to == "wandb" and args.hub_token is not None: if args.report_to == "wandb" and args.hub_token is not None:
raise ValueError( raise ValueError(
"You cannot use both --report_to=wandb and --hub_token due to a security risk of exposing your token." "You cannot use both --report_to=wandb and --hub_token due to a security risk of exposing your token."
" Please use `huggingface-cli login` to authenticate with the Hub." " Please use `hf auth login` to authenticate with the Hub."
) )
if torch.backends.mps.is_available() and args.mixed_precision == "bf16": if torch.backends.mps.is_available() and args.mixed_precision == "bf16":
......
...@@ -852,7 +852,7 @@ def main(args): ...@@ -852,7 +852,7 @@ def main(args):
if args.report_to == "wandb" and args.hub_token is not None: if args.report_to == "wandb" and args.hub_token is not None:
raise ValueError( raise ValueError(
"You cannot use both --report_to=wandb and --hub_token due to a security risk of exposing your token." "You cannot use both --report_to=wandb and --hub_token due to a security risk of exposing your token."
" Please use `huggingface-cli login` to authenticate with the Hub." " Please use `hf auth login` to authenticate with the Hub."
) )
if torch.backends.mps.is_available() and args.mixed_precision == "bf16": if torch.backends.mps.is_available() and args.mixed_precision == "bf16":
......
...@@ -1063,7 +1063,7 @@ def main(args): ...@@ -1063,7 +1063,7 @@ def main(args):
if args.report_to == "wandb" and args.hub_token is not None: if args.report_to == "wandb" and args.hub_token is not None:
raise ValueError( raise ValueError(
"You cannot use both --report_to=wandb and --hub_token due to a security risk of exposing your token." "You cannot use both --report_to=wandb and --hub_token due to a security risk of exposing your token."
" Please use `huggingface-cli login` to authenticate with the Hub." " Please use `hf auth login` to authenticate with the Hub."
) )
if torch.backends.mps.is_available() and args.mixed_precision == "bf16": if torch.backends.mps.is_available() and args.mixed_precision == "bf16":
......
...@@ -983,7 +983,7 @@ def main(args): ...@@ -983,7 +983,7 @@ def main(args):
if args.report_to == "wandb" and args.hub_token is not None: if args.report_to == "wandb" and args.hub_token is not None:
raise ValueError( raise ValueError(
"You cannot use both --report_to=wandb and --hub_token due to a security risk of exposing your token." "You cannot use both --report_to=wandb and --hub_token due to a security risk of exposing your token."
" Please use `huggingface-cli login` to authenticate with the Hub." " Please use `hf auth login` to authenticate with the Hub."
) )
if args.do_edm_style_training and args.snr_gamma is not None: if args.do_edm_style_training and args.snr_gamma is not None:
......
...@@ -988,7 +988,7 @@ def main(args): ...@@ -988,7 +988,7 @@ def main(args):
if args.report_to == "wandb" and args.hub_token is not None: if args.report_to == "wandb" and args.hub_token is not None:
raise ValueError( raise ValueError(
"You cannot use both --report_to=wandb and --hub_token due to a security risk of exposing your token." "You cannot use both --report_to=wandb and --hub_token due to a security risk of exposing your token."
" Please use `huggingface-cli login` to authenticate with the Hub." " Please use `hf auth login` to authenticate with the Hub."
) )
if torch.backends.mps.is_available() and args.mixed_precision == "bf16": if torch.backends.mps.is_available() and args.mixed_precision == "bf16":
......
...@@ -13,7 +13,7 @@ To incorporate additional condition latents, we expand the input features of Flu ...@@ -13,7 +13,7 @@ To incorporate additional condition latents, we expand the input features of Flu
> As the model is gated, before using it with diffusers you first need to go to the [FLUX.1 [dev] Hugging Face page](https://huggingface.co/black-forest-labs/FLUX.1-dev), fill in the form and accept the gate. Once you are in, you need to log in so that your system knows you’ve accepted the gate. Use the command below to log in: > As the model is gated, before using it with diffusers you first need to go to the [FLUX.1 [dev] Hugging Face page](https://huggingface.co/black-forest-labs/FLUX.1-dev), fill in the form and accept the gate. Once you are in, you need to log in so that your system knows you’ve accepted the gate. Use the command below to log in:
```bash ```bash
huggingface-cli login hf auth login
``` ```
The example command below shows how to launch fine-tuning for pose conditions. The dataset ([`raulc0399/open_pose_controlnet`](https://huggingface.co/datasets/raulc0399/open_pose_controlnet)) being used here already has the pose conditions of the original images, so we don't have to compute them. The example command below shows how to launch fine-tuning for pose conditions. The dataset ([`raulc0399/open_pose_controlnet`](https://huggingface.co/datasets/raulc0399/open_pose_controlnet)) being used here already has the pose conditions of the original images, so we don't have to compute them.
......
...@@ -697,7 +697,7 @@ def main(args): ...@@ -697,7 +697,7 @@ def main(args):
if args.report_to == "wandb" and args.hub_token is not None: if args.report_to == "wandb" and args.hub_token is not None:
raise ValueError( raise ValueError(
"You cannot use both --report_to=wandb and --hub_token due to a security risk of exposing your token." "You cannot use both --report_to=wandb and --hub_token due to a security risk of exposing your token."
" Please use `huggingface-cli login` to authenticate with the Hub." " Please use `hf auth login` to authenticate with the Hub."
) )
logging_out_dir = Path(args.output_dir, args.logging_dir) logging_out_dir = Path(args.output_dir, args.logging_dir)
......
...@@ -725,7 +725,7 @@ def main(args): ...@@ -725,7 +725,7 @@ def main(args):
if args.report_to == "wandb" and args.hub_token is not None: if args.report_to == "wandb" and args.hub_token is not None:
raise ValueError( raise ValueError(
"You cannot use both --report_to=wandb and --hub_token due to a security risk of exposing your token." "You cannot use both --report_to=wandb and --hub_token due to a security risk of exposing your token."
" Please use `huggingface-cli login` to authenticate with the Hub." " Please use `hf auth login` to authenticate with the Hub."
) )
if args.use_lora_bias and args.gaussian_init_lora: if args.use_lora_bias and args.gaussian_init_lora:
raise ValueError("`gaussian` LoRA init scheme isn't supported when `use_lora_bias` is True.") raise ValueError("`gaussian` LoRA init scheme isn't supported when `use_lora_bias` is True.")
......
...@@ -430,7 +430,7 @@ def main(): ...@@ -430,7 +430,7 @@ def main():
if args.report_to == "wandb" and args.hub_token is not None: if args.report_to == "wandb" and args.hub_token is not None:
raise ValueError( raise ValueError(
"You cannot use both --report_to=wandb and --hub_token due to a security risk of exposing your token." "You cannot use both --report_to=wandb and --hub_token due to a security risk of exposing your token."
" Please use `huggingface-cli login` to authenticate with the Hub." " Please use `hf auth login` to authenticate with the Hub."
) )
if args.non_ema_revision is not None: if args.non_ema_revision is not None:
......
...@@ -483,7 +483,7 @@ def main(): ...@@ -483,7 +483,7 @@ def main():
if args.report_to == "wandb" and args.hub_token is not None: if args.report_to == "wandb" and args.hub_token is not None:
raise ValueError( raise ValueError(
"You cannot use both --report_to=wandb and --hub_token due to a security risk of exposing your token." "You cannot use both --report_to=wandb and --hub_token due to a security risk of exposing your token."
" Please use `huggingface-cli login` to authenticate with the Hub." " Please use `hf auth login` to authenticate with the Hub."
) )
if args.non_ema_revision is not None: if args.non_ema_revision is not None:
......
...@@ -41,7 +41,7 @@ For all our examples, we will directly store the trained weights on the Hub, so ...@@ -41,7 +41,7 @@ For all our examples, we will directly store the trained weights on the Hub, so
Run the following command to authenticate your token Run the following command to authenticate your token
```bash ```bash
huggingface-cli login hf auth login
``` ```
We also use [Weights and Biases](https://docs.wandb.ai/quickstart) logging by default, because it is really useful to monitor the training progress by regularly generating sample images during training. To install wandb, run We also use [Weights and Biases](https://docs.wandb.ai/quickstart) logging by default, because it is really useful to monitor the training progress by regularly generating sample images during training. To install wandb, run
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment