MCPcopy Create free account
hub / github.com/DeepRec-AI/DeepRec / Reducer

Class Reducer

tensorflow/contrib/data/python/ops/grouping.py:146–157  ·  view source on GitHub ↗

A reducer is used for reducing a set of elements. A reducer is represented as a tuple of the three functions: 1) initialization function: key => initial state 2) reduce function: (old state, input) => new state 3) finalization function: state => result

Source from the content-addressed store, hash-verified

144
145
146class Reducer(grouping.Reducer):
147 """A reducer is used for reducing a set of elements.
148
149 A reducer is represented as a tuple of the three functions:
150 1) initialization function: key => initial state
151 2) reduce function: (old state, input) => new state
152 3) finalization function: state => result
153 """
154
155 @deprecation.deprecated(None, "Use `tf.data.experimental.Reducer(...)`.")
156 def __init__(self, init_func, reduce_func, finalize_func):
157 super(Reducer, self).__init__(init_func, reduce_func, finalize_func)

Callers 2

ComputeMethod · 0.50
ReduceOperandFunction · 0.50

Calls

no outgoing calls

Tested by

no test coverage detected