code: def save_tensors(filename, tensor_dict):
      """
      Save dict of tensors to file
  
      Parameters
      ----------
      filename : str
          File name to store dict of tensors.
      tensor_dict: dict of dgl NDArray or backend tensor
          Python dict using string as key and tensor as value
  
      Returns
      ----------
      status : bool
          Return whether save operation succeeds
      """
      nd_dict = {}
      is_empty_dict = len(tensor_dict) == 0
      for key, value in tensor_dict.items():
          if not isinstance(key, str):
              raise Exception("Dict key has to be str")
          if F.is_tensor(value):
              nd_dict[key] = F.zerocopy_to_dgl_ndarray(value)
          elif isinstance(value, NDArray):
              nd_dict[key] = value
          else:
              raise Exception(
                  "Dict value has to be backend tensor or dgl ndarray"
              )
  
      return _CAPI_SaveNDArrayDict(filename, nd_dict, is_empty_dict)
  
imports: from __future__ import absolute_import
  from ..None import backend
  from .._ffi.function import _init_api
  from ..ndarray import NDArray
label_desc: Use image node_id 1 for calling a global function with example usage: save_tensors(filename, tensor_dict) and returns: _CAPI_SaveNDArrayDict