Skip to content

Apply-MegatronAdaptor-NPU-migration-to-clean-branch - #385

Open
momo609 wants to merge 3 commits into
vllm-project:ascendfrom
momo609:ascendupdate2
Open

Apply-MegatronAdaptor-NPU-migration-to-clean-branch#385
momo609 wants to merge 3 commits into
vllm-project:ascendfrom
momo609:ascendupdate2

Conversation

@momo609

@momo609 momo609 commented Aug 14, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • Remove MindSpeed-specific dependencies and imports.
  • Switch NPU backend integration to MegatronAdaptor and TransformerEngineNPU.
  • Align Megatron-related patches with the mainline implementation.
  • Remove obsolete MindSpeed and Megatron communication patches.
  • Update Megatron, vLLM, and bridge patch application order.
  • Fix MegatronAdaptor initialization and feature re-patching in the actor.
  • Update NPU attention patch and weight-transfer compatibility logic.
  • Fix nested NPU memory-pool allocation during training offload.
  • Update the related unit test and deployment scripts.

Files Changed

  • vime/backends/megatron_utils/
  • vime/utils/
  • docker/
  • scripts/
  • examples/
  • tests/
  • train.py
  • train_async.py

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request transitions the NPU training stack from MindSpeed to MegatronAdaptor and TransformerEngineNPU, updates the Megatron-LM commit, and applies several patches for optimizer steps, memory pool regions, and vLLM speculative draft updates. The reviewer's feedback is highly actionable and should be addressed: the new megatron_bridge.patch is orphaned in the Dockerfile and lacks path resolution in the environment update script; cloning dependencies from main without pinning commits makes the Docker build fragile; and the run-qwen3-4B-npu.sh script contains several hardcoded absolute paths and NPU device IDs that break portability.

Comment thread docker/Dockerfile.npu
Comment thread .buildkite/scripts/update-npu-environment.sh
Comment thread docker/Dockerfile.npu
Comment thread scripts/run-qwen3-4B-npu.sh Outdated
Comment thread scripts/run-qwen3-4B-npu.sh Outdated
Comment thread scripts/run-qwen3-4B-npu.sh Outdated
Comment thread scripts/run-qwen3-4B-npu.sh Outdated
wangxiaoxin-sherie added 2 commits August 14, 2026 11:07
wangxiaoxin-sherie
fix
Signed-off-by: wangxiaoxin-sherie <wangxiaoxin7@huawei.com>
Signed-off-by: wangxiaoxin-sherie <wangxiaoxin7@huawei.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant