code: def chunks(iterable, chunk_size=1):
      """Chunks generator."""
      iterator = iter(iterable)
      for first in iterator:
          yield np.array(
              list(chain([first], islice(iterator, chunk_size - 1)))
          )
  
file_path: AmpliGraph/ampligraph/datasets/source_identifier.py
imports: import logging
  from collections.abc import Iterable
  from itertools import chain, islice
  import numpy
  import pandas
label_desc: Use image node_id 3 for calling a global function with example usage: chunks(iterable, chunk_size) without return types