public abstract class
Reduce
Known Indirect Subclasses
BinaryCrossentropy<T extends TNumber>,
CategoricalCrossentropy<T extends TNumber>,
CategoricalHinge<T extends TNumber>,
CosineSimilarity<T extends TNumber>,
Hinge<T extends TNumber>,
KLDivergence<T extends TNumber>,
LogCoshError<T extends TNumber>,
MeanAbsoluteError<T extends TNumber>,
MeanAbsolutePercentageError<T extends TNumber>,
MeanMetricWrapper<T extends TNumber>,
MeanSquaredError<T extends TNumber>,
MeanSquaredLogarithmicError<T extends TNumber>,
Poisson<T extends TNumber>,
SparseCategoricalCrossentropy<T extends TNumber>,
SquaredHinge<T extends TNumber>
|
Encapsulates metrics that perform a reduce operation on the metric values.
Constants
Public Methods
Variable<T> |
getCount()
Gets the count variable
|
Class<T> |
getResultType()
Gets the type for the variables
|
Variable<T> |
getTotal()
Gets the total variable
|
Op |
resetStates()
Resets any state variables to their initial values
|
Operand<T> |
result()
Gets the current result of the metric
|
List<Op> |
updateStateList(Operand<? extends TNumber> values, Operand<? extends TNumber> sampleWeights)
Updates the metric variables based on the inputs.
|
Inherited Methods
final Operand<T> | |
String |
getName()
Gets the name of this metric.
|
long |
getSeed()
Gets the random number generator seed value
|
Ops |
getTF()
Gets the TensorFlow Ops
|
abstract Op |
resetStates()
Resets any state variables to their initial values
|
abstract Operand<T> |
result()
Gets the current result of the metric
|
final Op | |
final Op |
updateState(Operand<? extends TNumber> values, Operand<? extends TNumber> sampleWeights)
Creates a NoOp Operation with control dependencies to update the metric state
|
List<Op> | |
List<Op> |
updateStateList(Operand<? extends TNumber> values, Operand<? extends TNumber> sampleWeights)
Creates a List of Operations to update the metric state based on input values.
|
boolean |
equals(Object arg0)
|
final Class<?> |
getClass()
|
int |
hashCode()
|
final void |
notify()
|
final void |
notifyAll()
|
String |
toString()
|
final void |
wait(long arg0, int arg1)
|
final void |
wait(long arg0)
|
final void |
wait()
|
Constants
public static final String COUNT
Constant Value:
"count"
public static final String TOTAL
Constant Value:
"total"
Public Methods
public Class<T> getResultType ()
Gets the type for the variables
Returns
- the type for the variables
public Op resetStates ()
Resets any state variables to their initial values
Returns
- the control operation for doing the reset
public Operand<T> result ()
Gets the current result of the metric
Returns
- the result, possibly with control dependencies
public List<Op> updateStateList (Operand<? extends TNumber> values, Operand<? extends TNumber> sampleWeights)
Updates the metric variables based on the inputs. At least one input arg required for
values
, an optional additional input for the sampleWeights
Parameters
values | the inputs to be passed to update state, this may not be null |
---|---|
sampleWeights | sample weights to be applied to values, may be null. |
Returns
- the result with a control dependency on update state Operands
Throws
IllegalArgumentException | if values is null |
---|