transformers
Expert-parallel implementations for `ep_dispatch_experts`: all-reduce at inference, all-to-all in training
#49429
Open

Expert-parallel implementations for `ep_dispatch_experts`: all-reduce at inference, all-to-all in training #49429

IlyasMoutawwakil wants to merge 43 commits into main from ep-masked-when-shared-batch
IlyasMoutawwakil
HuggingFaceDocBuilderDev
3outeille build and expand once the tp/ep_plan
6440b726
3outeille unify
79b5fdb0
3outeille clean fsdp
bb63397e
3outeille reorganize to avoid breaking changes
f9158f8d
3outeille better distinction
64eb317a
3outeille Merge branch 'main' into unify-resolve-plan
61a4954d
3outeille revert
5fbf21c9
3outeille Merge branch 'unify-resolve-plan' of github.com:huggingface/transform…
ff70527c
3outeille add tp plan to deepseek v4 (but attention stays replicated)
3f1e4ab9
3outeille Revert "add tp plan to deepseek v4 (but attention stays replicated)"
ff3629c6
IlyasMoutawwakil IlyasMoutawwakil marked this pull request as ready for review 23 days ago
github-actions github-actions requested a review from Rocketknight1 Rocketknight1 23 days ago
github-actions github-actions requested a review from ArthurZucker ArthurZucker 23 days ago
IlyasMoutawwakil IlyasMoutawwakil changed the title Expert-parallel dispatch runs the experts masked when the EP group shares one batch Expert-parallel strategies: masked all-reduce for small shared batches, all-to-all above, picked per forward 23 days ago
IlyasMoutawwakil IlyasMoutawwakil requested a review from qgallouedec qgallouedec 23 days ago
IlyasMoutawwakil IlyasMoutawwakil requested a review from 3outeille 3outeille 23 days ago
IlyasMoutawwakil IlyasMoutawwakil changed the title Expert-parallel strategies: masked all-reduce for small shared batches, all-to-all above, picked per forward Expert-parallel strategies for `ep_dispatch_experts`: all-reduce at inference, all-to-all in training 23 days ago
IlyasMoutawwakil
IlyasMoutawwakil commented on 2026-10-14
3outeille
3outeille commented on 2026-10-15
3outeille
3outeille commented on 2026-10-15
3outeille
3outeille commented on 2026-10-15
IlyasMoutawwakil IlyasMoutawwakil requested a review from 3outeille 3outeille 22 days ago
IlyasMoutawwakil IlyasMoutawwakil requested a review from vasqu vasqu 22 days ago
IlyasMoutawwakil
IlyasMoutawwakil commented on 2026-10-16
IlyasMoutawwakil IlyasMoutawwakil changed the title Expert-parallel strategies for `ep_dispatch_experts`: all-reduce at inference, all-to-all in training Expert-parallel implementations for `ep_dispatch_experts`: all-reduce at inference, all-to-all in training 21 days ago
dacorvo
IlyasMoutawwakil
dacorvo
3outeille
3outeille Merge branch 'main' into unify-resolve-plan
b5da03f9
3outeille Fix the merge of main: restore moved imports and the empty tp_plan ov…
d527c29f
3outeille Merge remote-tracking branch 'origin/main' into unify-resolve-plan
523101d8
3outeille cleaner mixin
96332a1e
3outeille cleaner
615fe835
3outeille deprecation cycle
868647f2
3outeille cleaner
a121baea
3outeille revert tp plan
e1d83ef5
3outeille Merge remote-tracking branch 'origin/main' into unify-resolve-plan
2dbcb42c
3outeille Pass the expanded plan in the bare-module colwise_gather_output test
9ef53bbc
tarekziade retrigger to verify fetcher
a1a055ba
vasqu
vasqu commented on 2026-10-19
3outeille the branch is now pointing to main and not to unify-resolve-plan
b5eb8827
3outeille Refactor expert parallelism registration and improve documentation
0de36597
3outeille comment
bc4b6e0a
3outeille some models missed the tests EP mixin
c47e5dce
3outeille fix copyright
f88b6167
3outeille Merge branch 'cleanup-ep' into unify-resolve-plan
7d3345d8
3outeille move replace_layer_number_by_wildcard and _get_parameter_plan to para…
da4eed4d
3outeille Merge branch 'main' into cleanup-ep
d7591e12
3outeille Merge branch 'cleanup-ep' into unify-resolve-plan
a75a5cb2
3outeille Merge branch 'main' into unify-resolve-plan
6247bd14
3outeille Merge remote-tracking branch 'origin/unify-resolve-plan' into unify-r…
f5824079
IlyasMoutawwakil Expert-parallel implementations for ep_dispatch_experts: all-reduce a…
6ac4923f
IlyasMoutawwakil Run the backward-only all-reduces only when a gradient can flow
44cd6786
IlyasMoutawwakil IlyasMoutawwakil force pushed from 9863215b to 44cd6786 10 days ago
github-actions
IlyasMoutawwakil Drop the config-side EP implementation resolver
0ce3b90c
IlyasMoutawwakil Merge main: the plans are resolved once in the model (#49527)
6f72a0ea
IlyasMoutawwakil Say what each EP implementation does in short sentences
1710f6c5
IlyasMoutawwakil IlyasMoutawwakil removed review request from Rocketknight1 Rocketknight1 4 days ago
IlyasMoutawwakil IlyasMoutawwakil removed review request from qgallouedec qgallouedec 4 days ago
IlyasMoutawwakil IlyasMoutawwakil removed review request from 3outeille 3outeille 4 days ago
IlyasMoutawwakil IlyasMoutawwakil removed review request from ArthurZucker ArthurZucker 4 days ago
IlyasMoutawwakil IlyasMoutawwakil requested a review from 3outeille 3outeille 4 days ago
IlyasMoutawwakil IlyasMoutawwakil requested a review from vasqu vasqu 4 days ago
IlyasMoutawwakil
IlyasMoutawwakil IlyasMoutawwakil requested a review from ArthurZucker ArthurZucker 4 days ago
3outeille
3outeille commented on 2026-11-04
IlyasMoutawwakil EP implementations: one forward instead of dispatch + combine
a3365657
IlyasMoutawwakil EP implementations are callables; inline the backward all-reduce check
704f9114
IlyasMoutawwakil IlyasMoutawwakil requested a review from 3outeille 3outeille 2 days ago
3outeille
3outeille commented on 2026-11-05
IlyasMoutawwakil EP: register implementations in a dict on EpDispatchExpertsParallel
d8763955
IlyasMoutawwakil IlyasMoutawwakil force pushed from 7c1410ea to d8763955 1 day ago
IlyasMoutawwakil EP: inline the shared-batch check into EPImplementation
6eae29f4
IlyasMoutawwakil IlyasMoutawwakil requested a review from 3outeille 3outeille 1 day ago
vasqu
vasqu commented on 2026-11-05
IlyasMoutawwakil EP: always take the TP mesh in EP implementations
389f9423
IlyasMoutawwakil EP: helper for the gradient-only all-reduce, kwarg ep mesh, one toy e…
4a1cd28f
vasqu
vasqu approved these changes on 2026-11-06
3outeille
3outeille requested changes on 2026-11-06
3outeille
3outeille approved these changes on 2026-11-06

Login to write a write a comment.

Login via GitHub

Assignees
No one assigned
Labels
Milestone