class_docstr: A metric which returns the output of the given function on each batch.
  
  Args:
      name (str): The name of the metric.
      metric_function (func): A metric function('y_pred', 'y_true') to wrap.
class_docstr_tok: ["A","metric","which","returns","the","output","of","the","given","function","on","each","batch",".","Args",":","name","(","str",")",":","The","name","of","the","metric",".","metric_function","(","func",")",":","A","metric","function","(","'y_pred","'",",","'y_true","'",")","to","wrap","."]
docstr: Return the output of the wrapped function.
  
  Args:
      args: The :class:`.torchbearer.Trial` state.
  
  Returns:
      The value of the metric function('y_pred', 'y_true').
docstr_tok: ["Return","the","output","of","the","wrapped","function",".","Args",":","args",":","The",":","class",":","`",".torchbearer.Trial","`","state",".","Returns",":","The","value","of","the","metric","function","(","'y_pred","'",",","'y_true","'",")","."]
code: def process(self, *args):
      """Return the output of the wrapped function.
  
      Args:
          args: The :class:`.torchbearer.Trial` state.
  
      Returns:
          The value of the metric function('y_pred', 'y_true').
      """
      state = args[0]
      return self._metric_function(
          state[torchbearer.Y_PRED], state[torchbearer.Y_TRUE]
      )
  
imports: import torchbearer
  from torchbearer.bases import Metric
  from .metrics import AdvancedMetric
  import torch
label_desc: Use image node_id 2 for calling the BatchLambda obj's underlying member method code with example usage: obj.process() and returns: self