Skip to content

[Feat] [FSDP2] [SFT] [ExpertParallel] [DeepSeekV4] fsdp2 dpsk v4 flash 0731 support on only 1Node with 8*H200 - #10197

Open
mugglewei97 wants to merge 2 commits into
modelscope:mainfrom
mugglewei97:feat/fsdp2-dpsk-v4-flash
Open

mugglewei97 wants to merge 2 commits into
modelscope:mainfrom
mugglewei97:feat/fsdp2-dpsk-v4-flash

Conversation

@mugglewei97

@mugglewei97 mugglewei97 commented Sep 18, 2026

Copy link
Copy Markdown

PR type

New Feature
More Models or Datasets Support

PR information

为混合专家(MoE)模型增加了基于 FSDP2 后端、具备普适性的专家并行EP
使得仅在单节点8*H200上即可实现full sft训练

由于MoE模型绝大部分权重在experts,而experts的激活是十分稀疏的,为避免fsdp2在fully shard下,
每次forward/pre-fetch时all gather整个decoder layer的完整权重,通过ignore modules将experts部分从fsdp2中解耦,为其实A2A通信和local expert计算

另,通过令device=meta,解决了大尺寸模型初始化加载权重时的oom问题
目前在8*H200即可加载DeepSeek-V4-Flash-0731

Experiment results

Training script which has been actual tested is added
Paste your experiment result here(if needed).

@hjh0119 hjh0119 added the postpone We'll revisit this PR once the refactoring work is finished label Sep 20, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

postpone We'll revisit this PR once the refactoring work is finished

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants