Instructions to use weights/flux-fill-dev with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Diffusers
How to use weights/flux-fill-dev with Diffusers:
pip install -U diffusers transformers accelerate
import torch from diffusers import FluxFillPipeline from diffusers.utils import load_image image = load_image("https://huggingface.co/datasets/diffusers/diffusers-images-docs/resolve/main/cup.png") mask = load_image("https://huggingface.co/datasets/diffusers/diffusers-images-docs/resolve/main/cup_mask.png") # switch to "mps" for apple devices pipe = FluxFillPipeline.from_pretrained("weights/flux-fill-dev", dtype=torch.bfloat16, device_map="cuda") image = pipe( prompt="a white paper cup", image=image, mask_image=mask, height=1632, width=1232, guidance_scale=30, num_inference_steps=50, max_sequence_length=512, generator=torch.Generator("cpu").manual_seed(0) ).images[0] image.save(f"flux-fill-dev.png") - Notebooks
- Google Colab
- Kaggle
Download vae/diffusion_pytorch_model.safetensors from weights/flux-fill-dev: direct link, hf CLI and curl.
- Browser
- Download file 335 MB
-
https://huggingface.co/weights/flux-fill-dev/resolve/main/vae/diffusion_pytorch_model.safetensors
- Command line
-
hf download hf://weights/flux-fill-dev/vae/diffusion_pytorch_model.safetensors
-
curl -L -o diffusion_pytorch_model.safetensors https://huggingface.co/weights/flux-fill-dev/resolve/main/vae/diffusion_pytorch_model.safetensors
335 MB
- Xet hash:
- a73a2c5c5dd12d0d1134decadb6020e2110fe5f4ad32b6fa8eda5d17e1910ce9
- Size of remote file:
- 335 MB
- SHA256:
- 8c717328c8ad41faab2ccfd52ae17332505c6833cf176aad56e7b58f2c4d4c94
·
Xet efficiently stores Large Files inside Git, intelligently splitting files into unique chunks and accelerating uploads and downloads. More info.