-
Notifications
You must be signed in to change notification settings - Fork 3.8k
[OpenCLML] Transposed convolution support and other fixes #14767
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
Added support for transposed convolution. Epsilon support for batchnorm op added - part of v3.0. CLML version query bug fixed.
|
Thanks for contributing to TVM! Please refer to the contributing guidelines https://tvm.apache.org/docs/contribute/ for useful information and tips. Please request code reviews from Reviewers by @-ing them in a comment.
Generated by tvm-bot |
echuraev
left a comment
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.
Thank you for your PR. In general LGTM. Some minor comments.
| name = "conv2d_transpose"; | ||
| const auto* conv_transpose_attr = nodes.conv->attrs.as<Conv2DTransposeAttrs>(); | ||
| ICHECK(conv_transpose_attr); | ||
| ICHECK(conv_transpose_attr->kernel_layout == "OIHW") |
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.
Is it necessary to check kernel_layout here? You have already done it in python/tvm/relay/op/contrib/clml.py. If it is not necessary, then probably the same checks can be removed for convolution.
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.
I will remove this check in python frontend. Codegen is the final component to make sure we don't generate incompatible code.
python/tvm/relay/op/contrib/clml.py
Outdated
| """Utility function to get clml version version""" | ||
|
|
||
| return tvm.support.libinfo().get("TVM_CLML_VERSION", 2) | ||
| return int(tvm.support.libinfo().get("CLML_VERSION_MAJOR", 2)) |
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.
Why did you change TVM_CLML_VERSION on CLML_VERSION_MAJOR?
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.
The version check from libinfo was broken earlier and not functional. TVM_CLML_VERSION was compiler flag and cmake option is CLML_VERSION_MAJOR. We can maintain same for both.
echuraev
left a comment
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. Thanks
76f43fc to
a7605af
Compare
Added support for transposed convolution.
Epsilon support for batchnorm op added - part of v3.0. CLML version query bug fixed.