code: def _get_score(
      metric: IMetric,
      predictions: np.ndarray,
      labels: np.ndarray,
  ) -> float:
      np_batch = {LABEL_KEY: labels}
      np_outputs = {PREDICTIONS_KEY: predictions}
      return metric.evaluate(np_batch, np_outputs).final_score
  
file_path: carefree-learn/tests/test_metrics.py
imports: import cflearn
  import unittest
  import numpy
  from cflearn.schema import IMetric
  from cflearn.constants import LABEL_KEY
  from cflearn.constants import PREDICTIONS_KEY
label_desc: Use image node_id 1 for calling a global function with example usage: _get_score(metric, predictions, labels) and returns: metric