Team Ai
Apppublic

bchao1/foveated-diffusion

sourceHugging Faceapache-2.0updated 4mo agoView on Hugging Face
1likes
App README

Foveated Diffusion — live demo

Live demo of **Foveated Diffusion: Efficient Spatially Adaptive Image and Video Generation**. Place a circular foveal region you want rendered at high resolution, pick a LoRA adapter, and run a 50-step inference pass through the foveated FLUX.2 pipeline.

  • —Project page: https://bchao1.github.io/foveated-diffusion/
  • —Paper: https://arxiv.org/abs/2603.23491
  • —Code: https://github.com/bchao1/foveated_diffusion
  • —Model weights: https://huggingface.co/bchao1/foveated_diffusion

How to use

  1. 1.Type a prompt and pick a seed.
  2. 2.Choose a LoRA from the dropdown:
  3. 3.no_fov — finetuned baseline, no foveation conditioning (always full-HR).
  4. 4.random — foveation conditioning at random gaze locations.
  5. 5.saliency — saliency-driven foveation masks.
  6. 6.Set the foveal circle: center cx, cy ∈ [-0.5, 0.5] (0 = image center) and radius r (relative to half the image diagonal). With no_fov the controls are disabled — the whole image is rendered HR.
  7. 7.The Tokenization mask preview shows exactly which 32×32-px blocks will be rendered at HR (white) vs LR (gray) before you commit.
  8. 8.Click Generate. The denoising progress bar reports steps k / 50.

Fixed pipeline settings

SettingValue
Resolution1024 × 1024
Steps50
CFG4.0
Decode modemerge
Prediction typeclean
LR downsample factor2
Soft foveation blendon

Hardware

FLUX.2-klein-base-4B + LoRA in bfloat16 needs ~30 GB of VRAM. We recommend running this Space on an L40S (l40sx1) or larger GPU tier. The CPU-Basic free tier cannot host the model.

Citation

bibtex
@misc{chao2026foveateddiffusion,
      title={Foveated Diffusion: Efficient Spatially Adaptive Image and Video Generation},
      author={Brian Chao and Lior Yariv and Howard Xiao and Gordon Wetzstein},
      year={2026},
      eprint={2603.23491},
      archivePrefix={arXiv},
      primaryClass={cs.CV},
      url={https://arxiv.org/abs/2603.23491},
}