From 548fe682e28684b914dd792782a47135d40c8161 Mon Sep 17 00:00:00 2001 From: Meghan Lele Date: Fri, 13 Aug 2021 11:46:14 -0700 Subject: [PATCH] [docs] Add cross references to `torch.transpose` and `torch.t` (#63177) Summary: Pull Request resolved: https://github.com/pytorch/pytorch/pull/63177 **Summary** This commit adds a link in the documentation for `torch.transpose` that directs to `torch.t` and vice versa. These two functions are related and it is useful for users of one to know about the other. **Test Plan** Continuous integration. **Fixes** This commit fixes #56267. Test Plan: Imported from OSS Reviewed By: VitalyFedyunin Differential Revision: D30292654 Pulled By: SplitInfinity fbshipit-source-id: 8e60cd7a598ff8b4756cb30141399dfe8e118338 --- torch/_torch_docs.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/torch/_torch_docs.py b/torch/_torch_docs.py index 876862d..d23b1d1 100644 --- a/torch/_torch_docs.py +++ b/torch/_torch_docs.py @@ -9350,6 +9350,8 @@ Example:: tensor([[ 0.4875, 0.3938], [ 0.9158, -0.6929], [-0.5872, 0.6932]]) + +See also :func:`torch.transpose`. """.format(**common_args)) add_docstr(torch.flip, @@ -9709,6 +9711,8 @@ Example:: tensor([[ 1.0028, -0.1669], [-0.9893, 0.7299], [ 0.5809, 0.4942]]) + +See also :func:`torch.t`. """.format(**common_args)) add_docstr(torch.triangular_solve, -- 2.7.4