arXivDaily arXiv每日学术速递 周一至周五更新
arXiv周末暂无论文更新,休息一下吧,周末愉快~~
arXiv 2408.10284cs.LG
收藏

AdapMoE:基于自适应敏感性的专家门控与管理,实现高效的MoE推理

AdapMoE: Adaptive Sensitivity-based Expert Gating and Management for Efficient MoE Inference

Peking University(北京大学);Institute for Artificial Intelligence(人工智能研究院);School of Integrated Circuits(集成电路学院);Institute of Electronic Design Automation(电子设计自动化研究所);Beijing Advanced Innovation Center for Integrated Circuits(北京集成电路高精尖创新中心)

Shuzhang Zhong, Ling Liang, Yuan Wang, Runsheng Wang, Ru Huang, Meng Li

AI总结:

AdapMoE提出一种算法-系统协同设计框架,通过基于敏感性的自适应专家门控与预取缓存管理,减少MoE推理中的按需加载开销,平均减少25%激活专家并实现1.35倍加速。

摘要:

混合专家(MoE)模型旨在提升大型语言模型(LLM)的效率,而无需按比例增加计算需求。然而,由于管理稀疏激活的专家所带来的高按需加载开销,它们在边缘设备上的部署仍面临重大挑战。本文介绍了AdapMoE,一种算法-系统协同设计框架,用于高效的MoE推理。AdapMoE具有自适应专家门控和管理功能,以减少按需加载开销。我们观察到专家加载在层和令牌之间的异质性,基于此,我们提出了一种基于敏感性的策略来动态调整激活专家的数量。同时,我们还整合了先进的预取和缓存管理技术,以进一步减少加载延迟。通过在多种平台上的全面评估,我们证明AdapMoE始终优于现有技术,平均减少激活专家数量25%,并在不损失准确性的情况下实现1.35倍的加速。代码可在以下网址获取:https://github.com/PKU-SEC-Lab/AdapMoE。

英文摘要:

Mixture-of-Experts (MoE) models are designed to enhance the efficiency of large language models (LLMs) without proportionally increasing the computational demands. However, their deployment on edge devices still faces significant challenges due to high on-demand loading overheads from managing sparsely activated experts. This paper introduces AdapMoE, an algorithm-system co-design framework for efficient MoE inference. AdapMoE features adaptive expert gating and management to reduce the on-demand loading overheads. We observe the heterogeneity of experts loading across layers and tokens, based on which we propose a sensitivity-based strategy to adjust the number of activated experts dynamically. Meanwhile, we also integrate advanced prefetching and cache management techniques to further reduce the loading latency. Through comprehensive evaluations on various platforms, we demonstrate AdapMoE consistently outperforms existing techniques, reducing the average number of activated experts by 25% and achieving a 1.35x speedup without accuracy degradation. Code is available at: https://github.com/PKU-SEC-Lab/AdapMoE.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑