[NPU] Enable Qwen3-VL GRPO (single- & multi-turn) on Ascend#314
Conversation
Documentation build overview
43 files changed ·
|
|
Warning Gemini encountered an error creating the review. You can try again by commenting |
7ce077b to
518f399
Compare
Signed-off-by: Meihan-chen <zr010426ztt@outlook.com>
518f399 to
383ffe8
Compare
af76eeb to
4836b95
Compare
|
The main branch seems to have a refactor #341 , maybe you can have a look. |
| - if packed_seq_params is not None | ||
| - else {} | ||
| - ) | ||
| + attention_mask = torch.triu( |
There was a problem hiding this comment.
This attention_mask line can be removed.
4836b95 to
24f6fb5
Compare
Signed-off-by: Meihan-chen <zr010426ztt@outlook.com>
24f6fb5 to
80b0c3d
Compare
Signed-off-by: Meihan-chen <zr010426ztt@outlook.com>
80b0c3d to
10baf84
Compare
#341 fixes the same two multi-turn issues as our earlier in-house patch, using the same approach — render once, keep the generated token ids as the canonical history, and append only the observation suffix delta between turns. The only difference was code structure (our hand-rolled generate() vs upstream’s _Geo3kRollout class). This PR adopts #341 verbatim so the file matches upstream, with a single required shim: this Ascend branch’s Sample has no append_response_tokens(), so _Geo3kRollout._append_response() maintains tokens/loss_mask/rollout_log_probs/response_length directly. diff vs upstream = only that method + its 3 call-sites. |
CalvinXKY
left a comment
There was a problem hiding this comment.
LGTM. Nit: PR description is slightly stale — it still says we restore 3 helpers in vime/rollout/vllm_rollout.py deleted by #178, but this diff does not touch that file. The multi-turn rollout now imports fewer helpers (_coerce_flat_int_token_ids / _mm_render_response_to_generate_body already present on ascend) and aligns with the #341 “render once + observation suffix” approach. Worth updating the “Multi-turn fixes” section so it matches the final code.
Good catch — updated. Reworded the alignment note accordingly. |



Summary
Brings up Qwen3-VL-8B-Instruct GRPO on Ascend NPU for both the single-turn (examples/geo3k_vlm) and multi-turn (examples/geo3k_vlm_multi_turn) examples, on vllm-ascend rollout + Megatron-Bridge/MindSpeed training.
Base VLM fixes (apply to both single- & multi-turn)
Multi-turn fixes