code: def broadcast_shape(*shapes):
      if len(shapes) == 1:
          return shapes[0]
  
      out_shapes = []
      for ss in itertools.zip_longest(
          *[reversed(s) for s in shapes], fillvalue=-1
      ):
          shape = max(s for s in ss if s != -1)
          if any(
              i != -1 and i != 1 and i != shape and not np.isnan(i)
              for i in ss
          ):
              raise ValueError(
                  "Operands could not be broadcast together "
                  "with shape {0}".format(" ".join(map(str, shapes)))
              )
          out_shapes.append(shape)
      return tuple(reversed(out_shapes))
  
imports: import inspect
  import itertools
  import operator
  from collections import OrderedDict
  from collections.abc import Iterable
  from functools import lru_cache, reduce, wraps
  from math import ceil
  from numbers import Integral
  from typing import Dict, List, Union
  import numpy
  from ..core import ExecutableTuple, recursive_tile
  from ..utils import lazy_import
  from ..lib.mmh3 import hash_from_buffer
label_desc: Use image node_id 3 for calling a global function with example usage: broadcast_shape() and returns: tuple, shapes