code: def scalarize(value):
      """Converts a namedtuple or dictionary containing tensors
      to their scalar value
      Arguments:
      ----------
      value: dict or namedtuple
          a dictionary or named tuple of tensors
      Returns
      -------
      result: dict
          a result dictionary
      """
      if hasattr(value, "_asdict"):
          value_dict = value._asdict()
      else:
          value_dict = value
      return {
          key: item_value.item()
          for key, item_value in value_dict.items()
      }
  
imports: import math
  import os
  import re
  import csv
  import shutil
  import urllib.request
  import collections.abc
  import torch
  import tqdm
  import pathlib
  import speechbrain
  from numbers import Number
label_desc: Use image node_id 15 for calling a global function with example usage: scalarize(value) and returns: unknown