Skip to main content
QUICK REVIEW

[论文解读] Revisiting Small Batch Training for Deep Neural Networks

Dominic Masters, Carlo Luschi|arXiv (Cornell University)|Apr 20, 2018
Advanced Neural Network Applications参考文献 23被引用 353
一句话总结

该论文显示小型小批量大小(2–32)在CIFAR-10/100和ImageNet上能获得更好的泛化和稳定训练,挑战向极大批量的趋势。它分析学习率缩放、批归一化的影响、以及暖昇策略。

ABSTRACT

Modern deep neural network training is typically based on mini-batch stochastic gradient optimization. While the use of large mini-batches increases the available computational parallelism, small batch training has been shown to provide improved generalization performance and allows a significantly smaller memory footprint, which might also be exploited to improve machine throughput. In this paper, we review common assumptions on learning rate scaling and training duration, as a basis for an experimental comparison of test performance for different mini-batch sizes. We adopt a learning rate that corresponds to a constant average weight update per gradient calculation (i.e., per unit cost of computation), and point out that this results in a variance of the weight updates that increases linearly with the mini-batch size $m$. The collected experimental results for the CIFAR-10, CIFAR-100 and ImageNet datasets show that increasing the mini-batch size progressively reduces the range of learning rates that provide stable convergence and acceptable test performance. On the other hand, small mini-batch sizes provide more up-to-date gradient calculations, which yields more stable and reliable training. The best performance has been consistently obtained for mini-batch sizes between $m = 2$ and $m = 32$, which contrasts with recent work advocating the use of mini-batch sizes in the thousands.

研究动机与目标

  • 评估小批量大小如何影响深度网络的泛化与收敛。
  • 在恒定梯度成本下,研究学习率缩放规律。
  • 评估批归一化在不同批量大小下的作用及其对训练稳定性的影响。
  • 考察渐进暖身在大批量与小批量模式中的作用。
  • 为分布式训练提供在BN批量大小与SGD批量大小可能不同的情况下的指导。

提出的方法

  • 将SGD更新表示为小批量梯度的平均值或和,以比较学习率缩放。
  • 在多种架构上,使用不同批量大小和基础学习率对CIFAR-10、CIFAR-100和ImageNet进行经验训练。
  • 在有无Batch Normalization以及数据增强下评估性能。
  • 测试渐进暖身策略以缓解大批量训练的不稳定性。
  • 分析BN与SGD更新采用不同批量大小的影响。

实验结果

研究问题

  • RQ1在恒定每梯度更新成本下,小批量大小如何影响泛化性能与稳定收敛?
  • RQ2批归一化对小批量与大批量在训练过程动态和最终准确度的影响是什么?
  • RQ3渐进暖身策略是否能缓解在多数据集上观察到的大批量降解?
  • RQ4在CIFAR-10/100和ImageNet上,得到最佳准确度与稳定性的最优批量大小范围(2–32)是什么?
  • RQ5将BN批量大小与SGD批量大小分离对分布式训练性能有何影响?

主要发现

  • 在所测试的架构和数据集上,一致获得最佳泛化的小批量大小为2到32之间。
  • 增大批量大小会缩小能实现稳定收敛和可接受测试性能的学习率范围。
  • Batch Normalization 提升收敛和测试精度,并允许使用中等批量大小进行有效训练;非常小的BN批次对全连接层可能存在问题。
  • 渐进暖身有助于在较大批量设置中维持稳定训练,但无法完全恢复小批量所具备的性能优势。
  • ImageNet结果显示最佳验证精度在16到64之间的批量大小,较大批量对学习率选择更敏感。

更好的研究,从现在开始

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

无需绑定信用卡

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