高层次综合(HLS)是设计现场可编程门阵列(FPGA)时广泛使用的工具。HLS通过将源代码编译为FPGA电路,使设计者能够使用软件编程语言进行FPGA设计。源代码包含一个程序(称为“kernel”)以及若干指导硬件综合的编译指示(pragma),例如并行化、流水线等。虽然软件开发者设计程序相对容易,但设计这些编译指示却高度依赖硬件知识,从而给软件开发者带来巨大挑战。近来,已有GNN等不同机器学习算法被提出,用于通过性能预测实现编译指示设计自动化。然而,将训练后的模型应用于新kernel时,显著的领域偏移往往导致性能不理想。我们提出一种更具领域泛化能力的模型结构:两级分层Mixture of Experts(MoE,混合专家),它可以灵活适配任何GNN模型。不同的专家网络能够学习处理表示空间中的不同区域,并利用旧kernel与新kernel之间的相似模式。在低层MoE中,我们在程序的三种自然粒度上应用MoE:节点、基本块和图。高层MoE则学习聚合这三种粒度以作出最终决策。为稳定训练分层MoE,我们进一步提出一种两阶段训练方法,以避免专家极化。大量实验验证了所提出分层MoE的有效性。我们已在 https://github.com/weikai-li/HierarchicalMoE 公开代码。
英文摘要:
High-level synthesis (HLS) is a widely used tool in designing Field Programmable Gate Array (FPGA). HLS enables FPGA design with software programming languages by compiling the source code into an FPGA circuit. The source code includes a program (called "kernel") and several pragmas that instruct hardware synthesis, such as parallelization, pipeline, etc. While it is relatively easy for software developers to design the program, it heavily relies on hardware knowledge to design the pragmas, posing a big challenge for software developers. Recently, different machine learning algorithms, such as GNNs, have been proposed to automate the pragma design via performance prediction. However, when applying the trained model on new kernels, the significant domain shift often leads to unsatisfactory performance. We propose a more domain-generalizable model structure: a two-level hierarchical Mixture of Experts (MoE), that can be flexibly adapted to any GNN model. Different expert networks can learn to deal with different regions in the representation space, and they can utilize similar patterns between the old kernels and new kernels. In the low-level MoE, we apply MoE on three natural granularities of a program: node, basic block, and graph. The high-level MoE learns to aggregate the three granularities for the final decision. To train the hierarchical MoE stably, we further propose a two-stage training method to avoid expert polarization. Extensive experiments verify the effectiveness of the proposed hierarchical MoE. We publicized our codes at https://github.com/weikai-li/HierarchicalMoE.
Sparse Mixture-of-Experts are Domain Generalizable Learners
Nanyang Technological University(南洋理工大学);The Hong Kong University of Science and Technology(香港科技大学);Mila-Quebec AI Institute(米拉-魁北克人工智能研究所);Nvidia Research(英伟达研究院)
Zero-shot Generalizable Graph Anomaly Detection with Mixture of Riemannian Experts
School of Computer Science and Engineering, Beihang University(北航计算机科学与工程学院);Key Lab of Education Blockchain and Intelligent Technology, Ministry of Education, Guangxi Normal University(教育区块链与智能技术重点实验室,教育部,广西师范大学)
MC#: Mixture Compressor for Mixture-of-Experts Large Models
Department of Electrical and Electronic Engineering, The University of Hong Kong(香港大学电子与电气工程系);School of Computing, National University of Singapore(新加坡国立大学计算机学院);NVIDIA Research(NVIDIA研究)
HyperMoE: Towards Better Mixture of Experts via Transferring Among Experts
Beijing University of Posts and Telecommunications(北京邮电大学);Tsinghua University(清华大学);INF Technology(INF科技);Hong Kong University of Science and Technology(香港科技大学)
The Illusion of Specialization: Unveiling the Domain-Invariant "Standing Committee" in Mixture-of-Experts Models
The Fin AI(Fin AI);Georgia Institute of Technology(佐治亚理工学院);Cornell University(康奈尔大学);Stevens Institute of Technology(史蒂文斯理工学院);The University of Manchester(曼彻斯特大学)
Booth School of Business University of Chicago(芝加哥大学商学院);Volgenau School of Engineering, George Mason University(乔治·马歇尔大学工程学院);Department of Systems Engineering and Operations Research George Mason University(乔治·马歇尔大学系统工程与运营管理系)
DAG-MoE: From Simple Mixture to Structural Aggregation in Mixture-of-Experts
University of Science and Technology of China(中国科学技术大学);Tsinghua University(清华大学);Nanyang Technological University(南洋理工大学);University of California, Berkeley(加州大学伯克利分校);University of Washington(华盛顿大学)
Mixture-of-Clustered-Experts: Advancing Expert Specialization and Generalization in Instruction Tuning
Department of Computer Science and Engineering, Korea University, Republic of Korea(韩国大学计算机科学与工程系);KT, Republic of Korea(韩国KT);School of Software, Soongsil University, Republic of Korea(顺天大学软件学院)