fuse constant padding into conv kernels#7515
Merged
masahi merged 4 commits intoapache:mainfrom Mar 2, 2021
Merged
Conversation
csullivan
reviewed
Feb 24, 2021
Contributor
csullivan
left a comment
There was a problem hiding this comment.
Thanks @mbrookhart!
Support for other operators that handle would be a nice follow on, but this handles the majority of problematic cases of padding happening explicitly from ONNX's use of auto_pad. On deeplabv3-mobilenetv2 this reduces the number of explicit nn.pad calls from 54 -> 11. Those remaining are part of a space to depth transformation.
csullivan
approved these changes
Feb 26, 2021
Contributor
csullivan
left a comment
There was a problem hiding this comment.
Wonderful! Thanks @mbrookhart
Contributor
|
Note that given the layout inference of the implementation, users should consider running SimplifyExpr prior to layout transformations via ConvertLayout or otherwise. Else it may be the case that a |
89b7dee to
2f59169
Compare
masahi
approved these changes
Mar 2, 2021
Member
|
Thanks @mbrookhart @csullivan |
trevor-m
pushed a commit
to trevor-m/tvm
that referenced
this pull request
May 6, 2021
* fuse constant padding into conv kernels * change the kernel to support other layouts * add channel-last test * add a comment about bailing early
trevor-m
pushed a commit
to neo-ai/tvm
that referenced
this pull request
May 11, 2021
* fuse constant padding into conv kernels * change the kernel to support other layouts * add channel-last test * add a comment about bailing early
This file contains hidden or 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
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.
cc @masahi @csullivan
Currently supports conv1d/2d/3d. I can probably do the same thing for conv transpose and pooling, but this is getting a little long, what do you guys think?