class_docstr: Abstract class for defining callbacks for use with [Optimizer.minimize](vis.optimizer.md#optimizerminimize).
      
class_docstr_tok: ["Abstract","class","for","defining","callbacks","for","use","with","[","Optimizer.minimize","]","(","vis.optimizer.md","#","optimizerminimize",")","."]
docstr: This function will be called within [optimizer.minimize](vis.optimizer.md#minimize).
  
  Args:
      i: The optimizer iteration.
      named_losses: List of `(loss_name, loss_value)` tuples.
      overall_loss: Overall weighted loss.
      grads: The gradient of input image with respect to `wrt_value`.
      wrt_value: The current `wrt_value`.
docstr_tok: ["This","function","will","be","called","within","[","optimizer.minimize","]","(","vis.optimizer.md","#","minimize",")",".","Args",":","i",":","The","optimizer","iteration",".","named_losses",":","List","of","`","(","loss_name",",","loss_value",")","`","tuples",".","overall_loss",":","Overall","weighted","loss",".","grads",":","The","gradient","of","input","image","with","respect","to","`","wrt_value","`",".","wrt_value",":","The","current","`","wrt_value","`","."]
code: def callback(self, i, named_losses, overall_loss, grads, wrt_value):
      """This function will be called within [optimizer.minimize](vis.optimizer.md#minimize).
  
      Args:
          i: The optimizer iteration.
          named_losses: List of `(loss_name, loss_value)` tuples.
          overall_loss: Overall weighted loss.
          grads: The gradient of input image with respect to `wrt_value`.
          wrt_value: The current `wrt_value`.
      """
      raise NotImplementedError()
  
file_path: keras-vis/vis/callbacks.py
imports: from __future__ import absolute_import
  import pprint
  import numpy
  from .utils import utils
label_desc: Use image node_id 1 for calling the OptimizerCallback obj's underlying member method code with example usage: obj.callback(i, named_losses, overall_loss, grads, wrt_value) without return types