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

Method _apply_sparse

tensorflow/contrib/optimizer_v2/adam.py:175–180  ·  view source on GitHub ↗
(self, grad, var, state)

Source from the content-addressed store, hash-verified

173 return control_flow_ops.group(*[var_update, m_t, v_t])
174
175 def _apply_sparse(self, grad, var, state):
176 return self._apply_sparse_shared(
177 grad.values, var, grad.indices,
178 lambda x, i, v: state_ops.scatter_add( # pylint: disable=g-long-lambda
179 x, i, v, use_locking=self._use_locking),
180 state)
181
182 def _resource_scatter_add(self, x, i, v):
183 with ops.control_dependencies(

Callers

nothing calls this directly

Calls 2

_apply_sparse_sharedMethod · 0.95
scatter_addMethod · 0.45

Tested by

no test coverage detected