Hugging Face's logo Hugging Face
  • Models
  • Datasets
  • Spaces
  • Buckets new
  • Docs
  • Enterprise
  • Pricing

  • Log In
  • Sign Up

black-forest-labs
/
FLUX.2-small-decoder

Image-to-Image
Diffusers
Safetensors
Diffusion Single File
English
text-to-image
image-editing
flux
Model card Files Files and versions
xet
Community
2

Instructions to use black-forest-labs/FLUX.2-small-decoder with libraries, inference providers, notebooks, and local apps. Follow these links to get started.

  • Libraries
  • Diffusers

    How to use black-forest-labs/FLUX.2-small-decoder with Diffusers:

    pip install -U diffusers transformers accelerate
    import torch
    from diffusers import DiffusionPipeline
    from diffusers.utils import load_image
    
    # switch to "mps" for apple devices
    pipe = DiffusionPipeline.from_pretrained("black-forest-labs/FLUX.2-small-decoder", dtype=torch.bfloat16, device_map="cuda")
    
    prompt = "Turn this cat into a dog"
    input_image = load_image("https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/diffusers/cat.png")
    
    image = pipe(image=input_image, prompt=prompt).images[0]
  • Diffusion Single File

    How to use black-forest-labs/FLUX.2-small-decoder with Diffusion Single File:

    # No code snippets available yet for this library.
    
    # To use this model, check the repository files and the library's documentation.
    
    # Want to help? PRs adding snippets are welcome at:
    # https://github.com/huggingface/huggingface.js
  • Notebooks
  • Google Colab
  • Kaggle
FLUX.2-small-decoder
619 MB
Ctrl+K
Ctrl+K
  • 3 contributors
History: 12 commits
stephenbtl's picture
stephenbtl
Update README.md
a3efc24 verified about 1 month ago
  • .gitattributes
    1.75 kB
    Upload comparison_panel.jpeg about 1 month ago
  • README.md
    3.86 kB
    Update README.md about 1 month ago
  • compare_full_decoder.png
    1.25 MB
    xet
    Upload 3 files about 1 month ago
  • compare_small_decoder.png
    1.26 MB
    xet
    Upload 3 files about 1 month ago
  • comparison_panel.jpeg
    3.54 MB
    xet
    Upload comparison_panel.jpeg about 1 month ago
  • config.json
    842 Bytes
    Upload 4 files about 1 month ago
  • diffusion_pytorch_model.safetensors
    250 MB
    xet
    Upload 4 files about 1 month ago
  • editing.jpg
    2.51 MB
    xet
    Upload 3 files about 1 month ago
  • full_encoder_small_decoder.safetensors
    250 MB
    xet
    Upload 4 files about 1 month ago
  • small_decoder.safetensors
    112 MB
    xet
    Upload 4 files about 1 month ago