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

[Relay/Topi][Op] Conv1D #4639

Merged
merged 30 commits into from
Jan 11, 2020
Merged

[Relay/Topi][Op] Conv1D #4639

merged 30 commits into from
Jan 11, 2020

Conversation

jwfromm
Copy link
Contributor

@jwfromm jwfromm commented Jan 7, 2020

As NLP models become increasingly important in industry it's important we have first class support for Conv1D with dilation. This PR adds the Conv1D operation to Topi and Relay for both CPU and GPU. It supports both NCW and NWC layouts natively.

Conv1D is implemented in the ONNX frontend our current convolution testing for ONNX is expanded.

@jwfromm
Copy link
Contributor Author

jwfromm commented Jan 7, 2020

@optima2005, @kevinthesun, Can one of you take a look at this PR?

@jwfromm
Copy link
Contributor Author

jwfromm commented Jan 9, 2020

@masahi, maybe you could take a look too.

@masahi masahi self-assigned this Jan 9, 2020
python/tvm/relay/frontend/onnx.py Outdated Show resolved Hide resolved
tests/python/frontend/onnx/test_forward.py Show resolved Hide resolved
tests/python/frontend/onnx/test_forward.py Outdated Show resolved Hide resolved
tests/python/frontend/onnx/test_forward.py Outdated Show resolved Hide resolved
topi/python/topi/cuda/conv1d.py Show resolved Hide resolved
@jwfromm
Copy link
Contributor Author

jwfromm commented Jan 10, 2020

@optima2005 I think I've addressed all your comments. Can you take another look and let me know what you think?

@optima2005
Copy link
Contributor

LGTM. Thanks @jwfromm
But I am not quite confident to the schedule template part. @masahi

@masahi masahi merged commit 35099e6 into apache:master Jan 11, 2020
@masahi
Copy link
Member

masahi commented Jan 11, 2020

Thanks @jwfromm @optima2005

@jwfromm jwfromm deleted the conv1d_op branch January 11, 2020 22:51
alexwong pushed a commit to alexwong/tvm that referenced this pull request Feb 26, 2020
* added conv1d operators to topi.

* Started to add python testing.

* Added python conv1d implementation for testing.

* Wrote test but need to add cuda schedule :(

* Cuda schedules working for both conv1d layouts.

* All topi tests passing.

* Formatting topi.

* Removed pad_method option as its probably overkill.

* Added relay op definition of conv1d.

* End2end conv1d working with onnx.

* Lint fixes.

* Formatting fixes.

* Rebase fix.

* Switched to array based attributes for consistency across convs.

* Improved onnx parsing and testing for convolutions.

* lint fix

* Tiny tweak.

* Bug fix

* Rebase fix.

* Add group ignore to onnx conv1d frontend.

* Unified MakeConv and fixed documentation.

* improved autopadding

* Addressed feedback and simplified onnx frontend.

* Format fix.

* Basic X86 NCW schedule working.

* Added nwc schedule.

* fixed name

* Added more tests and basic x86 schedules.

* Format fix.

* Added non power of two shape tests.
alexwong pushed a commit to alexwong/tvm that referenced this pull request Feb 28, 2020
* added conv1d operators to topi.

* Started to add python testing.

* Added python conv1d implementation for testing.

* Wrote test but need to add cuda schedule :(

* Cuda schedules working for both conv1d layouts.

* All topi tests passing.

* Formatting topi.

* Removed pad_method option as its probably overkill.

* Added relay op definition of conv1d.

* End2end conv1d working with onnx.

* Lint fixes.

* Formatting fixes.

* Rebase fix.

* Switched to array based attributes for consistency across convs.

* Improved onnx parsing and testing for convolutions.

* lint fix

* Tiny tweak.

* Bug fix

* Rebase fix.

* Add group ignore to onnx conv1d frontend.

* Unified MakeConv and fixed documentation.

* improved autopadding

* Addressed feedback and simplified onnx frontend.

* Format fix.

* Basic X86 NCW schedule working.

* Added nwc schedule.

* fixed name

* Added more tests and basic x86 schedules.

* Format fix.

* Added non power of two shape tests.
zhiics pushed a commit to neo-ai/tvm that referenced this pull request Mar 2, 2020
* added conv1d operators to topi.

* Started to add python testing.

* Added python conv1d implementation for testing.

* Wrote test but need to add cuda schedule :(

* Cuda schedules working for both conv1d layouts.

* All topi tests passing.

* Formatting topi.

* Removed pad_method option as its probably overkill.

* Added relay op definition of conv1d.

* End2end conv1d working with onnx.

* Lint fixes.

* Formatting fixes.

* Rebase fix.

* Switched to array based attributes for consistency across convs.

* Improved onnx parsing and testing for convolutions.

* lint fix

* Tiny tweak.

* Bug fix

* Rebase fix.

* Add group ignore to onnx conv1d frontend.

* Unified MakeConv and fixed documentation.

* improved autopadding

* Addressed feedback and simplified onnx frontend.

* Format fix.

* Basic X86 NCW schedule working.

* Added nwc schedule.

* fixed name

* Added more tests and basic x86 schedules.

* Format fix.

* Added non power of two shape tests.
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