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

[TOPI] add basic scheduling for conv2d_transpose on x86 #3491

Merged
merged 6 commits into from
Jul 7, 2019

Conversation

yidawang
Copy link
Contributor

@yidawang yidawang commented Jul 4, 2019

As the title. For workload of mask r-cnn, the #FLOPS improves from 0.9G to 90G on c5.18xlarge instance of Amazon EC2.

Finer tuning and autotvm remain the future work.

@yzhliu @kevinthesun

def traverse(op):
"""Traverse operators from computation graph"""
# inline all one-to-one-mapping operators except the last stage (output)
if tag.is_broadcast(op.tag) or tag.is_injective(op.tag):
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is_injective implies is_broadcast

def _declaration_conv2d_transpose(cfg, data, kernel, strides, padding, out_dtype):
return _declaration_conv2d_transpose_impl(cfg, data, kernel, strides, padding, out_dtype)

def _declaration_conv2d_transpose_impl(cfg, data, kernel, strides, padding, out_dtype):
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can we put this function to nn/conv2d_transpose.py and have nn.conv2d_transpose_nchw and _declaration_conv2d_transpose share the implement?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makes sense. But I am assuming that cfg will be used in the future within this function. If we move it to nn/conv2d_transpose.py, I am not sure how to deal with it. What do you suggest? Thanks!

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Anyway, I modified as you suggested and put a TODO for now.

@ajtulloch
Copy link
Contributor

@yidawang do you folks happen to have an E2E example of Mask R-CNN with TVM? We'd be interested in this at FB for our object detector work.

@yidawang
Copy link
Contributor Author

yidawang commented Jul 6, 2019

@yidawang do you folks happen to have an E2E example of Mask R-CNN with TVM? We'd be interested in this at FB for our object detector work.

I used the models here to benchmark, and quickly modified this file to run it E2E.

@yzhliu yzhliu merged commit f978887 into apache:master Jul 7, 2019
@yzhliu
Copy link
Member

yzhliu commented Jul 7, 2019

Thanks @yidawang

@yidawang yidawang deleted the deconv_x86 branch July 7, 2019 12:18
wweic pushed a commit to wweic/tvm that referenced this pull request Jul 11, 2019
* initialize cond 2d transpose scheduling on x86

* refine the scheduler a bit

* fix for lint

* address review comments; remove duplicate code

* fix lint
wweic pushed a commit to wweic/tvm that referenced this pull request Jul 11, 2019
* initialize cond 2d transpose scheduling on x86

* refine the scheduler a bit

* fix for lint

* address review comments; remove duplicate code

* fix lint
wweic pushed a commit to neo-ai/tvm that referenced this pull request Jul 11, 2019
* initialize cond 2d transpose scheduling on x86

* refine the scheduler a bit

* fix for lint

* address review comments; remove duplicate code

* fix lint
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