[论文解读] HELP: Hardware-Adaptive Efficient Latency Prediction for NAS via Meta-Learning
该论文提出 HELP,一种基于元学习的延迟预测器,仅需每台设备 10–20 次测量即可实现对未见过的硬件设备的快速、准确的延迟估计,适用于神经架构搜索(NAS)。通过利用新颖的硬件嵌入和内层适应机制学习设备特定的初始参数,HELP 在仅使用基线方法 1/90 的样本量下实现了更优的泛化性能。
For deployment, neural architecture search should be hardware-aware, in order to satisfy the device-specific constraints (e.g., memory usage, latency and energy consumption) and enhance the model efficiency. Existing methods on hardware-aware NAS collect a large number of samples (e.g., accuracy and latency) from a target device, either builds a lookup table or a latency estimator. However, such approach is impractical in real-world scenarios as there exist numerous devices with different hardware specifications, and collecting samples from such a large number of devices will require prohibitive computational and monetary cost. To overcome such limitations, we propose Hardware-adaptive Efficient Latency Predictor (HELP), which formulates the device-specific latency estimation problem as a meta-learning problem, such that we can estimate the latency of a model's performance for a given task on an unseen device with a few samples. To this end, we introduce novel hardware embeddings to embed any devices considering them as black-box functions that output latencies, and meta-learn the hardware-adaptive latency predictor in a device-dependent manner, using the hardware embeddings. We validate the proposed HELP for its latency estimation performance on unseen platforms, on which it achieves high estimation performance with as few as 10 measurement samples, outperforming all relevant baselines. We also validate end-to-end NAS frameworks using HELP against ones without it, and show that it largely reduces the total time cost of the base NAS method, in latency-constrained settings. Code is available at https://github.com/HayeonLee/HELP.
研究动机与目标
- 解决在硬件感知 NAS 中为每个新硬件设备收集大规模延迟测量所导致的高计算和经济成本问题。
- 克服现有方法在每个设备和任务上均需从零开始训练延迟预测器的局限性。
- 通过利用多样化设备池中的元知识,实现对未见设备的样本高效延迟估计。
- 与现有快速 NAS 框架无缝集成,显著缩短延迟约束场景下的总搜索时间。
提出的方法
- 将延迟预测建模为少样本回归问题,使模型仅通过少量延迟测量即可适应新设备。
- 提出一种新颖的硬件嵌入机制,基于设备对一组参考架构的延迟响应,将任意设备编码为潜在向量。
- 设计一种结合摊销元学习与基于梯度的元学习的元学习框架,以学习设备自适应的初始参数。
- 将硬件嵌入作为元学习器的输入,用于预测初始模型权重,随后通过内层梯度更新实现对未见设备的快速适应。
- 在多样化设备池(如 GPU 和 CPU)上训练元学习器,以实现对硬件异构性的泛化。
- 通过将传统延迟预测器替换为元学习的 HELP 预测器,实现与 NAS 框架的端到端集成。
实验结果
研究问题
- RQ1单一延迟预测器是否能以极低的测量开销在多样化、未见的硬件平台上实现泛化?
- RQ2结合硬件嵌入的元学习在减少准确预测所需延迟测量次数方面效果如何?
- RQ3当与现有 NAS 方法集成时,HELP 在延迟约束的 NAS 中能将总时间成本降低多少?
- RQ4所提出的硬件嵌入是否能有效捕捉设备特定特征,以实现准确的元适应?
主要发现
- HELP 仅需每台设备 10–20 次测量,即可在未见设备上实现最先进的延迟估计性能,显著优于基线方法。
- 在 HW-NAS-Bench 数据集上的 NAS-Bench-201 实验中,HELP 相较于基线方法将所需样本数减少了至少 90 倍。
- 与 HAT 结合时,HELP 将训练延迟预测器所需的样本数从 2000 降低至仅 10 个,同时在 WMT’14 En-De 任务上保持了具有竞争力的 BLEU 分数。
- 在 90ms 延迟约束下,HAT+HELP 仅用 10 个样本即达到 BLEU 分数 27.19,而基线方法使用 2000 个样本仅获得 27.08 的分数。
- 在 CPU 平台(Intel Xeon Gold6240)上,HAT+HELP 使用 10 个样本即达到 BLEU 分数 27.52,优于使用 2000 个样本训练的基线方法(27.09)。
- 将 HELP 与 OFA 和 MetaD2A 等快速 NAS 方法集成后,可在新设备上实现近乎即时的延迟约束 NAS,显著降低整体搜索成本。
更好的研究,从现在开始
从阅读论文到最终审阅,大幅缩短您的研究时间。
无需绑定信用卡
本解读由 AI 生成,并经人工编辑审核。