FLUX.1 Model Card

FLUX.1 [schnell] Model Card

FLUX.1[schnell] is a 12 billion parameter rectified flow transformer capable of generating images from text descriptions.

Key Features

  • Delivers exceptional output quality and competitive prompt adherence, rivaling closed-source alternatives.
  • Powered by latent adversarial diffusion distillation, FLUX.1 [schnell] produces high-quality images in just 1 to 4 steps.
  • Licensed under Apache 2.0, allowing for personal, scientific, and commercial use.

Usage

A reference implementation of FLUX.1 [schnell], along with sample code, is available in a dedicated GitHub repository. Developers and creatives are encouraged to use this as a foundation for building on FLUX.1 [schnell].

API Endpoints

The FLUX.1 models can also be accessed via API from the following sources:

ComfyUI

FLUX.1 [schnell] is integrated into ComfyUI, enabling local inference through a node-based workflow.

Diffusers

To run FLUX.1 [schnell] with the 🧨 Diffusers Python library, first install or update Diffusers:

pip install -U diffusers

Then, you can use FluxPipeline to execute the model:

import torch
from diffusers import FluxPipeline

pipe = FluxPipeline.from_pretrained("black-forest-labs/FLUX.1-schnell", torch_dtype=torch.bfloat16)
pipe.enable_model_cpu_offload()  # Save VRAM by offloading the model to CPU. Remove this if you have sufficient GPU power.

prompt = "A cat holding a sign that says hello world"
image = pipe(
    prompt,
    guidance_scale=0.0,
    num_inference_steps=4,
    max_sequence_length=256,
    generator=torch.Generator("cpu").manual_seed(0)
).images[0]
image.save("flux-schnell.png")

For further details, refer to the Diffusers documentation.

Limitations

  • This model is not designed to provide factual information.
  • As a statistical model, it may reflect existing societal biases.
  • Prompt adherence may vary, influenced by the style of prompting.

Out-of-Scope Use

The model and its derivatives must not be used:

  • In any way that violates applicable laws or regulations.
  • To exploit, harm, or attempt to harm minors, including creating or distributing child exploitative content.
  • To generate or disseminate false information with the intent to harm.
  • To generate or distribute personally identifiable information that could harm individuals.
  • For harassment, abuse, threats, stalking, or bullying.
  • To create non-consensual nudity or illegal pornographic content.
  • For fully automated decision-making that negatively impacts legal rights or creates binding obligations.
  • To facilitate or generate large-scale disinformation campaigns.

Read other articles:


Posted