A framework for randomized benchmarking over compact groups