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] Add gradient for reshape #3901

Merged
merged 1 commit into from
Sep 6, 2019
Merged

Conversation

MarisaKirisame
Copy link
Contributor

Thanks for contributing to TVM! Please refer to guideline https://docs.tvm.ai/contribute/ for useful information and tips. After the pull request is submitted, please request code reviews from Reviewers.
@SWu @vinx13 @Ruinhuang can you guys help review?

@@ -247,6 +247,7 @@ def verify_reshape(shape, newshape, oshape):
assert zz.checked_type == relay.ty.TensorType(oshape, "float32")

func = relay.Function([x], z)
check_grad(func)
Copy link
Contributor

Choose a reason for hiding this comment

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

I think it might be a good idea to separate this test out since gradient is implemented separately from the op

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This allow us to get the same coverage for both test_op_level3 and test_op_grad_level3. I think we should move toward this style.

Copy link
Contributor

Choose a reason for hiding this comment

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

True. I think grad implementations could also use some refactoring to move around; it would be more convenient implementation-wise to put grad implementations next to their forward op implementations as well.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

That also sounds good. Tensor_grad is getting big.

@jroesch jroesch merged commit 02ddb5a into apache:master Sep 6, 2019
MarisaKirisame added a commit to MarisaKirisame/tvm that referenced this pull request Sep 7, 2019
wweic pushed a commit to wweic/tvm that referenced this pull request Sep 16, 2019
wweic pushed a commit to wweic/tvm that referenced this pull request Sep 16, 2019
wweic pushed a commit to neo-ai/tvm that referenced this pull request Sep 16, 2019
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