arXiv:2509.15448cs.LGcs.AI2025-09NeurIPS被引 2

提出可统一处理多尺度多模态数据的层次化注意力机制

Hierarchical Self-Attention: Generalizing Neural Attention Mechanics to Multi-Scale Problems

论文配图:Hierarchical Self-Attention: Generalizing Neural Attention Mechanics to Multi-Scale Problems
图 1 · 摘自论文原文
  • 从熵最小化出发,推导出具有层次结构偏置的注意力公式
  • 可在训练中直接使用,也可零样本注入预训练模型提升效率
  • 基于动态规划实现高效计算,适用于图像、视频等多尺度任务

Transformer 及其注意力机制在机器学习领域影响深远。尽管最初用于语言数据,但迅速扩展到图像、视频、图等具有不同信号几何结构的数据模态。然而,将注意力机制推广到呈现多尺度、多模态数据的场景仍具挑战。现有方法多依赖启发式设计,难以泛化至结构不同的问题。本文提出一种数学构造来表示多模态、多尺度数据,并从熵最小化原理出发,推导出神经注意力机制。所提公式在保持与标准 Softmax 注意力接近的同时,融入了层次/几何信息的归纳偏置。进一步提出基于动态规划的高效算法实现该注意力机制。将其嵌入 Transformer 后,不仅可从头训练层次化或多模态模型,还可零样本注入预训练模型,提升效率。

原文摘要 · Abstract (English)

Transformers and their attention mechanism have been revolutionary in the field of Machine Learning. While originally proposed for the language data, they quickly found their way to the image, video, graph, etc. data modalities with various signal geometries. Despite this versatility, generalizing the attention mechanism to scenarios where data is presented at different scales from potentially different modalities is not straightforward. The attempts to incorporate hierarchy and multi-modality within transformers are largely based on ad hoc heuristics, which are not seamlessly generalizable to similar problems with potentially different structures. To address this problem, in this paper, we take a fundamentally different approach: we first propose a mathematical construct to represent multi-modal, multi-scale data. We then mathematically derive the neural attention mechanics for the proposed construct from the first principle of entropy minimization. We show that the derived formulation is optimal in the sense of being the closest to the standard Softmax attention while incorporating the inductive biases originating from the hierarchical/geometric information of the problem. We further propose an efficient algorithm based on dynamic programming to compute our derived attention mechanism. By incorporating it within transformers, we show that the proposed hierarchical attention mechanism not only can be employed to train transformer models in hierarchical/multi-modal settings from scratch, but it can also be used to inject hierarchical information into classical, pre-trained transformer models post training, resulting in more efficient models in zero-shot manner.

注意力机制多尺度Transformer层次结构

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