MoE ECHO: Unlocking Sync-Free, Full CUDA-Graph Support for Dropless MoE via Elastic Cloning#2368
Draft
Victarry wants to merge 16 commits into
Draft
MoE ECHO: Unlocking Sync-Free, Full CUDA-Graph Support for Dropless MoE via Elastic Cloning#2368Victarry wants to merge 16 commits into
Victarry wants to merge 16 commits into
Conversation
- Updated `TransformerConfig` to include new parameters for echo experts and offloading capabilities. - Introduced `one_shot_greedy_assignment` function for efficient token assignment in offloading planner. - Added tests for echo experts and offloading planner to ensure functionality and performance. - Adjusted existing functions to support new metadata handling for echo expert dispatching. This commit improves load balancing and reduces communication overhead in MoE models.
48 tasks
95ee60c to
843ce7d
Compare
Delete outdated and unused files
44ac439 to
cb82c5b
Compare
…n in the expert dispatch.
cb82c5b to
78a1fc1
Compare
|
why deepep backend not surpport sync-free dispatch |
71 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
MoE ECHO: Elastic Cloning for Hot Experts 🚀
Contributors(Equal Contribution, sorted alphabetically): Ahan Huang, Dennis Liu(@Victarry), Nan Zheng(@nanz-nv), Patrick Haft, Qi Zhang(@QiZhangNV), Robin Zhang(@buptzyb), Tong Liu(@Autumn1998), Zijie Yan(@yanring)
Overview 🔍
MoE Echo is a research prototype of a new MoE training paradigm that targets large-scale distributed training. It focuses on achieving load balance and sync-free with Fully CUDA-graph-capturable on dropless MoE training.
Concretely, MoE Echo aims to:
Sync-Free MoE ⚡
In token-dropless MoE, the number of tokens sent to each EP rank can vary significantly from step to step. The routing decisions (and thus the per-rank shapes) are produced on the GPU, but the host traditionally needs this shape information to:
Naively, this requires device-to-host copies and host-side synchronization on every step, which both slows down training and makes CUDA graph capture difficult.
To build a sync-free, CUDA-graph-friendly MoE, we:
MoE Echo tackles this by:
Elastic Cloning for Hot Experts (ECHO)
To further reduce expert load imbalance, MoE Echo introduces elastic cloning for hot experts (ECHO). The key idea is to dynamically clone high-traffic (“hot”) experts onto EP ranks that receive fewer-than-average tokens.
Cloning experts during training is challenging because expert weights and gradients must remain coherent across all clones at every step. This means:
MoE Echo addresses this with:
Quick Start 🏁
Install Dependencies
HybridEP
Device-inited-grouped gemm
Note that this kernel is only available for Blackwell GPUs.
Run MoE Echo▶️
Add the following flags to the command line to enable Echo for your training:
Roadmap 🗺️