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

use_fuse_mask_softmax #412

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open

use_fuse_mask_softmax #412

wants to merge 3 commits into from

Conversation

xiezipeng-ML
Copy link
Contributor

No description provided.

@xiezipeng-ML
Copy link
Contributor Author

测试use_fuse_mask_softmax 的性能增益

oneflow分支:python3 -m pip install --pre oneflow -f https://staging.oneflow.info/branch/release/mt5_opt/cu112

对应的oneflow commit:2d080aa

libai分支:use_fuse_mask_softmax

projects/T5/configs/t5_model_config.py中测量model.cfg.scale_mask_softmax_fusion = Falsemodel.cfg.scale_mask_softmax_fusion = True上的吞吐区别

@ouyangyu @chengtbf @strint

@xiezipeng-ML
Copy link
Contributor Author

batch size = 4, acc step = 8, amp, open Checkpointing

1n1g use_fuse_mask_softmax = False use_fuse_mask_softmax = True
Throughput total_throughput: 152.35 samples/s total_throughput: 158.00 samples/s
GPU Memory 3145MiB 3335MiB
1n4g use_fuse_mask_softmax = False use_fuse_mask_softmax = True
Throughput total_throughput: 109.33 samples/s total_throughput: 112.39 samples/s
GPU Memory 2445MiB 2545MiB

@chengtbf @strint @ouyangyu

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.

1 participant