Decorated function with `add_update()`.
(metric_obj, *args, **kwargs)
| 69 | """ |
| 70 | |
| 71 | def decorated(metric_obj, *args, **kwargs): |
| 72 | """Decorated function with `add_update()`.""" |
| 73 | |
| 74 | with tf_utils.graph_context_for_symbolic_tensors(*args, **kwargs): |
| 75 | update_op = update_state_fn(*args, **kwargs) |
| 76 | if update_op is not None: # update_op will be None in eager execution. |
| 77 | metric_obj.add_update(update_op) |
| 78 | return update_op |
| 79 | |
| 80 | return tf_decorator.make_decorator(update_state_fn, decorated) |
| 81 |
nothing calls this directly
no test coverage detected