🗜️Extract LoRA

Create lightweight LoRA files extracted from full Stable Diffusion models

dreamlook.ai lets you finetune Stable Diffusion models in minutes (first SD1.5 run is free!) Follow this guide to create LoRA files from your own images on dreamlook.ai.

LoRA files: a smaller alternative to full checkpoints

When finetuning Stable Diffusion models, the trained models are huge files of at least 2 GB. It can be a challenge to download, store and load such files if you train hundreds of models!

LoRA files allow you to train only some of the parameters of the model, which result in a 75 MB file. The result is not as good as when training the full model, but the result is much more manageable. This can be a good trade-off in some situations.

Another advantage of LoRA files is that you can use multiple LoRAs at the same time when doing image generation, and you can even specify different weights for each of them (which can be positive or negative).

What are extracted LoRAs?

There are two ways to get LoRA files:

  1. Train the full model, then extract a LoRA file from it. In this method you allow full finetuning of the base model and then extract a LoRA model from the finetuned model. Technically speaking, this can be achieved by running SVD on the the finetuned model checkpoint weights. This is what we offer on dreamlook.ai.

  2. Fine-tune LoRA models natively. You can train LoRA models directly with relatively minimal resources, using libraries such as Kohya's GUI (https://github.com/bmaltais/kohya_ss). We currently don't offer native LoRA finetuning on dreamlook.ai.

Extracted LoRAs give better results than native LoRAs. They require more resources, as you need to train the full model, but this is something we do very efficiently on dreamlook.ai (models can be trained in minutes).

LoRA files extracted on dreamlook.ai have rank 64, which results in a 75 MB file.

How do I use extracted LoRA on dreamlook.ai?

There is no extra cost to extract a LoRA file when training a model on dreamlook.ai, but it is disabled by default so you need to explicitly turn on this option.

  1. Head to https://dreamlook.ai/dreambooth and enable "Expert mode"

  2. Configure your training run as usual: see Train models

  3. Enable the option "Extract LoRA" under "Advanced settings":

For API users, you can set the option extract_lora to original. This option is set to disabled by default, which means LoRA extraction does not happen.

Last updated