class_docstr: Generic Loss interface.
  A loss has a name, a configuration, and stores information about the output and label it requires from the model(s),
  as well as a weight (default 1.0) and a method to create the corresponding metric.
class_docstr_tok: ["Generic","Loss","interface",".","A","loss","has","a","name",",","a","configuration",",","and","stores","information","about","the","output","and","label","it","requires","from","the","model","(","s",")",",","as","well","as","a","weight","(","default","1.0",")","and","a","method","to","create","the","corresponding","metric","."]
docstr: Loss retrieves the required output and label.
code: def __call__(self, outputs: Dict[str, Any], labels: Dict[str, Any]):
      """
      Loss retrieves the required output and label.
      """
      utils.check_condition(
          self.output_name in outputs,
          "output '%s' not found. Loss requires this output key"
          % self.output_name,
      )
      utils.check_condition(
          self.label_name in labels,
          "label '%s' not found. Loss requires this label key"
          % self.output_name,
      )
      output = outputs[self.output_name]
      label = labels[self.label_name]
  
      return super().__call__(output, label)
  
imports: import logging
  import math
  from abc import ABC, abstractmethod
  from typing import Any, Dict, Optional, Tuple
  import torch
  import numpy
  from .None import constants
  from .None import utils
label_desc: Use image node_id 2 for calling the Loss obj's underlying member method code with example usage: obj.__call__(outputs, labels) and returns: super