nemo-mbridge-perf-moe-vlm-training
NVIDIA/skills
Megatron Bridge における「専門家混合型」視覚・言語モデルの学習に関する実践的な指針を示し、FSDP アプローチと 3D 並列アプローチを比較するとともに、最近のマルチモーダル実験から得られた知見を紹介する。
...すべて拡張しますMoE VLMのトレーニング
安定版ドキュメント: @docs/training/moe-optimization.md カード: @skills/nemo-mbridge-perf-moe-vlm-training/card.yaml
FSDP 対 3D 並列
| アプローチ | 強み | 最適な適用先 |
|---|---|---|
| FSDP | マルチモーダル実行を動作させるための最も簡単な方法 | 初回起動、メモリ優先のチューニング、扱いにくいPP境界 |
| 3D並列 | チューニング後のさらなる性能向上 | 整然としたPPレイアウトによる安定したモデルと、より詳細な探索を行うための時間 |
MoE VLMの場合、実用的なワークフローは通常以下の通りです:
- FSDPを用いて最初の信頼できる実行結果を得る
- 実データの入力を安定させ、再計算を行い、メモリ挙動を確認する
- スループットの余裕が追加作業に見合う場合にのみ、3D並列処理に移行する
最近のVLM実行から得られた主な知見
Qwen3-VLクラスのモデル
トラッカー全体を通じて、主な傾向は一貫していた:
- GB200クラスのシステムにおけるFSDPは、比較的シンプルな設定でも、すでに10%台後半という良好な利用率を達成できる
- B200でのFSDP実行は可能だが、再計算の選択や固定された ビジョン設定の影響をより受けやすい
- 3D並列処理では、同等の、あるいはそれ以上の動作点に回復可能だが、 MBS、再計算、および実際のビジョンパスを総合的に調整した後にのみ可能である
実データ対模擬データ
模擬データを用いたVLMの実行結果は、信頼できるパフォーマンスの指標とはなりません。実験では、 画像を含まない模擬実行は、実際のマルチモーダル入力と比較した場合、「わずかに 楽観的」というよりも「おおよそ2倍の速度」に近い結果となりました。
VLMのスループットについて結論を出す前に、実データまたは現実的な画像ペイロードを使用すること。
小規模なマルチモーダルMoEの実行
Qwen3.5スタイルの小規模なマルチモーダル実験でも、同様の教訓が裏付けられています:
- GB200では、HybridEPが堅実なデフォルト設定である
- トレーニングループが安定したら、TEスコープのCUDAグラフが役立つ
- より大きなMBSは効果をもたらす可能性がありますが、それはビジョンエンコーダが 次のボトルネックにならない場合に限られます
決定ガイド
以下の場合はFSDPを選択してください:
- 新しいVLMを初めて立ち上げる場合
- モデルに、埋め込み、ビジョン、デコーダの各ステージ間に扱いにくい境界がある場合
- 絶対的なスループットよりもメモリ収まりが重要である場合
- デコーダに重点を置いたチューニング中にビジョンスタックを一時停止する可能性がある場合
以下の場合は3D並列を選択してください
- モデルがFSDP下ですでに安定している場合
- PPのレイアウトが明確で再現性がある場合
- MBSのスイープ、再計算、およびCUDAグラフのスコープをまとめて実行できる場合
- 目標が「最も簡単な立ち上げ」ではなく、「最高の定常状態スループット」である場合
主な調整ポイント
適切なタイミングでビジョンスタックを凍結する:作業がデコーダに重点を置いている場合、 ビジョン側を凍結することで、わずかではあるが確実なスループットの向上が得られ、 メモリ負荷も軽減される。
MBSを積極的にスイープする:ビジョンパスは演算とオーバーヘッドのバランスを変えるため、 VLMsはテキストのみのMoE実行よりもMBSの影響を受けやすい。
モデルの適合後は、選択的な再計算を優先する:完全な再計算は 立ち上げには有用なツールだが、通常、選択的な再計算の方が安定した 状態を実現できる。
CUDAグラフのスコープをワークロードに合わせる:
attn moe_router moe_preprocessはより安全なMoEのデフォルト設定ですが、制御された実験においては、 より狭いスコープも有用な場合があります。EPだけでは不十分な場合にのみETPを使用する:ETPはレイアウトの制約を解除できるが、 通信量が増加し、チューニングの調整範囲も広がる。
代表的な設定ファミリー
FSDP優先のGB200パス
TP=1 CP=1 PP=1
EPはエキスパート・トポロジーに合わせてサイズ設定され、多くの場合大規模
ディスパッチャ:GB200クラスのシステムではHybridEP
再計算:最初はフル再計算から始め、その後選択的再計算へと緩和
3D並列GB200パス
TP=1 CP=1 PP=1 または適度なPP
EPおよびETPはエキスパート・トポロジーに合わせてサイズ設定
ディスパッチャ:HybridEP
CUDAグラフ:最初は狭く設定し、実データパスが安定してから幅を広げる
互換性
| 機能 | FSDP | 3D並列 |
|---|---|---|
| GB200上のHybridEP | 強力なデフォルト | トポロジーが安定した後の強力なデフォルト |
| CUDAグラフ | 立ち上げ後に有用 | 有用だが、スコープに敏感 |
| ビジョンのフリーズ | 自然な適合 | 可能だが、主要なパフォーマンス向上の手段としてはあまり使われない |
| 選択的な再計算 | 推奨 | 推奨 |
落とし穴
模擬マルチモーダルデータは誤解を招く恐れがある:これにより、デコーダの性能が実際のエンドツーエンドのVLMパスよりも はるかに良好に見える可能性がある。
ビジョンエンコーダーが予想外に支配的になる可能性があります:すべてをディスパッチャーに帰属させる前に、エンコーダー、プロジェクター、 およびデコーダーを個別にプロファイリングしてください。
有効作業量が異なるFSDPと3D並列実行を比較してはいけません: ステップ時間だけでなく、有用なトークン数やワークロードの形状で正規化してください。
ETPは無料ではない:デフォルトとしてではなく、適合やトポロジー調整のツールとして使用すること。
再計算とCUDAグラフの選択は密接に関連しています。 モデルを適合させる設定は、多くの場合、定常状態で最高の速度をもたらす設定とは異なります。
---
name: nemo-mbridge-perf-moe-vlm-training
description: Provides practical guidance for training Mixture-of-Experts Vision-Language Models in Megatron Bridge, comparing FSDP and 3D-parallel approaches with lessons from recent multimodal experiments.
license: Apache-2.0
---
# MoE VLM Training
Stable docs: @docs/training/moe-optimization.md
Card: @skills/nemo-mbridge-perf-moe-vlm-training/card.yaml
## FSDP vs 3D Parallel
| Approach | Strength | Best fit |
|---|---|---|
| FSDP | Simplest path to a working multimodal run | first bring-up, memory-first tuning, awkward PP boundaries |
| 3D parallel | Higher ceiling after tuning | stable models with a clean PP layout and time for deeper sweeps |
For MoE VLMs, the practical workflow is usually:
1. get the first reliable run with FSDP
2. stabilize real-data input, recompute, and memory behavior
3. move to 3D parallel only if the throughput headroom is worth the extra work
## Rounded Findings From Recent VLM Runs
### Qwen3-VL class models
The main patterns were consistent across the tracker:
- FSDP on GB200-class systems can already reach healthy high-teens utilization
with a comparatively simple setup
- B200 FSDP runs are viable, but more sensitive to recompute choice and frozen
vision settings
- 3D parallel can recover to a similar or better operating point, but only after
tuning MBS, recompute, and the real vision path together
### Real data vs mock data
Mock-data VLM runs are not trustworthy performance proxies. In the experiments,
image-free mock runs looked closer to "roughly twice as fast" than "slightly
optimistic" when compared with real multimodal input.
Use real or realistic image payloads before drawing any conclusion about VLM
throughput.
### Smaller multimodal MoE runs
The smaller Qwen3.5-style multimodal experiments reinforce the same lessons:
- HybridEP is a solid default on GB200
- TE-scoped CUDA graphs help once the training loop is stable
- larger MBS can pay off, but only if the vision encoder does not become the
next bottleneck
## Decision Guide
### Choose FSDP when
- you are bringing up a new VLM for the first time
- the model has awkward stage boundaries across embedding, vision, and decoder
- memory fit matters more than absolute throughput
- you may freeze the vision stack during decoder-focused tuning
### Choose 3D parallel when
- the model is already stable under FSDP
- the PP layout is clear and repeatable
- you can sweep MBS, recompute, and CUDA-graph scope together
- the goal is best steady-state throughput, not easiest bring-up
## Key Tuning Knobs
1. **Freeze the vision stack when appropriate**: if the work is decoder-focused,
freezing the vision side often gives a small but real throughput gain and
reduces memory pressure.
2. **Sweep MBS aggressively**: VLMs are more MBS-sensitive than text-only MoE
runs because the vision path changes the compute-to-overhead balance.
3. **Prefer selective recompute once the model fits**: full recompute is a
useful bring-up tool, but selective recompute is usually the better steady
state.
4. **Match CUDA-graph scope to the workload**: `attn moe_router moe_preprocess`
is the safer MoE default, while narrower scopes can still be useful for
controlled experiments.
5. **Use ETP only when EP alone is insufficient**: it can unlock a layout, but
it also introduces more communication and more tuning surface.
## Representative Config Families
### FSDP-first GB200 path
```text
TP=1 CP=1 PP=1
EP sized to the expert topology, often large
Dispatcher: HybridEP on GB200-class systems
Recompute: start with full, then relax toward selective recompute
```
### 3D-parallel GB200 path
```text
TP=1 CP=1 PP=1 or modest PP
EP and ETP sized to the expert topology
Dispatcher: HybridEP
CUDA Graph: start narrow, then widen only after the real-data path is stable
```
## Compatibility
| Feature | FSDP | 3D parallel |
|---|---|---|
| HybridEP on GB200 | strong default | strong default once topology is stable |
| CUDA graphs | useful after bring-up | useful, but more scope-sensitive |
| Freeze vision | natural fit | possible, but less often used as the headline perf path |
| Selective recompute | recommended | recommended |
## Pitfalls
1. **Mock multimodal data is misleading**: it can make the decoder look much
healthier than the real end-to-end VLM path.
2. **The vision encoder can dominate unexpectedly**: profile encoder, projector,
and decoder separately before attributing everything to the dispatcher.
3. **Do not compare FSDP and 3D-parallel runs with different effective work**:
normalize by useful tokens and workload shape, not only by step time.
4. **ETP is not free**: use it as a fit or topology tool, not as the default.
5. **Recompute and CUDA-graph choices are coupled**: the setting that gets the
model to fit is often not the setting that gives the best steady-state speed.
すべてのファイル
1件のファイルnemo-mbridge-perf-moe-vlm-trainingをインストール
スキルファイルをダウンロードし、.claude/skills/ ディレクトリに解凍してください。
ZIPをダウンロードリポジトリをクローンし、スキルファイルをプロジェクトにコピーしてください。
git clone https://github.com/NVIDIA/skills/tree/main/skills/nemo-mbridge-perf-moe-vlm-training # Copy SKILL.md to your .claude/skills/ directory
コピー





家
