arXiv:2510.03339cs.LGcs.AI2025-10NeurIPS被引 4

剖析池化对Transformer模型的影响,揭示其如何决定性能与泛化能力。

Pool Me Wisely: On the Effect of Pooling in Transformer-Based Models

  • 构建理论框架,推导不同池化方法的表征能力上限。
  • 实证发现池化方式显著影响准确率、敏感性和优化行为。
  • 为视觉、语言、时序任务提供可落地的池化设计指南。

Transformer模型已成为序列建模的主流骨干网络,依赖自注意力机制生成上下文相关的词元表示,通常通过池化操作将其聚合为固定长度向量以用于下游任务。尽管大量研究聚焦于注意力机制,池化的作用仍被低估,但其对模型行为具有关键影响。本文提出一个理论框架,严格刻画采用常见池化方法的Transformer模型的表达能力,推导其表征容量和区分相似输入的能力的闭式边界。分析扩展至不同注意力变体,证明这些边界在多种架构变体中均成立。我们在需要全局与局部上下文理解的任务上,跨计算机视觉、自然语言处理和时间序列三大模态,实证评估多种池化策略。结果揭示了池化选择对精度、敏感性和优化行为的一致影响趋势。研究统一了理论与实证视角,为针对特定任务选择或设计池化机制提供实践指导。本工作将池化定位为Transformer模型的关键组件,为超越注意力机制的更严谨模型设计奠定基础。

原文摘要 · Abstract (English)

Transformer models have become the dominant backbone for sequence modeling, leveraging self-attention to produce contextualized token representations. These are typically aggregated into fixed-size vectors via pooling operations for downstream tasks. While much of the literature has focused on attention mechanisms, the role of pooling remains underexplored despite its critical impact on model behavior. In this paper, we introduce a theoretical framework that rigorously characterizes the expressivity of Transformer-based models equipped with widely used pooling methods by deriving closed-form bounds on their representational capacity and the ability to distinguish similar inputs. Our analysis extends to different variations of attention formulations, demonstrating that these bounds hold across diverse architectural variants. We empirically evaluate pooling strategies across tasks requiring both global and local contextual understanding, spanning three major modalities: computer vision, natural language processing, and time-series analysis. Results reveal consistent trends in how pooling choices affect accuracy, sensitivity, and optimization behavior. Our findings unify theoretical and empirical perspectives, providing practical guidance for selecting or designing pooling mechanisms suited to specific tasks. This work positions pooling as a key architectural component in Transformer models and lays the foundation for more principled model design beyond attention alone.

Transformer池化表征能力模型设计

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