code: def __init__(
      self,
      metrics,
      weighted_metrics,
      name="compile_metric",
      output_names=None,
  ):
      super().__init__(name=name)
      if metrics and not isinstance(metrics, (list, tuple, dict)):
          raise ValueError(
              "Expected `metrics` argument to be a list, tuple, or dict. "
              f"Received instead: metrics={metrics} of type {type(metrics)}"
          )
      if weighted_metrics and not isinstance(
          weighted_metrics, (list, tuple, dict)
      ):
          raise ValueError(
              "Expected `weighted_metrics` argument to be a list, tuple, or "
              f"dict. Received instead: weighted_metrics={weighted_metrics} "
              f"of type {type(weighted_metrics)}"
          )
      self._user_metrics = metrics
      self._user_weighted_metrics = weighted_metrics
      self.built = False
      self.name = "compile_metrics"
      self.output_names = output_names
  
imports: import tree
  from keras import backend
  from keras import losses
  from keras import metrics
  from keras import ops
  from keras.utils.naming import get_object_name
label_desc: Use image node_id 1 to create a new CompileMetrics object from inherited base classes: metrics_module with example: obj = CompileMetrics(metrics, weighted_metrics, name, output_names)