Table of Contents
Fetching ...

Learning Flow Fields in Attention for Controllable Person Image Generation

Zijian Zhou, Shikun Liu, Xiao Han, Haozhe Liu, Kam Woh Ng, Tian Xie, Yuren Cong, Hang Li, Mengmeng Xu, Juan-Manuel Pérez-Rúa, Aditya Patel, Tao Xiang, Miaojing Shi, Sen He

TL;DR

This work addresses texture-level distortions in controllable person image generation by introducing Leffa, a regularization loss that learns flow fields in attention to guide the target query toward the correct reference regions during training. Implemented on top of a diffusion-based baseline, Leffa warps the reference using learned flow fields derived from attention maps and supervises the warp to match the target region, without changing inference cost. The method yields state-of-the-art results in both appearance (virtual try-on) and pose control (pose transfer) across multiple datasets and diffusion backbones, and it generalizes to other diffusion models. This attention-flow supervision provides a practical, model-agnostic path to preserve fine-grained details while maintaining high image quality, with broad implications for controllable generation tasks in vision-rich applications.

Abstract

Controllable person image generation aims to generate a person image conditioned on reference images, allowing precise control over the person's appearance or pose. However, prior methods often distort fine-grained textural details from the reference image, despite achieving high overall image quality. We attribute these distortions to inadequate attention to corresponding regions in the reference image. To address this, we thereby propose learning flow fields in attention (Leffa), which explicitly guides the target query to attend to the correct reference key in the attention layer during training. Specifically, it is realized via a regularization loss on top of the attention map within a diffusion-based baseline. Our extensive experiments show that Leffa achieves state-of-the-art performance in controlling appearance (virtual try-on) and pose (pose transfer), significantly reducing fine-grained detail distortion while maintaining high image quality. Additionally, we show that our loss is model-agnostic and can be used to improve the performance of other diffusion models.

Learning Flow Fields in Attention for Controllable Person Image Generation

TL;DR

This work addresses texture-level distortions in controllable person image generation by introducing Leffa, a regularization loss that learns flow fields in attention to guide the target query toward the correct reference regions during training. Implemented on top of a diffusion-based baseline, Leffa warps the reference using learned flow fields derived from attention maps and supervises the warp to match the target region, without changing inference cost. The method yields state-of-the-art results in both appearance (virtual try-on) and pose control (pose transfer) across multiple datasets and diffusion backbones, and it generalizes to other diffusion models. This attention-flow supervision provides a practical, model-agnostic path to preserve fine-grained details while maintaining high image quality, with broad implications for controllable generation tasks in vision-rich applications.

Abstract

Controllable person image generation aims to generate a person image conditioned on reference images, allowing precise control over the person's appearance or pose. However, prior methods often distort fine-grained textural details from the reference image, despite achieving high overall image quality. We attribute these distortions to inadequate attention to corresponding regions in the reference image. To address this, we thereby propose learning flow fields in attention (Leffa), which explicitly guides the target query to attend to the correct reference key in the attention layer during training. Specifically, it is realized via a regularization loss on top of the attention map within a diffusion-based baseline. Our extensive experiments show that Leffa achieves state-of-the-art performance in controlling appearance (virtual try-on) and pose (pose transfer), significantly reducing fine-grained detail distortion while maintaining high image quality. Additionally, we show that our loss is model-agnostic and can be used to improve the performance of other diffusion models.

Paper Structure

This paper contains 25 sections, 5 equations, 8 figures, 9 tables.

Figures (8)

  • Figure 1: We present Leffa, a unified framework for controllable person image generation that enables precise manipulation of both appearance (i.e., virtual try-on) and pose (i.e., pose transfer). Leffa's generated images demonstrate high quality, with fine details preserved and minimal texture distortion. Please zoom in for better viewing.
  • Figure 2: Taking appearance control of a person image (virtual try-on) as an example: (a) input person and reference (garment) images; (b) generated image and attention map from a diffusion-based method (e.g., IDM-VTON choi2024improving); (c) generated image after manually modifying the attention map in the diffusion-based method to focus on the correct regions; (d) generated image and attention map from Leffa. Our method generates high-quality images without detail distortion (see the colored striped texture).
  • Figure 3: An overview of our Leffa training pipeline for controllable person image generation. The left is our diffusion-based baseline; the right is our Leffa loss. Note that $I_\text{src}$ and $I_\text{tgt}$ are the same image during training.
  • Figure 4: Qualitative visual results comparison with other methods. The input person image for the pose transfer is generated using our method in the virtual try-on. The visualization results demonstrate that our method not only generates high-quality images but also greatly reduces the distortion of fine-grained details. Please zoom in for better viewing.
  • Figure 5: Ablation study for (a) Leffa loss weight $\lambda_{\text{leffa}}$, (b) resolution threshold $\theta_{\text{resolution}}$, (c) timestep threshold $\theta_{\text{timestep}}$, (d) temperature $\tau$ on VITON-HD dataset of virtual try-on.
  • ...and 3 more figures