-
Notifications
You must be signed in to change notification settings - Fork 28
Add all2all initial impl #51
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
problems/amd/all2all/reference.py
Outdated
cfg, all_rank_data = data | ||
world_size = 8 | ||
|
||
mp.set_start_method("spawn", force=True) |
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.
we were doing this on our end, I'm still unsure whether we should do this or make users do this. It seems "fine" if we can just provide a helper or copy pastable code in template for folks -cc @ngc92
problems/amd/all2all/reference.py
Outdated
# num experts per rank | ||
self.num_local_experts = cfg.num_experts // world_size | ||
# max recv tokens per rank | ||
self.max_recv = cfg.max_num_tokens * cfg.experts_per_token |
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.
n00b q is reasonable loading balancing guaranteed?
This PR included reference.py and submission.py and task description
I initially added some shapes which all from popular models like deepseek series, gpt-oss, mixtral. You can check if they work with the reference.py and submission.py on your end.
Thanks