Dictionaries

Collecting utilities for dictionaries

DIRAC.Core.Utilities.Dictionaries.breakDictionaryIntoChunks(aDict, chunkSize)

This function is a generator of chunks of dictionaries of size chunkSize

Parameters:
  • aDict (dict) – the dictionary you want to chunk

  • chunkSize (int) – the size of the chunks

Returns:

a generator object, that generates chunks of the original dictionary in aDict