def _kernel_seq(inputs, estimator):
    """
    Wrapper around a function that computes anything on two sequences and returns a dict

    While it is written as a general purpose kernel for anything, here it is used for
    causal discovery and estimation from CCM based methods.

    The function unpacks inputs into an index element and a sequence pair and runs the
    estimator function on the sequence pair, returning various estimates in a dict

    Parameters
    ----------
    inputs : tuple
        Tuple of two elements - (a, b) where a is an index, b is a tuple of two. a can
        be produced manually or more typically using enumerate; b holds the two sequences
        usually passed in by zip-ping larger iterables or itertools' product/combinations.
        a, the index, is passed to keep track of order in case of asynchronous execution
        Should look like this: (index, (sequence_x, sequence_y)
    estimator : function
        A function that can compute something on two arrays and return a dict. Preferably
        one that can compute something meaningful, like causal discovery

    Returns
    -------
    out : dict
        Estimates obtained by running estimator on inputs.

    """
    # Unpack inputs
    idx, seqs = inputs

    # Unpack sequences
    idx_x, idx_y, seq_x, seq_y = seqs

    # Initialize dictionary of output estimates with index
    out = {"index_pair": idx, "index_x": idx_x, "index_y": idx_y}

    # Execute the estimator function on the sequence pair
    out.update(estimator(seq_x, seq_y))

    # Some feedback to console
    # print(".", end="")

    return out