class_docstr: A reducer is used for reducing a set of elements.
  
  A reducer is represented as a tuple of the three functions:
  - init_func - to define initial value: key => initial state
  - reducer_func - operation to perform on values with same key: (old state, input) => new state
  - finalize_func - value to return in the end: state => result
  
  For example,
  
  ```
  def init_func(_):
    return (0.0, 0.0)
  
  def reduce_func(state, value):
    return (state[0] + value['features'], state[1] + 1)
  
  def finalize_func(s, n):
    return s / n
  
  reducer = tf.data.experimental.Reducer(init_func, reduce_func, finalize_func)
  ```
class_docstr_tok: ["A","reducer","is","used","for","reducing","a","set","of","elements",".","A","reducer","is","represented","as","a","tuple","of","the","three","functions",":","-","init_func","-","to","define","initial","value",":","key","=",">","initial","state","-","reducer_func","-","operation","to","perform","on","values","with","same","key",":","(","old","state",",","input",")","=",">","new","state","-","finalize_func","-","value","to","return","in","the","end",":","state","=",">","result","For","example",",","``","`","def","init_func","(","_",")",":","return","(","0.0",",","0.0",")","def","reduce_func","(","state",",","value",")",":","return","(","state","[","0","]","+","value","[","'features","'","]",",","state","[","1","]","+","1",")","def","finalize_func","(","s",",","n",")",":","return","s","\/","n","reducer","=","tf.data.experimental.Reducer","(","init_func",",","reduce_func",",","finalize_func",")","``","`"]
code: def init_func(self):
      return self._init_func
  
imports: from tensorflow.python.data.ops import dataset_ops
  from tensorflow.python.data.ops import structured_function
  from tensorflow.python.data.util import nest
  from tensorflow.python.data.util import structure
  from tensorflow.python.framework import dtypes
  from tensorflow.python.framework import ops
  from tensorflow.python.framework import tensor_spec
  from tensorflow.python.ops import gen_experimental_dataset_ops
  from tensorflow.python.util import deprecation
  from tensorflow.python.util.tf_export import tf_export
label_desc: Use image node_id 2 for calling the Reducer obj's underlying member method code with example usage: obj.init_func() and returns: self