class_docstr: A sparse representation of a set of tensor slices at given indices.
  
  This class is a simple wrapper for a pair of `Tensor` objects:
  
  * `values`: A `Tensor` of any dtype with shape `[D0, D1, ..., Dn]`.
  * `indices`: A 1-D integer `Tensor` with shape `[D0]`.
  
  An `IndexedSlices` is typically used to represent a subset of a larger
  tensor `dense` of shape `[LARGE0, D1, .. , DN]` where `LARGE0 >> D0`.
  The values in `indices` are the indices in the first dimension of
  the slices that have been extracted from the larger tensor.
  
  The dense tensor `dense` represented by an `IndexedSlices` `slices` has
  
  ```python
  dense[slices.indices[i], :, :, :, ...] = slices.values[i, :, :, :, ...]
  ```
  
  The `IndexedSlices` class is used principally in the definition of
  gradients for operations that have sparse gradients
  (e.g. `tf.gather`).
  
  >>> v = tf.Variable([[0.,1, 2], [2, 3, 4], [4, 5, 6], [6, 7, 8]])
  >>> with tf.GradientTape() as tape:
  ...   r = tf.gather(v, [1,3])
  >>> index_slices = tape.gradient(r,v)
  >>> index_slices
  <...IndexedSlices object ...>
  >>> index_slices.indices.numpy()
  array([1, 3], dtype=int32)
  >>> index_slices.values.numpy()
  array([[1., 1., 1.],
         [1., 1., 1.]], dtype=float32)
  
  Contrast this representation with
  `tf.sparse.SparseTensor`,
  which uses multi-dimensional indices and scalar values.
class_docstr_tok: ["A","sparse","representation","of","a","set","of","tensor","slices","at","given","indices",".","This","class","is","a","simple","wrapper","for","a","pair","of","`","Tensor","`","objects",":","*","`","values","`",":","A","`","Tensor","`","of","any","dtype","with","shape","`","[","D0",",","D1",",","...",",","Dn","]","`",".","*","`","indices","`",":","A","1-D","integer","`","Tensor","`","with","shape","`","[","D0","]","`",".","An","`","IndexedSlices","`","is","typically","used","to","represent","a","subset","of","a","larger","tensor","`","dense","`","of","shape","`","[","LARGE0",",","D1",",","..",",","DN","]","`","where","`","LARGE0",">",">","D0","`",".","The","values","in","`","indices","`","are","the","indices","in","the","first","dimension","of","the","slices","that","have","been","extracted","from","the","larger","tensor",".","The","dense","tensor","`","dense","`","represented","by","an","`","IndexedSlices","`","`","slices","`","has","``","`","python","dense","[","slices.indices","[","i","]",",",":",",",":",",",":",",","...","]","=","slices.values","[","i",",",":",",",":",",",":",",","...","]","``","`","The","`","IndexedSlices","`","class","is","used","principally","in","the","definition","of","gradients","for","operations","that","have","sparse","gradients","(","e.g",".","`","tf.gather","`",")",".",">",">",">","v","=","tf.Variable","(","[","[","0.,1",",","2","]",",","[","2",",","3",",","4","]",",","[","4",",","5",",","6","]",",","[","6",",","7",",","8","]","]",")",">",">",">","with","tf.GradientTape","(",")","as","tape",":","...","r","=","tf.gather","(","v",",","[","1,3","]",")",">",">",">","index_slices","=","tape.gradient","(","r",",","v",")",">",">",">","index_slices","<","...","IndexedSlices","object","...",">",">",">",">","index_slices.indices.numpy","(",")","array","(","[","1",",","3","]",",","dtype=int32",")",">",">",">","index_slices.values.numpy","(",")","array","(","[","[","1.",",","1.",",","1",".","]",",","[","1.",",","1.",",","1",".","]","]",",","dtype=float32",")","Contrast","this","representation","with","`","tf.sparse.SparseTensor","`",",","which","uses","multi-dimensional","indices","and","scalar","values","."]
docstr: The `Operation` that produces `values` as an output.
code: def op(self) -> ops.Operation:
      """The `Operation` that produces `values` as an output."""
      return self.values.op
  
imports: import collections
  import warnings
  import numpy
  from tensorflow.core.protobuf import struct_pb2
  from tensorflow.python import tf2
  from tensorflow.python.eager import context
  from tensorflow.python.framework import composite_tensor
  from tensorflow.python.framework import composite_tensor_gradient
  from tensorflow.python.framework import dtypes
  from tensorflow.python.framework import ops
  from tensorflow.python.framework import tensor_conversion_registry
  from tensorflow.python.framework import tensor_shape
  from tensorflow.python.framework import tensor_spec
  from tensorflow.python.framework import tensor_util
  from tensorflow.python.framework import type_spec
  from tensorflow.python.ops import gen_math_ops
  from tensorflow.python.saved_model import nested_structure_coder
  from tensorflow.python.types import internal
  from tensorflow.python.util.compat import collections_abc
  from tensorflow.python.util.tf_export import tf_export
label_desc: Use image node_id 8 for calling the IndexedSlices obj's underlying member method code with example usage: obj.op() and returns: self