From 1ca0ec7299b9352123a07525320a04e39d657781 Mon Sep 17 00:00:00 2001 From: Brennan Vincent Date: Mon, 26 Nov 2018 16:34:47 -0800 Subject: [PATCH] fix typo in `torch.sum` documentation (#14250) Summary: Notice that an extra colon was added to `:attr:`, so in https://pytorch.org/docs/stable/torch.html#torch.sum , `dim` shows up as ":attr::_dim_". This patch fixes the issue. Pull Request resolved: https://github.com/pytorch/pytorch/pull/14250 Reviewed By: soumith Differential Revision: D13146363 Pulled By: umanwizard fbshipit-source-id: f7d03dcb0973aae248b56ab407ba8489f2b1fe36 --- torch/_torch_docs.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/torch/_torch_docs.py b/torch/_torch_docs.py index afbe3f5..4b49385 100644 --- a/torch/_torch_docs.py +++ b/torch/_torch_docs.py @@ -4487,7 +4487,7 @@ Example:: .. function:: sum(input, dim, keepdim=False, dtype=None) -> Tensor Returns the sum of each row of the :attr:`input` tensor in the given -dimension :attr:`dim`. If :attr::`dim` is a list of dimensions, +dimension :attr:`dim`. If :attr:`dim` is a list of dimensions, reduce over all of them. If :attr:`keepdim` is ``True``, the output tensor is of the same size -- 2.7.4