def lazy_pool(pool, function, args, disable_return=True):
    """
    Run pool lazily, suitable when the argument is a generator.

    This function is designed to work mostly with generators So by default it returns None. The reason for this is
    because generator are usually used for very long iterables, and storing all returns would exhaust memory.

    Args:
        pool: Pool instance.
        function: Function to be executed in the pool.
        args: Function arguments list.
        disable_return: Whether to store and return or not. When the argument is a generator, it exhaust memory.

    Returns:
        the return of the function, or None when disable_return=True
    """
    result = pool.imap_unordered(function, args)
    i = 0
    return_list = []
    while True:
        try:
            row = result.next()
        except StopIteration:
            break
        if not disable_return:
            return_list.append(row)
        i += 1
        print(f'\r{i} loaded.')
    return return_list
