Open Z0rx opened 1 year ago
use the ckpt/safetensors version of the model
same error, ill checked it with "safetensors" in "model download cell"
remove the hf link from the cell when using a ckpt or safetensors
if i want to download a finetune model from HF
it shows me this warning " V1
/content/stable-diffusion-custom
hint: Using 'master' as the name for the initial branch. This default branch name
hint: is subject to change. To configure the initial branch name to use in all
hint: of your new repositories, which will suppress this warning, call:
hint:
hint: git config --global init.defaultBranch
i work with your code since 4 months and this warning never showed up since 2 days ago.
I downloaded the HF model and removed the Link, still dont work
I need a link to the model to test it
you're using the wrong link format
this is the correct link https://huggingface.co/dreamlike-art/dreamlike-photoreal-2.0/resolve/main/dreamlike-photoreal-2.0.safetensors
use "resolve" instead of "blob"
tested it, it works fine
I cant drop the complete link into the text bar
"Load and finetune a model from Hugging Face, use the format "profile/model" like : runwayml/stable-diffusion-v1-5"
code snip
"if Path_to_HuggingFace != "": if authe=="https://": textenc= f"{authe}huggingface.co/{Path_to_HuggingFace}/resolve/main/text_encoder/pytorch_model.bin" txtenc_size=urllib.request.urlopen(textenc).info().get('Content-Length', None) else: textenc= f"https://huggingface.co/{Path_to_HuggingFace}/resolve/main/text_encoder/pytorch_model.bin""
The cell is using /resolve/
i tested with 3 different finetune models directly from github and copying it to my gdrive all giving me this error
Training the UNet...
Traceback (most recent call last):
File "/usr/local/bin/accelerate", line 5, in
Training the UNet... Traceback (most recent call last): File "/usr/local/lib/python3.10/dist-packages/tensorboard/compat/init.py", line 42, in tf from tensorboard.compat import notf # noqa: F401 ImportError: cannot import name 'notf' from 'tensorboard.compat' (/usr/local/lib/python3.10/dist-packages/tensorboard/compat/init.py)
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/local/bin/accelerate", line 5, in
maybe this is usefull?
do a screenshot the the model cell
I did instruct you to not use the path to hugginface and use the safetensors link in the link input box https://huggingface.co/dreamlike-art/dreamlike-photoreal-2.0/resolve/main/dreamlike-photoreal-2.0.safetensors
i could download the model now but training still dont work for me, idk why.
Training the UNet... Traceback (most recent call last): File "/usr/local/lib/python3.10/dist-packages/tensorboard/compat/init.py", line 42, in tf from tensorboard.compat import notf # noqa: F401 ImportError: cannot import name 'notf' from 'tensorboard.compat' (/usr/local/lib/python3.10/dist-packages/tensorboard/compat/init.py)
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/usr/local/bin/accelerate", line 5, in
Since 2 day i got errors if i want to train the UNET
Training the UNet... '########:'########:::::'###::::'####:'##::: ##:'####:'##::: ##::'######::: ... ##..:: ##.... ##:::'## ##:::. ##:: ###:: ##:. ##:: ###:: ##:'##... ##:: ::: ##:::: ##:::: ##::'##:. ##::: ##:: ####: ##:: ##:: ####: ##: ##:::..::: ::: ##:::: ########::'##:::. ##:: ##:: ## ## ##:: ##:: ## ## ##: ##::'####: ::: ##:::: ##.. ##::: #########:: ##:: ##. ####:: ##:: ##. ####: ##::: ##:: ::: ##:::: ##::. ##:: ##.... ##:: ##:: ##:. ###:: ##:: ##:. ###: ##::: ##:: ::: ##:::: ##:::. ##: ##:::: ##:'####: ##::. ##:'####: ##::. ##:. ######::: :::..:::::..:::::..::..:::::..::....::..::::..::....::..::::..:::......::::
0% 0/3500 [00:00<?, ?it/s] asosa asosa Traceback (most recent call last): File "/content/diffusers/examples/dreambooth/train_dreambooth.py", line 803, in
main()
File "/content/diffusers/examples/dreambooth/train_dreambooth.py", line 723, in main
accelerator.clip_gradnorm(params_to_clip, args.max_grad_norm)
File "/usr/local/lib/python3.10/dist-packages/accelerate/accelerator.py", line 920, in clip_gradnorm
self.unscale_gradients()
File "/usr/local/lib/python3.10/dist-packages/accelerate/accelerator.py", line 904, in unscalegradients
self.scaler.unscale(opt)
File "/usr/local/lib/python3.10/dist-packages/torch/cuda/amp/gradscaler.py", line 284, in unscale
optimizer_state["found_inf_per_device"] = self._unscalegrads(optimizer, inv_scale, found_inf, False)
File "/usr/local/lib/python3.10/dist-packages/torch/cuda/amp/grad_scaler.py", line 212, in _unscalegrads
raise ValueError("Attempting to unscale FP16 gradients.")
ValueError: Attempting to unscale FP16 gradients.
0% 0/3500 [00:02<?, ?it/s]
Traceback (most recent call last):
File "/usr/local/bin/accelerate", line 8, in
sys.exit(main())
File "/usr/local/lib/python3.10/dist-packages/accelerate/commands/accelerate_cli.py", line 43, in main
args.func(args)
File "/usr/local/lib/python3.10/dist-packages/accelerate/commands/launch.py", line 837, in launch_command
simple_launcher(args)
File "/usr/local/lib/python3.10/dist-packages/accelerate/commands/launch.py", line 354, in simple_launcher
raise subprocess.CalledProcessError(returncode=process.returncode, cmd=cmd)
subprocess.CalledProcessError: Command '['/usr/bin/python3', '/content/diffusers/examples/dreambooth/train_dreambooth.py', '--image_captions_filename', '--train_only_unet', '--save_starting_step=500', '--save_n_steps=500', '--Session_dir=/content/gdrive/MyDrive/Fast-Dreambooth/Sessions/asosa', '--pretrained_model_name_or_path=/content/stable-diffusion-custom', '--instance_data_dir=/content/gdrive/MyDrive/Fast-Dreambooth/Sessions/asosa/instance_images', '--output_dir=/content/models/asosa', '--captions_dir=/content/gdrive/MyDrive/Fast-Dreambooth/Sessions/asosa/captions', '--instance_prompt=', '--seed=196321', '--resolution=768', '--mixed_precision=fp16', '--train_batch_size=1', '--gradient_accumulation_steps=1', '--use_8bit_adam', '--learning_rate=2e-06', '--lr_scheduler=linear', '--lr_warmup_steps=0', '--max_train_steps=3500']' returned non-zero exit status 1.