code: def make_hashable(x):
      if isinstance(x, (tuple, list)):
          return tuple([make_hashable(y) for y in x])
      elif isinstance(x, dict):
          return tuple(
              sorted(
                  [
                      (make_hashable(item[0]), make_hashable(item[1]))
                      for item in x.items()
                  ]
              )
          )
      elif isinstance(x, tf.TensorShape):
          return tuple(x.as_list())
      else:
          try:
              hash(x)
              return x
          except TypeError:
              # not safe
              # collision may happen
              return str(id(x)) + str(x)
  
imports: import functools
  from abc import ABC
  from types import TracebackType
  from typing import Any
  from typing import Callable
  from typing import Optional
  import tensorflow
  import tf_encrypted
  from ..config import get_config
  from ..tensor.factory import AbstractTensor
label_desc: Use image node_id 1 for calling a global function with example usage: make_hashable(x) and returns: tuple, tuple, tuple, x, unknown