-
Notifications
You must be signed in to change notification settings - Fork 1.9k
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
webgpu: Add non-shared argminmax program #6778
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
The perf of ArgMax[1, 1025, 2049, 19] in cityscapes architecture in DeepLabV3 is very poor. With this changes, this op becomes 6.3ms from 22.36ms.
Linchenn
approved these changes
Aug 23, 2022
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.
LGTM!
xhcao
approved these changes
Aug 23, 2022
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.
LGTM
qjia7
added a commit
to qjia7/tfjs
that referenced
this pull request
Jun 7, 2023
In PR tensorflow#6778, we ever added the pain argminmax shader to improve the perf of ArgMax[1, 1025, 2049, 19]. However, we accidently added the output size condition, which was not verified. This PR removes that condition and only goes to pain argminmax when the reduce length is very small(<32). With this change, ArgMax[1,513,513,151] becomes 7.19ms from 13.24ms in DeepLabV3-ade20k on Intel ADL.
qjia7
added a commit
to qjia7/tfjs
that referenced
this pull request
Jun 7, 2023
In PR tensorflow#6778, I ever added the plain argminmax shader to improve the perf of ArgMax[1, 1025, 2049, 19]. However, I accidently added the output size condition, which was not verified. This PR removes that condition and only goes to plain argminmax when the reduce length is very small(<32). With this change, ArgMax[1,513,513,151] becomes 7.19ms from 13.24ms in DeepLabV3-ade20k on Intel ADL.
gyagp
pushed a commit
that referenced
this pull request
Jun 8, 2023
* webgpu: Tighten the condition to go the plain argminmax In PR #6778, I ever added the plain argminmax shader to improve the perf of ArgMax[1, 1025, 2049, 19]. However, I accidently added the output size condition, which was not verified. This PR removes that condition and only goes to plain argminmax when the reduce length is very small(<32). With this change, ArgMax[1,513,513,151] becomes 7.19ms from 13.24ms in DeepLabV3-ade20k on Intel ADL.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The perf of ArgMax[1, 1025, 2049, 19] in cityscapes architecture in
DeepLabV3 is very poor. With this changes, this op becomes 6.3ms from
22.36ms.
To see the logs from the Cloud Build CI, please join either our discussion or announcement mailing list.
This change is