Skip to main content
QUICK REVIEW

[论文解读] Dynamic Inference with Neural Interpreters

Nasim Rahaman, Muhammad Waleed Gondal|arXiv (Cornell University)|Oct 12, 2021
Topic Modeling参考文献 47被引用 9
一句话总结

本文提出神经解释器(Neural Interpreters),一种基于自注意力机制的架构,将推理过程分解为动态路由、可重用的计算模块(称为'函数')。通过端到端学习这些函数的组合,模型实现了强大的系统性泛化能力与样本高效的 few-shot 适应能力,在视觉推理任务中对分布外数据的泛化性能优于视觉变换器(Vision Transformers),同时在推理时可实现计算量与准确率之间的动态权衡。

ABSTRACT

Modern neural network architectures can leverage large amounts of data to generalize well within the training distribution. However, they are less capable of systematic generalization to data drawn from unseen but related distributions, a feat that is hypothesized to require compositional reasoning and reuse of knowledge. In this work, we present Neural Interpreters, an architecture that factorizes inference in a self-attention network as a system of modules, which we call \emph{functions}. Inputs to the model are routed through a sequence of functions in a way that is end-to-end learned. The proposed architecture can flexibly compose computation along width and depth, and lends itself well to capacity extension after training. To demonstrate the versatility of Neural Interpreters, we evaluate it in two distinct settings: image classification and visual abstract reasoning on Raven Progressive Matrices. In the former, we show that Neural Interpreters perform on par with the vision transformer using fewer parameters, while being transferrable to a new task in a sample efficient manner. In the latter, we find that Neural Interpreters are competitive with respect to the state-of-the-art in terms of systematic generalization

研究动机与目标

  • 为解决深度神经网络在分布外数据上系统性泛化能力有限的问题,特别是在组合性推理任务中。
  • 通过引入模块化、基于函数的推理机制,缓解注意力机制与 CNN/RNN 架构中刚性计算重用模式的限制。
  • 通过可重用、可组合的计算单元,实现样本高效的 few-shot 适应与训练后能力扩展。
  • 证明所学的模块化计算能够同时支持分布内与分布外的泛化,适用于视觉与抽象推理任务。
  • 通过消融实验与可视化,探究可重组计算原语的可解释性与可学习性。

提出的方法

  • 将自注意力网络分解为一组可学习的函数,每个函数作为计算模块。
  • 输入以标记集合的形式处理,通过可微分的路由机制动态选择并按序组合函数。
  • 函数应用过程可微分且支持端到端训练,使模型能够基于输入上下文学习应应用哪些函数及其顺序。
  • 该架构对输入集合大小与函数数量无依赖,支持在预训练后通过添加新函数实现非破坏性的容量扩展。
  • 通过调整函数迭代次数,支持任意时间推理(anytime inference),实现在推理时的性能-计算量动态权衡。
  • 该方法在图像分类与视觉抽象推理(Raven’s Progressive Matrices)任务上进行评估,并与 ViT 及其他 SOTA 模型进行比较。

实验结果

研究问题

  • RQ1神经架构能否学习通过可重用、模块化的函数序列动态路由输入,以提升系统性泛化能力?
  • RQ2神经解释器的模块化归纳偏置是否能带来优于标准注意力机制的 few-shot 适应能力与分布外泛化性能?
  • RQ3通过调整函数迭代次数,模型能否在性能与计算量之间实现优雅的权衡,作为任意时间预测器运行?
  • RQ4所学习的函数是否对应于可解释、可重组的计算原语,从而支持组合性推理?
  • RQ5在预训练后,随着容量增加(如增加更多函数),模型性能如何变化?

主要发现

  • 在 PGM 数据集上,神经解释器达到 77.0% 的测试准确率,优于视觉变换器(分布内 72.7%,测试 70.5%),并在 6 个数据集中的 4 个上实现了分布外泛化的 SOTA 性能。
  • 当仅使用一半计算量时,模型仍保持超过原始性能的 80%,证明其具备强大的任意时间推理能力。
  • 在视觉推理基准测试中,神经解释器在 'Extra.' 模式下达到 91.8% 的准确率,优于视觉变换器(分布内 92.2%,测试 16.4%),在分布外泛化方面表现更优。
  • 在 few-shot 图像分类任务中,神经解释器以更少参数达到与 ViT 相当的性能,并展现出强大的样本高效迁移学习能力。
  • 消融实验表明,多种超参数设置均能实现有效的路由;可视化结果揭示了稳定且可解释的函数使用模式。
  • 模型实现了非破坏性的容量扩展:可在不重新训练整个网络的前提下添加新函数并进行微调。

更好的研究,从现在开始

从阅读论文到最终审阅,大幅缩短您的研究时间。

无需绑定信用卡

本解读由 AI 生成,并经人工编辑审核。