Skip to content

A gradio tool to visualize the attntion maps in StableDiffusion-XL model

Notifications You must be signed in to change notification settings

raywang335/attention_visualization_sdxl

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

A gradio tool for visualizing attention maps in SDXL

Prerequisites

  1. Install dependencies >> requirement.txt
  2. python sdxl_attn_visualizer_gradio.py

Usage

./docs/page.png

  1. Input the prompt and choose the path of sdxl model (format: .safetensors).
  2. Click "Run" button.
  3. Choose the layer and token_idx for visualization.
  4. The "group attn maps" means the attention maps in the same block.
  5. Clear button will clear both model and attention map cache.

Demo

./docs/demo.png

About

A gradio tool to visualize the attntion maps in StableDiffusion-XL model

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages