arXiv:2510.10489cs.CV2025-10

改进图像生成中的位置编码,让模型更懂物体位置和细节。

Head-wise Adaptive Rotary Positional Encoding for Fine-Grained Image Generation

  • 为旋转位置编码引入可学习的动态频率调整机制
  • 在ImageNet和文本生成任务中显著提升图像质量
  • 无需修改结构,适合各类生成模型快速接入

Transformer依赖显式位置编码来建模数据结构。尽管旋转位置编码(RoPE)在1维任务中表现优异,但在图像生成中仍存在精细空间关系建模、颜色线索捕捉和物体计数能力不足等问题。本文指出标准多维RoPE存在频率分配僵化、轴间独立性及头处理均一化等关键局限。为此提出HARoPE,一种头级自适应扩展方法,在旋转映射前加入基于奇异值分解(SVD)参数化的可学习线性变换。该轻量级修改实现动态频率重分配、旋转平面语义对齐与头级位置感受野定制,同时严格保持RoPE的相对位置特性。在类别条件生成的ImageNet以及文本到图像生成(Flux和MMDiT)任务上,实验表明HARoPE持续优于强基准RoPE及其他扩展方法。该方法可作为即插即用的高效替代方案,为基于Transformer的图像生成模型提供一种原理清晰且灵活的位置感知增强路径。

原文摘要 · Abstract (English)

Transformers rely on explicit positional encoding to model structure in data. While Rotary Position Embedding (RoPE) excels in 1D domains, its application to image generation reveals significant limitations such as fine-grained spatial relation modeling, color cues, and object counting. This paper identifies key limitations of standard multi-dimensional RoPE-rigid frequency allocation, axis-wise independence, and uniform head treatment-in capturing the complex structural biases required for fine-grained image generation. We propose HARoPE, a head-wise adaptive extension that inserts a learnable linear transformation parameterized via singular value decomposition (SVD) before the rotary mapping. This lightweight modification enables dynamic frequency reallocation, semantic alignment of rotary planes, and head-specific positional receptive fields while rigorously preserving RoPE's relative-position property. Extensive experiments on class-conditional ImageNet and text-to-image generation (Flux and MMDiT) demonstrate that HARoPE consistently improves performance over strong RoPE baselines and other extensions. The method serves as an effective drop-in replacement, offering a principled and adaptable solution for enhancing positional awareness in transformer-based image generative models.

位置编码图像生成TransformerRoPE改进

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。