Skip to main content
QUICK REVIEW

[论文解读] Lipschitz regularity of deep neural networks: analysis and efficient estimation

Kevin Scaman, Aladin Virmaux|arXiv (Cornell University)|May 28, 2018
Adversarial Robustness in Machine Learning参考文献 24被引用 135
一句话总结

本文证明神经网络的精确 Lipschitz 计算是 NP-hard,并提出 AutoLip 和 SeqLip,以有效地对自动可微函数的 Lipschitz 常数进行上界估计,实验表明 SeqLip 在各种架构上显著改进 AutoLip 的界限,并附有 PyTorch 实现。

ABSTRACT

Deep neural networks are notorious for being sensitive to small well-chosen perturbations, and estimating the regularity of such architectures is of utmost importance for safe and robust practical applications. In this paper, we investigate one of the key characteristics to assess the regularity of such methods: the Lipschitz constant of deep learning architectures. First, we show that, even for two layer neural networks, the exact computation of this quantity is NP-hard and state-of-art methods may significantly overestimate it. Then, we both extend and improve previous estimation methods by providing AutoLip, the first generic algorithm for upper bounding the Lipschitz constant of any automatically differentiable function. We provide a power method algorithm working with automatic differentiation, allowing efficient computations even on large convolutions. Second, for sequential neural networks, we propose an improved algorithm named SeqLip that takes advantage of the linear computation graph to split the computation per pair of consecutive layers. Third we propose heuristics on SeqLip in order to tackle very large networks. Our experiments show that SeqLip can significantly improve on the existing upper bounds. Finally, we provide an implementation of AutoLip in the PyTorch environment that may be used to better estimate the robustness of a given neural network to small perturbations or regularize it using more precise Lipschitz estimations.

研究动机与目标

  • 动机化并将 Lipschitz 正则化形式化为衡量神经网络鲁棒性的方法。
  • 证明即使对于简单网络,精确的 Lipschitz 常数计算也 NP-hard。
  • 开发面向自动可微函数的实用上界估计器 AutoLip 和 SeqLip。
  • 提供高效、与可微分计算图兼容的实现,用于计算 Lipschitz 上界。
  • 在常见结构上评估方法,并提供一个开源的 PyTorch 实现。

提出的方法

  • 为向量值函数定义 Lipschitz 常数,并将其与雅可比算子的算子范数联系起来(通过 Rademacher 定理)。
  • 给出带 ReLU 的两层多层感知机的精确 Lipschitz 计算的 NP-hard 性,进而为上界方法提供动机。
  • 引入 AutoLip:一种通过对计算图进行自动微分来对 L(f) 进行上界的算法(算法 1)。
  • 扩展基于幂方法的方法,通过自动梯度计算仿射层(线性/卷积)的谱范数(算法 2)。
  • 开发 SeqLip:通过按层拆分计算图并使用基于 SVD 的分解(式 Eq. 8)为序列网络提供改进的上界。
  • 提出贪心式 SeqLip 以及对大层的低秩近似以控制复杂度;提供理论直觉和界(定理 3)。
  • 讨论常见层(激活、池化、归一化)的具体 Lipschitz 常数,并提供实现的实用说明。

实验结果

研究问题

  • RQ1神经网络的精确 Lipschitz 常数是否可以在多项式时间内计算?
  • RQ2如何对像神经网络这样的自动可微函数的 Lipschitz 常数进行上界?
  • RQ3是否可以在序列网络上改进现有的 Lipschitz 上界,超越简单的逐层乘积?
  • RQ4AutoLip 和 SeqLip 在标准结构(MLP、CNN、AlexNet)上的表现如何,是否可以在 PyTorch 中实现?
  • RQ5有哪些理论保证可以解释何时 SeqLip 相对于 AutoLip 提供显著改进?

主要发现

  • 精确的 Lipschitz 计算即使对于带 ReLU 的简单两层 MLP 也是 NP-hard。
  • AutoLip 为任何自动可微函数的 Lipschitz 常数提供通用上界。
  • SeqLip 通过利用计算图结构和逐层分解,为序列网络提供更紧的上界。
  • SeqLip 在实践中能显著缩小 AutoLip 上界,对于 MLPs 和 CNNs 有时可达到最多八倍的改进。
  • 在像 AlexNet 这样的架构上,AutoLip 产生的上界非常大,而 SeqLip 可以实现显著降低。
  • 提供一个开源的 PyTorch 实现(lipEstimation),用于估计网络对微小扰动的鲁棒性。

更好的研究,从现在开始

从论文设计到论文写作,大幅缩短您的研究时间。

无需绑定信用卡

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