Skip to content

Commit 54c838e

Browse files
a-r-r-o-wsayakpaul
andcommitted
[docs] Clarify dtypes for Sana (#10248)
update Co-authored-by: Sayak Paul <[email protected]>
1 parent 2e1bd6c commit 54c838e

File tree

1 file changed

+2
-0
lines changed
  • docs/source/en/api/pipelines

1 file changed

+2
-0
lines changed

docs/source/en/api/pipelines/sana.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,8 @@ Available models:
4242

4343
Refer to [this](https://huggingface.co/collections/Efficient-Large-Model/sana-673efba2a57ed99843f11f9e) collection for more information.
4444

45+
Note: The recommended dtype mentioned is for the transformer weights. The text encoder and VAE weights must stay in `torch.bfloat16` or `torch.float32` for the model to work correctly. Please refer to the inference example below to see how to load the model with the recommended dtype.
46+
4547
<Tip>
4648

4749
Make sure to pass the `variant` argument for downloaded checkpoints to use lower disk space. Set it to `"fp16"` for models with recommended dtype as `torch.float16`, and `"bf16"` for models with recommended dtype as `torch.bfloat16`. By default, `torch.float32` weights are downloaded, which use twice the amount of disk storage. Additionally, `torch.float32` weights can be downcasted on-the-fly by specifying the `torch_dtype` argument. Read about it in the [docs](https://huggingface.co/docs/diffusers/v0.31.0/en/api/pipelines/overview#diffusers.DiffusionPipeline.from_pretrained).

0 commit comments

Comments
 (0)