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

Tweak Pipeline Parallel layer split strategy #20

Draft
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

C-TC
Copy link

@C-TC C-TC commented Sep 3, 2024

The previous pipelineblock split strategy in nanotron tries to evenly split the layers to each device in terms of FLOPs. However, since the embedding table is becoming larger and larger, memory consumption should be taken into account.

We follow the practice in Llama 405B training, which treat the embedding table and lm head as heavy as a single transformer block. (This is why 405B model has 126 layers.)

Any suggestions for better general strategy?

e.g. a 32-layer llama model and PP=4:

Prev:
image

After:
image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants