Created
October 11, 2019 17:37
-
-
Save vaibkumr/c43b8d169ac5c85be4783380bed34ad1 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import torch | |
# Unary operator on named tensors | |
t = torch.randn(4, 2, names=('N', 'C')) | |
t = t.abs() | |
t.names #output: ('N', 'C') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment