diff options
author | Jonathan Hseu <jhseu@google.com> | 2016-11-16 17:04:14 -0800 |
---|---|---|
committer | TensorFlower Gardener <gardener@tensorflow.org> | 2016-11-16 17:22:34 -0800 |
commit | 7e8728662120df0a80720bb7527613f96d58271e (patch) | |
tree | 7a224c0cbd874c05be01445750d1526166abed0b /tensorflow/contrib/solvers | |
parent | d38fb783e5c1801949ea9ccebfd14afa1cb17dff (diff) |
Rename `Tensor` to `Output` in all Python docs
Generated by running:
$ find . -name '*.py' | xargs sed -i 's/a `Tensor`/an `Output`/g'
$ find . -name '*.py' | xargs sed -i 's/A `Tensor`/An `Output`/g'
$ find . -name '*.py' | xargs sed -i 's/`Tensor`/`Output`/g'
$ find . -name '*.py' | xargs sed -i 's/`tf.Tensor`/`tf.Output`/g'
$ find . -name '*.py' | xargs sed -i 's/`Tensors`/`Output`s/g'
$ find . -name '*.py' | xargs sed -i 's/#Tensor)/#Output)/g'
$ find . -name '*.py' | xargs sed -i 's/#Tensor\./#Output./g'
Manually fixed up lines that exceeded 80 characters after the change.
Change: 139400135
Diffstat (limited to 'tensorflow/contrib/solvers')
-rw-r--r-- | tensorflow/contrib/solvers/python/ops/lanczos.py | 18 | ||||
-rw-r--r-- | tensorflow/contrib/solvers/python/ops/least_squares.py | 12 | ||||
-rw-r--r-- | tensorflow/contrib/solvers/python/ops/linear_equations.py | 12 |
3 files changed, 21 insertions, 21 deletions
diff --git a/tensorflow/contrib/solvers/python/ops/lanczos.py b/tensorflow/contrib/solvers/python/ops/lanczos.py index 10ef60d0db..4e666c24dc 100644 --- a/tensorflow/contrib/solvers/python/ops/lanczos.py +++ b/tensorflow/contrib/solvers/python/ops/lanczos.py @@ -46,7 +46,7 @@ def lanczos_bidiag(operator, Args: operator: An object representing a linear operator with attributes: - - shape: Either a list of integers or a 1-D `Tensor` of type `int32` of + - shape: Either a list of integers or a 1-D `Output` of type `int32` of length 2. `shape[0]` is the dimension on the domain of the operator, `shape[1]` is the dimension of the co-domain of the operator. On other words, if operator represents an M x N matrix A, `shape` must contain @@ -65,20 +65,20 @@ def lanczos_bidiag(operator, may terminate before `k` steps have been run. orthogonalize: If `True`, perform full orthogonalization. If `False` no orthogonalization is performed. - starting_vector: If not null, must be a `Tensor` of shape `[n]`. + starting_vector: If not null, must be an `Output` of shape `[n]`. name: A name scope for the operation. Returns: output: A namedtuple representing a Lanczos bidiagonalization of `operator` with attributes: - u: A rank-2 `Tensor` of type `operator.dtype` and shape + u: A rank-2 `Output` of type `operator.dtype` and shape `[operator.shape[0], k_actual+1]`, where `k_actual` is the number of steps run. - v: A rank-2 `Tensor` of type `operator.dtype` and shape + v: A rank-2 `Output` of type `operator.dtype` and shape `[operator.shape[1], k_actual]`, where `k_actual` is the number of steps run. - alpha: A rank-1 `Tensor` of type `operator.dtype` and shape `[k]`. - beta: A rank-1 `Tensor` of type `operator.dtype` and shape `[k]`. + alpha: A rank-1 `Output` of type `operator.dtype` and shape `[k]`. + beta: A rank-1 `Output` of type `operator.dtype` and shape `[k]`. """ def tarray(size, dtype, name): @@ -209,9 +209,9 @@ def bidiag_matmul(matrix, alpha, beta, adjoint_b=False, name="bidiag_matmul"): A * diag(alpha) + [zeros(m,1), A[:, :-1] * diag(beta[:-1])] Args: - matrix: A rank-2 `Tensor` representing matrix A. - alpha: A rank-1 `Tensor` representing the diagonal of B. - beta: A rank-1 `Tensor` representing the lower subdiagonal diagonal of B. + matrix: A rank-2 `Output` representing matrix A. + alpha: A rank-1 `Output` representing the diagonal of B. + beta: A rank-1 `Output` representing the lower subdiagonal diagonal of B. adjoint_b: `bool` determining what to compute. name: A name scope for the operation. diff --git a/tensorflow/contrib/solvers/python/ops/least_squares.py b/tensorflow/contrib/solvers/python/ops/least_squares.py index 9a2d3b24dd..f80910ffe7 100644 --- a/tensorflow/contrib/solvers/python/ops/least_squares.py +++ b/tensorflow/contrib/solvers/python/ops/least_squares.py @@ -40,7 +40,7 @@ def cgls(operator, rhs, tol=1e-6, max_iter=20, name="cgls"): Args: operator: An object representing a linear operator with attributes: - - shape: Either a list of integers or a 1-D `Tensor` of type `int32` of + - shape: Either a list of integers or a 1-D `Output` of type `int32` of length 2. `shape[0]` is the dimension on the domain of the operator, `shape[1]` is the dimension of the co-domain of the operator. On other words, if operator represents an M x N matrix A, `shape` must contain @@ -55,7 +55,7 @@ def cgls(operator, rhs, tol=1e-6, max_iter=20, name="cgls"): to `x`, i.e. if `operator` represents matrix `A`, `apply_adjoint` should return `conj(transpose(A)) * x`. - rhs: A rank-1 `Tensor` of shape `[M]` containing the right-hand size vector. + rhs: A rank-1 `Output` of shape `[M]` containing the right-hand size vector. tol: A float scalar convergence tolerance. max_iter: An integer giving the maximum number of iterations. name: A name scope for the operation. @@ -63,10 +63,10 @@ def cgls(operator, rhs, tol=1e-6, max_iter=20, name="cgls"): Returns: output: A namedtuple representing the final state with fields: - - i: A scalar `int32` `Tensor`. Number of iterations executed. - - x: A rank-1 `Tensor` of shape `[N]` containing the computed solution. - - r: A rank-1 `Tensor` of shape `[M]` containing the residual vector. - - p: A rank-1 `Tensor` of shape `[N]`. The next descent direction. + - i: A scalar `int32` `Output`. Number of iterations executed. + - x: A rank-1 `Output` of shape `[N]` containing the computed solution. + - r: A rank-1 `Output` of shape `[M]` containing the residual vector. + - p: A rank-1 `Output` of shape `[N]`. The next descent direction. - gamma: \\(||A^* r||_2^2\\) """ # ephemeral class holding CGLS state. diff --git a/tensorflow/contrib/solvers/python/ops/linear_equations.py b/tensorflow/contrib/solvers/python/ops/linear_equations.py index 41fd6e466b..38c94addd0 100644 --- a/tensorflow/contrib/solvers/python/ops/linear_equations.py +++ b/tensorflow/contrib/solvers/python/ops/linear_equations.py @@ -41,7 +41,7 @@ def conjugate_gradient(operator, Args: operator: An object representing a linear operator with attributes: - - shape: Either a list of integers or a 1-D `Tensor` of type `int32` of + - shape: Either a list of integers or a 1-D `Output` of type `int32` of length 2. `shape[0]` is the dimension on the domain of the operator, `shape[1]` is the dimension of the co-domain of the operator. On other words, if operator represents an N x N matrix A, `shape` must contain @@ -50,17 +50,17 @@ def conjugate_gradient(operator, - apply: Callable object taking a vector `x` as input and returning a vector with the result of applying the operator to `x`, i.e. if `operator` represents matrix `A`, `apply` should return `A * x`. - rhs: A rank-1 `Tensor` of shape `[N]` containing the right-hand size vector. + rhs: A rank-1 `Output` of shape `[N]` containing the right-hand size vector. tol: A float scalar convergence tolerance. max_iter: An integer giving the maximum number of iterations. name: A name scope for the operation. Returns: output: A namedtuple representing the final state with fields: - - i: A scalar `int32` `Tensor`. Number of iterations executed. - - x: A rank-1 `Tensor` of shape `[N]` containing the computed solution. - - r: A rank-1 `Tensor` of shape `[M]` containing the residual vector. - - p: A rank-1 `Tensor` of shape `[N]`. `A`-conjugate basis vector. + - i: A scalar `int32` `Output`. Number of iterations executed. + - x: A rank-1 `Output` of shape `[N]` containing the computed solution. + - r: A rank-1 `Output` of shape `[M]` containing the residual vector. + - p: A rank-1 `Output` of shape `[N]`. `A`-conjugate basis vector. - gamma: \\(||r||_2^2\\) """ # ephemeral class holding CG state. |