pytorch
7970e572 - Rename tensor.view_names -> tensor.renamed (#25711)

Commit
6 years ago
Rename tensor.view_names -> tensor.renamed (#25711) Summary: Pull Request resolved: https://github.com/pytorch/pytorch/pull/25711 This function renames the dimensions of a tensor out-of-place. Because of that, I think `tensor.renamed(...)` is a clearer name: `view_names` has the connotation that we can use names to `view` our tensors with a "different shape", but what this function really does is let us rename a tensor no matter the previous names. `tensor.names_`, the in-place version of this, is unchanged for now. However, we might delete this or not advertise it if it has no use case and also because its naming is a little inconsistent with `tensor.renamed`. Test Plan: - [namedtensor ci] Differential Revision: D17206515 Pulled By: zou3519 fbshipit-source-id: 67053951fcc8130c84566b5ebbdce35ef619c90d
Author
Parents
Loading