r"""
    Returns a measure of group consistency

    Example:
        >>> # ENABLE_DOCTEST
        >>> from utool.util_alg import *  # NOQA
        >>> groups1 = [[1, 2, 3], [4], [5, 6]]
        >>> groups2 = [[1, 2], [4], [5, 6]]
        >>> common_groups = find_group_consistencies(groups1, groups2)
        >>> result = ('common_groups = %r' % (common_groups,))
        >>> print(result)
        common_groups = [(5, 6), (4,)]

def find_group_consistencies(groups1, groups2):
    r"""
    Returns a measure of group consistency

    Example:
        >>> # ENABLE_DOCTEST
        >>> from utool.util_alg import *  # NOQA
        >>> groups1 = [[1, 2, 3], [4], [5, 6]]
        >>> groups2 = [[1, 2], [4], [5, 6]]
        >>> common_groups = find_group_consistencies(groups1, groups2)
        >>> result = ('common_groups = %r' % (common_groups,))
        >>> print(result)
        common_groups = [(5, 6), (4,)]
    """
    group1_list = {tuple(sorted(_group)) for _group in groups1}
    group2_list = {tuple(sorted(_group)) for _group in groups2}
    common_groups = list(group1_list.intersection(group2_list))
    return common_groups