docstr: Update all metrics.
  
  Args:
      out (Tensor): Prediction.
      target (Tensor): Ground truth.
      loss (Tensor): Loss from the criterion.
      filter (str): Only update metrics according to this filter.
code: def _update_metrics(self, out, target, loss, filter=""):
      """
      Update all metrics.
  
      Args:
          out (Tensor): Prediction.
          target (Tensor): Ground truth.
          loss (Tensor): Loss from the criterion.
          filter (str): Only update metrics according to this filter.
      """
      for met_name, metric in self.metrics.items():
          if filter in met_name:
              if "loss" in met_name:
                  metric.update(loss)
              else:
                  metric.update(out, target)
  
file_path: baal/baal/metrics/mixin.py
imports: from typing import Callable, Dict, Any, Optional, DefaultDict, Union
  import numpy
  from torchmetrics import Metric
  from baal.utils.metrics import Metrics
label_desc: Use image node_id 5 for calling the MetricMixin obj's underlying member method code with example usage: obj._update_metrics(out, target, loss, filter) without return types