Skip to content

Conversation

@sayakpaul
Copy link
Member

What does this PR do?

Fixes: #7239.

Example training command:

accelerate launch train_dreambooth_lora_sdxl.py \
  --pretrained_model_name_or_path="stabilityai/stable-diffusion-xl-base-1.0"  \
  --instance_data_dir="dog" \
  --pretrained_vae_model_name_or_path="madebyollin/sdxl-vae-fp16-fix" \
  --output_dir="dog-sdxl" \
  --mixed_precision="fp16" \
  --instance_prompt="a photo of sks dog" \
  --resolution=1024 \
  --train_batch_size=1 \
  --gradient_accumulation_steps=4 \
  --learning_rate=1e-4 \
  --report_to="wandb" \
  --lr_scheduler="constant" \
  --lr_warmup_steps=0 \
  --max_train_steps=500 \
  --validation_prompt="A photo of sks dog in a bucket" \
  --validation_epochs=25 \
  --seed="0" \
  --with_prior_preservation --class_data_dir="dog_class" --class_prompt="photo of a dog"

FYI: @shawnrushefsky.

@sayakpaul sayakpaul requested a review from linoytsaban March 7, 2024 06:58
@HuggingFaceDocBuilderDev

The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update.

Copy link
Collaborator

@linoytsaban linoytsaban left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great! sorry for the bug 🐞

@sayakpaul sayakpaul merged commit 0d4dfbb into main Mar 7, 2024
@sayakpaul sayakpaul deleted the fix/prior-preservation-sdxl-dreambooth-lora branch March 7, 2024 09:50
@Evan-Sukhoi
Copy link

The live doc in unavailible currently. Do you remember how it was fixed?

@sayakpaul
Copy link
Member Author

https://github.com/huggingface/diffusers/pull/7242/files explains the changes.

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

Successfully merging this pull request may close these issues.

Dreambooth SDXL LoRA - mat1 and mat2 shapes cannot be multiplied (2x2048 and 2816x1280)

5 participants