code: def get_all_shard_instructions(
      info: dataset_info.DatasetInfo,
      out_file_format: file_adapters.FileFormat,
      out_path: epath.Path,
      in_file_adapter: Type[file_adapters.FileAdapter],
      out_file_adapter: Type[file_adapters.FileAdapter],
  ) -> list[ShardInstruction]:
      """Returns all shard instructions for the given dataset info."""
      shard_instructions = []
      for split_info in info.splits.values():
          shard_instructions.extend(
              _shard_instructions_for_split(
                  split_info=split_info,
                  out_file_format=out_file_format,
                  out_path=out_path,
                  in_file_adapter=in_file_adapter,
                  out_file_adapter=out_file_adapter,
              )
          )
      return shard_instructions
  
imports: from collections.abc import Iterator
  import dataclasses
  from typing import Type
  from absl import logging
  from etils import epath
  from tensorflow_datasets.core import constants
  from tensorflow_datasets.core import dataset_info
  from tensorflow_datasets.core import file_adapters
  from tensorflow_datasets.core import naming
  from tensorflow_datasets.core import read_only_builder
  from tensorflow_datasets.core import splits
  from tensorflow_datasets.core.utils import py_utils
  from tensorflow_datasets.core.utils import type_utils
  from tensorflow_datasets.core.utils.lazy_imports_utils import apache_beam
label_desc: Use image node_id 3 for calling a global function with example usage: get_all_shard_instructions(info, out_file_format, out_path, in_file_adapter, out_file_adapter) and returns: shard_instructions