aboutsummaryrefslogtreecommitdiffhomepage
path: root/tensorflow/docs_src/api_guides/python/sparse_ops.md
blob: b360055ed0ed0cde59a68c89f0a0f4ae1d5758ab (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
# Sparse Tensors

Note: Functions taking `Tensor` arguments can also take anything accepted by
`tf.convert_to_tensor`.

[TOC]

## Sparse Tensor Representation

TensorFlow supports a `SparseTensor` representation for data that is sparse
in multiple dimensions. Contrast this representation with `IndexedSlices`,
which is efficient for representing tensors that are sparse in their first
dimension, and dense along all other dimensions.

*   `tf.SparseTensor`
*   `tf.SparseTensorValue`

## Conversion

*   `tf.sparse_to_dense`
*   `tf.sparse_tensor_to_dense`
*   `tf.sparse_to_indicator`
*   `tf.sparse_merge`

## Manipulation

*   `tf.sparse_concat`
*   `tf.sparse_reorder`
*   `tf.sparse_reshape`
*   `tf.sparse_split`
*   `tf.sparse_retain`
*   `tf.sparse_reset_shape`
*   `tf.sparse_fill_empty_rows`
*   `tf.sparse_transpose`

## Reduction
*   `tf.sparse_reduce_sum`
*   `tf.sparse_reduce_sum_sparse`

## Math Operations
*   `tf.sparse_add`
*   `tf.sparse_softmax`
*   `tf.sparse_tensor_dense_matmul`
*   `tf.sparse_maximum`
*   `tf.sparse_minimum`