From 81764d1153c607e324390dcac107ea0970ba668c Mon Sep 17 00:00:00 2001 From: Michael Dagitses Date: Thu, 26 Aug 2021 17:26:52 -0700 Subject: [PATCH] document that `torch.triangular_solve` has optional out= parameter (#63253) Summary: Pull Request resolved: https://github.com/pytorch/pytorch/pull/63253 Fixes #57955 Test Plan: Imported from OSS Reviewed By: malfet Differential Revision: D30312134 Pulled By: dagitses fbshipit-source-id: 4f484620f5754f4324a99bbac1ff783c64cee6b8 --- torch/_torch_docs.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/torch/_torch_docs.py b/torch/_torch_docs.py index a4f3bda..bbb8d98 100644 --- a/torch/_torch_docs.py +++ b/torch/_torch_docs.py @@ -9679,7 +9679,7 @@ See also :func:`torch.t`. add_docstr(torch.triangular_solve, r""" -triangular_solve(b, A, upper=True, transpose=False, unitriangular=False) -> (Tensor, Tensor) +triangular_solve(b, A, upper=True, transpose=False, unitriangular=False, *, out=None) -> (Tensor, Tensor) Solves a system of equations with a triangular coefficient matrix :math:`A` and multiple right-hand sides :math:`b`. @@ -9706,6 +9706,10 @@ Args: If True, the diagonal elements of :math:`A` are assumed to be 1 and not referenced from :math:`A`. Default: ``False``. +Keyword args: + out ((Tensor, Tensor), optional): tuple of two tensors to write + the output to. Ignored if `None`. Default: `None`. + Returns: A namedtuple `(solution, cloned_coefficient)` where `cloned_coefficient` is a clone of :math:`A` and `solution` is the solution :math:`X` to :math:`AX = b` -- 2.7.4