code: def _get_iterables_lengths(
      iterables: List[Iterable],
  ) -> List[Union[int, float]]:
      return [
          (
              float("inf")
              if (length := sized_len(iterable)) is None
              else length
          )
          for iterable in iterables
      ]
  
imports: import contextlib
  from collections.abc import Iterable
  from typing import Any, Callable, Dict, Iterator, List, Literal, Optional, Tuple, Type, Union
  from torch.utils.data.dataloader import _BaseDataLoaderIter, _MultiProcessingDataLoaderIter
  from typing_extensions import Self, TypedDict
  from lightning.fabric.utilities.data import sized_len
  from lightning.pytorch.utilities._pytree import _map_and_unflatten, _tree_flatten, tree_unflatten
label_desc: Use image node_id 2 for calling a global function with example usage: _get_iterables_lengths(iterables) and returns: unknown