code: def from_dict(transforms):
      """Deserializes the transformations stored in a dict.
          Supports deserialization of Streams only.
  
      Parameters
      ----------
      transforms : dict
          Transforms
  
      Returns
      -------
      out : solt.core.Stream
          An instance of solt.core.Stream.
  
      """
  
      if not isinstance(transforms, dict):
          raise TypeError("Transforms must be a dict!")
      for t in transforms:
          if "transforms" in transforms[t]:
              transforms[t]["transforms"] = [
                  from_dict(x) for x in transforms[t]["transforms"]
              ]
          if "affine_transforms" in transforms[t]:
              transforms[t]["affine_transforms"] = from_dict(
                  transforms[t]["affine_transforms"]
              )
          if t in Serializable.registry:
              cls = Serializable.registry[t]
          else:
              raise ValueError(f"Could not find {t} in the registry!")
  
          return cls(**transforms[t])
  
file_path: solt/solt/utils/_utils.py
imports: from functools import wraps
  import json
  import yaml
  import inspect
label_desc: Use image node_id 1 for calling a global function with example usage: from_dict(transforms) and returns: cls