T
- data type for dValues()
output@Operator(group="sparse") public final class SparseFillEmptyRowsGrad<T> extends PrimitiveOp
Takes vectors reverse_index_map, shaped `[N]`, and grad_values, shaped `[N_full]`, where `N_full >= N` and copies data into either `d_values` or `d_default_value`. Here `d_values` is shaped `[N]` and `d_default_value` is a scalar.
d_values[j] = grad_values[reverse_index_map[j]] d_default_value = sum_{k : 0 .. N_full - 1} ( grad_values[k] * 1{k not in reverse_index_map})
operation
Modifier and Type | Method and Description |
---|---|
static <T> SparseFillEmptyRowsGrad<T> |
create(Scope scope,
Operand<Long> reverseIndexMap,
Operand<T> gradValues)
Factory method to create a class wrapping a new SparseFillEmptyRowsGrad operation.
|
Output<T> |
dDefaultValue()
0-D.
|
Output<T> |
dValues()
1-D.
|
equals, hashCode, op, toString
public static <T> SparseFillEmptyRowsGrad<T> create(Scope scope, Operand<Long> reverseIndexMap, Operand<T> gradValues)
scope
- current scopereverseIndexMap
- 1-D. The reverse index map from SparseFillEmptyRows.gradValues
- 1-D. The gradients from backprop.Copyright © 2022. All rights reserved.