GitHunt
VA

vaibhavpandeyvpz/flux.1-text-to-image

Generate stunning images from text prompts using FLUX.1 [dev], a 12B parameter rectified flow transformer guidance-distilled from FLUX.1 [pro].


title: FLUX.1 Text to Image
emoji: ๐ŸŽจ
colorFrom: purple
colorTo: red
sdk: gradio
sdk_version: 5.44.0
app_file: app.py
pinned: true
license: apache-2.0
short_description: Generate high-quality images from text using FLUX.1 [dev]

FLUX.1 [dev] Text to Image

Generate stunning images from text prompts using FLUX.1 [dev], a 12B parameter rectified flow transformer guidance-distilled from FLUX.1 [pro].

Features

  • Live Preview: Watch your image generate in real-time with intermediate previews
  • Dual VAE Support: Choose between fast preview VAE or high-quality VAE for final output
  • Advanced Controls: Fine-tune generation with guidance scale, inference steps, and custom dimensions
  • High Resolution: Generate images up to 2048x2048 pixels

Model Information

Setup

Authentication

This model requires accepting the license agreement on Hugging Face. To authenticate:

  1. Go to FLUX.1-dev model page and accept the license
  2. Create a Hugging Face token at https://huggingface.co/settings/tokens
  3. In your Hugging Face Space settings, add a secret named HF_TOKEN with your token value

The code will automatically use the token from the environment variable to authenticate when loading the model.

Usage

  1. Enter your text prompt in the input field
  2. Adjust settings in the "Model Features" and "Advanced Settings" accordions
  3. Click "Generate" or press Enter
  4. Watch the live preview (if enabled) and get your final high-quality image

Technical Details

  • Uses TAEF1 VAE for fast live previews
  • Uses FLUX.1-dev VAE for high-quality final output
  • Supports custom dimensions, guidance scale, and inference steps
  • Optimized for GPU acceleration with CUDA support
  • ZeroGPU enabled for efficient GPU resource management on Hugging Face Spaces

Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference