tf.raw_ops.SparseMatrixMatMul
Stay organized with collections
Save and categorize content based on your preferences.
Matrix-multiplies a sparse matrix with a dense matrix.
tf.raw_ops.SparseMatrixMatMul(
a,
b,
transpose_a=False,
transpose_b=False,
adjoint_a=False,
adjoint_b=False,
transpose_output=False,
conjugate_output=False,
name=None
)
Returns a dense matrix.
For inputs A and B, where A is CSR and B is dense; this op returns a dense C;
If transpose_output is false, returns:
C = A . B
If transpose_output is true
, returns:
C = transpose(A . B) = transpose(B) . transpose(A)
where the transposition is performed along the two innermost (matrix)
dimensions.
If conjugate_output is true
, returns:
C = conjugate(A . B) = conjugate(A) . conjugate(B)
If both conjugate_output and transpose_output are true
, returns:
C = conjugate(transpose(A . B)) = conjugate(transpose(B)) .
conjugate(transpose(A))
Args |
a
|
A Tensor of type variant . A CSRSparseMatrix.
|
b
|
A Tensor . A dense tensor.
|
transpose_a
|
An optional bool . Defaults to False .
Indicates whether a should be transposed.
|
transpose_b
|
An optional bool . Defaults to False .
Indicates whether b should be transposed.
|
adjoint_a
|
An optional bool . Defaults to False .
Indicates whether a should be conjugate-transposed.
|
adjoint_b
|
An optional bool . Defaults to False .
Indicates whether b should be conjugate-transposed.
|
transpose_output
|
An optional bool . Defaults to False .
Transposes the product of a and b .
|
conjugate_output
|
An optional bool . Defaults to False .
Conjugates the product of a and b .
|
name
|
A name for the operation (optional).
|
Returns |
A Tensor . Has the same type as b .
|
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates. Some content is licensed under the numpy license.
Last updated 2024-04-26 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2024-04-26 UTC."],[],[],null,["# tf.raw_ops.SparseMatrixMatMul\n\n\u003cbr /\u003e\n\nMatrix-multiplies a sparse matrix with a dense matrix.\n\n#### View aliases\n\n\n**Compat aliases for migration**\n\nSee\n[Migration guide](https://www.tensorflow.org/guide/migrate) for\nmore details.\n\n[`tf.compat.v1.raw_ops.SparseMatrixMatMul`](https://www.tensorflow.org/api_docs/python/tf/raw_ops/SparseMatrixMatMul)\n\n\u003cbr /\u003e\n\n tf.raw_ops.SparseMatrixMatMul(\n a,\n b,\n transpose_a=False,\n transpose_b=False,\n adjoint_a=False,\n adjoint_b=False,\n transpose_output=False,\n conjugate_output=False,\n name=None\n )\n\nReturns a dense matrix.\nFor inputs A and B, where A is CSR and B is dense; this op returns a dense C;\n\nIf transpose_output is false, returns: \n\n C = A . B\n\nIf transpose_output is `true`, returns: \n\n C = transpose(A . B) = transpose(B) . transpose(A)\n\nwhere the transposition is performed along the two innermost (matrix)\ndimensions.\n\nIf conjugate_output is `true`, returns: \n\n C = conjugate(A . B) = conjugate(A) . conjugate(B)\n\nIf both conjugate_output and transpose_output are `true`, returns: \n\n C = conjugate(transpose(A . B)) = conjugate(transpose(B)) .\n conjugate(transpose(A))\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n| Args ---- ||\n|--------------------|------------------------------------------------------------------------------------------------|\n| `a` | A `Tensor` of type `variant`. A CSRSparseMatrix. |\n| `b` | A `Tensor`. A dense tensor. |\n| `transpose_a` | An optional `bool`. Defaults to `False`. Indicates whether `a` should be transposed. |\n| `transpose_b` | An optional `bool`. Defaults to `False`. Indicates whether `b` should be transposed. |\n| `adjoint_a` | An optional `bool`. Defaults to `False`. Indicates whether `a` should be conjugate-transposed. |\n| `adjoint_b` | An optional `bool`. Defaults to `False`. Indicates whether `b` should be conjugate-transposed. |\n| `transpose_output` | An optional `bool`. Defaults to `False`. Transposes the product of `a` and `b`. |\n| `conjugate_output` | An optional `bool`. Defaults to `False`. Conjugates the product of `a` and `b`. |\n| `name` | A name for the operation (optional). |\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n| Returns ------- ||\n|---|---|\n| A `Tensor`. Has the same type as `b`. ||\n\n\u003cbr /\u003e"]]