code: def bind(
      children: T,
      parents,
      *,
      omit=None,
      seed: Hashable | None = None,
      assume_layers: bool = True,
      split_every: float | Literal[False] | None = None,
  ) -> T:
      """
      Make ``children`` collection(s), optionally omitting sub-collections, dependent on
      ``parents`` collection(s). Two examples follow.
  
      The first example creates an array ``b2`` whose computation first computes an array
      ``a`` completely and then computes ``b`` completely, recomputing ``a`` in the
      process:
  
      >>> import dask
      >>> import dask.array as da
      >>> a = da.ones(4, chunks=2)
      >>> b = a + 1
      >>> b2 = bind(b, a)
      >>> len(b2.dask)
      9
      >>> b2.compute()
      array([2., 2., 2., 2.])
  
      The second example creates arrays ``b3`` and ``c3``, whose computation first
      computes an array ``a`` and then computes the additions, this time not
      recomputing ``a`` in the process:
  
      >>> c = a + 2
      >>> b3, c3 = bind((b, c), a, omit=a)
      >>> len(b3.dask), len(c3.dask)
      (7, 7)
      >>> dask.compute(b3, c3)
      (array([2., 2., 2., 2.]), array([3., 3., 3., 3.]))
  
      Parameters
      ----------
      children
          Dask collection or nested structure of Dask collections
      parents
          Dask collection or nested structure of Dask collections
      omit
          Dask collection or nested structure of Dask collections
      seed
          Hashable used to seed the key regeneration. Omit to default to a random number
          that will produce different keys at every call.
      assume_layers
          True
              Use a fast algorithm that works at layer level, which assumes that all
              collections in ``children`` and ``omit``
  
              #. use :class:`~dask.highlevelgraph.HighLevelGraph`,
              #. define the ``__dask_layers__()`` method, and
              #. never had their graphs squashed and rebuilt between the creation of the
                 ``omit`` collections and the ``children`` collections; in other words if
                 the keys of the ``omit`` collections can be found among the keys of the
                 ``children`` collections, then the same must also hold true for the
                 layers.
          False
              Use a slower algorithm that works at keys level, which makes none of the
              above assumptions.
      split_every
          See :func:`checkpoint`
  
      Returns
      -------
      Same as ``children``
          Dask collection or structure of dask collection equivalent to ``children``,
          which compute to the same values. All nodes of ``children`` will be regenerated,
          up to and excluding the nodes of ``omit``. Nodes immediately above ``omit``, or
          the leaf nodes if the collections in ``omit`` are not found, are prevented from
          computing until all collections in ``parents`` have been fully computed.
          The keys of the regenerated nodes will be different from the original ones, so
          that they can be used within the same graph.
      """
      if seed is None:
          seed = uuid.uuid4().bytes
  
      # parents=None is a special case invoked by the one-liner wrapper clone() below
      blocker = (
          checkpoint(parents, split_every=split_every)
          if parents is not None
          else None
      )
  
      omit, _ = unpack_collections(omit)
      if assume_layers:
          # Set of all the top-level layers of the collections in omit
          omit_layers = {
              layer for coll in omit for layer in coll.__dask_layers__()
          }
          omit_keys = set()
      else:
          omit_layers = set()
          # Set of *all* the keys, not just the top-level ones, of the collections in omit
          omit_keys = {
              key for coll in omit for key in coll.__dask_graph__()
          }
  
      unpacked_children, repack = unpack_collections(children)
      return repack(
          [
              _bind_one(child, blocker, omit_layers, omit_keys, seed)
              for child in unpacked_children
          ]
      )[0]
  
imports: from __future__ import annotations
  import uuid
  from collections.abc import Callable, Hashable
  from typing import Literal, TypeVar
  from dask.base import clone_key, get_collection_names, get_name_from_key, replace_name_in_key, tokenize, unpack_collections
  from dask.blockwise import blockwise
  from dask.core import flatten
  from dask.delayed import Delayed, delayed
  from dask.highlevelgraph import HighLevelGraph, Layer, MaterializedLayer
  from dask.typing import Graph, Key
label_desc: Use image node_id 5 for calling a global function with example usage: bind(children, parents) and returns: repack