Skip to content

Conversation

@zou3519
Copy link
Contributor

@zou3519 zou3519 commented Oct 31, 2019

Stack from ghstack:

This PR adds support for calling those functions on named tensors. The
implementation is not the nicest: in the future we have plans to merge
names into TensorOptions, at which point we don't need the extra
branches that check if the tensor has names. Right now, however, these
functions are very useful to have (in particular, ones_like is used by
autograd to generate gradients).

Test Plan:

  • Added tests for each of these

Differential Revision: D18270937

This PR adds support for calling those functions on named tensors. The
implementation is not the nicest: in the future we have plans to merge
names into TensorOptions, at which point we don't need the extra
branches that check if the tensor has names. Right now, however, these
functions are very useful to have (in particular, ones_like is used by
autograd to generate gradients).

Test Plan:
- Added tests for each of these
zou3519 added a commit that referenced this pull request Oct 31, 2019
This PR adds support for calling those functions on named tensors. The
implementation is not the nicest: in the future we have plans to merge
names into TensorOptions, at which point we don't need the extra
branches that check if the tensor has names. Right now, however, these
functions are very useful to have (in particular, ones_like is used by
autograd to generate gradients).

Test Plan:
- Added tests for each of these

ghstack-source-id: b9f903b
Pull Request resolved: #28981
@zou3519 zou3519 requested review from gchanan, izdeby and nairbv October 31, 2019 19:44
…_like ops"

This PR adds support for calling those functions on named tensors. The
implementation is not the nicest: in the future we have plans to merge
names into TensorOptions, at which point we don't need the extra
branches that check if the tensor has names. Right now, however, these
functions are very useful to have (in particular, ones_like is used by
autograd to generate gradients).

Test Plan:
- Added tests for each of these
zou3519 added a commit that referenced this pull request Nov 1, 2019
This PR adds support for calling those functions on named tensors. The
implementation is not the nicest: in the future we have plans to merge
names into TensorOptions, at which point we don't need the extra
branches that check if the tensor has names. Right now, however, these
functions are very useful to have (in particular, ones_like is used by
autograd to generate gradients).

Test Plan:
- Added tests for each of these

ghstack-source-id: 65a94e2
Pull Request resolved: #28981
zdevito pushed a commit to zdevito/ATen that referenced this pull request Nov 1, 2019
Summary:
Pull Request resolved: pytorch/pytorch#28981

This PR adds support for calling those functions on named tensors. The
implementation is not the nicest: in the future we have plans to merge
names into TensorOptions, at which point we don't need the extra
branches that check if the tensor has names. Right now, however, these
functions are very useful to have (in particular, ones_like is used by
autograd to generate gradients).

Test Plan: - Added tests for each of these

Differential Revision: D18270937

Pulled By: zou3519

fbshipit-source-id: 720739ff0474449a960b81728345a4250becbfc3
@facebook-github-bot
Copy link
Contributor

@zou3519 merged this pull request in 71be5fe.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants