def _verify_bsgs(group, base, gens):
    from sympy.combinatorics.perm_groups import PermutationGroup
    strong_gens_distr = _distribute_gens_by_base(base, gens)
    current_stabilizer = group
    for i in range(len(base)):
        candidate = PermutationGroup(strong_gens_distr[i])
        if current_stabilizer.order() != candidate.order():
            return False
        current_stabilizer = current_stabilizer.stabilizer(base[i])
    if current_stabilizer.order() != 1:
        return False
    return True
Verify the correctness of a base and strong generating set.
dataset/ETHPy150Open sympy/sympy/sympy/combinatorics/testutil.py/_verify_bsgs