-
-
Notifications
You must be signed in to change notification settings - Fork 11.1k
Fix test_mamba_ssm_ssd.py due to missing _query_start_loc_to_chunk_indices_offsets #25995
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
2019c24 to
25a53dc
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does this test not run as part of CI? Didn't realize it was broken.
| chunk_lens.append(int(take)) | ||
| seq_idx_chunks.append(b) | ||
| last_chunk_indices[b] = len(chunk_lens) - 1 | ||
| pos += take |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Rather than re-implementing this logic - I think it could be better to refactor the logic into a util function in the meta-data builder and import it (e.g., similarly to how we were doing it for _query_start_loc_to_chunk_indices_offsets).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thanks @tdoublep !
I moved this helper function to vllm/v1/attention/backends/mamba2_attn.py . Let me know what you think!
Signed-off-by: Huamin Li <3ericli@gmail.com>
Regarding this, from https://github.com/vllm-project/vllm/blob/main/.buildkite/test-pipeline.yaml#L473C10-L480 , my guess is it will run only if changes touch Your PR didn't touch those directories so it didn't get triggered. Let me know if you want to change that, and I am happy to add vllm/v1/attention/backends/mamba2_attn.py into the list! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks reasonable and would like to merge to unblock CI, thank you
…dices_offsets (vllm-project#25995) Signed-off-by: Huamin Li <3ericli@gmail.com>
…dices_offsets (#25995) Signed-off-by: Huamin Li <3ericli@gmail.com> Signed-off-by: yewentao256 <zhyanwentao@126.com>
…dices_offsets (vllm-project#25995) Signed-off-by: Huamin Li <3ericli@gmail.com> Signed-off-by: Tomer Asida <57313761+tomeras91@users.noreply.github.com>
…dices_offsets (vllm-project#25995) Signed-off-by: Huamin Li <3ericli@gmail.com> Signed-off-by: xuebwang-amd <xuebwang@amd.com>
…dices_offsets (vllm-project#25995) Signed-off-by: Huamin Li <3ericli@gmail.com>
…dices_offsets (vllm-project#25995) Signed-off-by: Huamin Li <3ericli@gmail.com>
…dices_offsets (vllm-project#25995) Signed-off-by: Huamin Li <3ericli@gmail.com> Signed-off-by: xuebwang-amd <xuebwang@amd.com>
Purpose
#24683 removed the helper function _query_start_loc_to_chunk_indices_offsets and breaks the tests/kernels/mamba/test_mamba_ssm_ssd.py (sample job https://buildkite.com/vllm/ci/builds/32891/steps/canvas?sid=019998c8-1682-4e2d-8161-55a772c16cde) from v1.attention.backends.mamba2_attn as part of the chunk‑aligned Mamba2 changes. This made tests/kernels/mamba/test_mamba_ssm_ssd.py fail at import time. This patch removes the import and computes the small piece of chunk metadata directly in the test, also providing cu_chunk_seqlens and last_chunk_indices expected by the new kernels. No runtime changes.
This PR
Test Plan
Test Result
Essential Elements of an Effective PR Description Checklist
supported_models.mdandexamplesfor a new model.