8000 random pad input ids by grimoire · Pull Request #3530 · InternLM/lmdeploy · GitHub
[go: up one dir, main page]

Skip to content

random pad input ids #3530

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

Merged
merged 1 commit into from
May 12, 2025
Merged

random pad input ids #3530

merged 1 commit into from
May 12, 2025

Conversation

grimoire
Copy link
Collaborator
@grimoire grimoire commented May 9, 2025

Zero-padded input ids would lead to an imbalance in expert selection.

Fix dp-tp attention default behaviour.

@@ -1675,7 +1675,7 @@ def build_qkv_proj(in_features: int,
device: Optional[torch.device] = None,
is_tp: bool = True,
num_replicate_kv_heads: int = 1,
dp_disable_tp: bool = False,
dp_disable_tp: bool = True,
Copy link
Collaborator

Choose a reason for hiding this comment

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

How can it benefit us?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

this is a fix for dp+tp.

@lvhan028 lvhan028 requested a review from RunningLeon May 9, 2025 04:43
Copy link
Collaborator
@RunningLeon RunningLeon left a comment

Choose a reason for hiding this comment

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

LGTM

@lvhan028 lvhan028 merged commit 20a4272 into InternLM:main May 12, 2025
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants
0