code: def log_metrics(
      self, metrics: Mapping[str, float], step: Optional[int] = None
  ) -> None:
      if self.clearml_model and self.clearml_cfg.log_metrics:
          metrics = {
              k: {
                  "value": str(v.item() if type(v) == Tensor else v),
                  "type": str(
                      type(v.item() if type(v) == Tensor else v)
                  ),
              }
              for k, v in metrics.items()
          }
          self.last_metrics = metrics
  
imports: import os
  from argparse import Namespace
  from dataclasses import dataclass
  from pathlib import Path
  from typing import Any, List, Literal, Mapping, Optional, Union
  import pandas
  from lightning_utilities.core.apply_func import apply_to_collection
  from omegaconf import DictConfig, ListConfig, OmegaConf
  from pytorch_lightning.callbacks import Checkpoint
  from pytorch_lightning.loggers import Logger
  from pytorch_lightning.utilities.parsing import AttributeDict
  from torch import Tensor
  from nemo.utils import logging
label_desc: Use image node_id 5 for calling the ClearMLLogger obj's underlying member method code with example usage: obj.log_metrics(metrics, step) without return types