Allow loss to be passed as a Tensor to Optimizer.minimize
PiperOrigin-RevId: 323895500
This commit is contained in:
parent
cea9e01670
commit
d5e34b77c8
1 changed files with 1 additions and 1 deletions
|
@ -151,7 +151,7 @@ class TestOptimizer(OptimizerV2):
|
||||||
self.iterations = tf.constant(1, dtype=tf.float32)
|
self.iterations = tf.constant(1, dtype=tf.float32)
|
||||||
self._iterations = tf.constant(1, dtype=tf.float32)
|
self._iterations = tf.constant(1, dtype=tf.float32)
|
||||||
|
|
||||||
def _compute_gradients(self, loss, var_list, grad_loss=None):
|
def _compute_gradients(self, loss, var_list, grad_loss=None, tape=None):
|
||||||
return 'test'
|
return 'test'
|
||||||
|
|
||||||
def get_config(self):
|
def get_config(self):
|
||||||
|
|
Loading…
Reference in a new issue