Skip to content
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

[BUG]megatron-lm,with torchompile,The provided qkv memory layout is not supported! #1329

Open
qingshanxwx opened this issue Dec 20, 2024 · 1 comment
Labels
stale No activity in 60 days on issue or PR

Comments

@qingshanxwx
Copy link

code: the main branch https://github.com/NVIDIA/Megatron-LM
transformer_engine 1.13
eager is normal, compile will report The provided qkv memory layout is not supported!
The error is as follows:
Image

According to the functional description, the stride of k and v should be (SHD, HD, D, 1), but it is actually (HD, H*D, D, 1)

megatron/core/extensions/transformer_engine.py
Image

printed result
Image

Then call DotProductAttention, v'stride will become (524288, 128, 32, 1) directly,k'stride not change.
Image

printed result
Image

Copy link

Marking as stale. No activity in 60 days.

@github-actions github-actions bot added the stale No activity in 60 days on issue or PR label Feb 18, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
stale No activity in 60 days on issue or PR
Projects
None yet
Development

No branches or pull requests

1 participant