  We explore the capacity of neural networks to detect a symmetry with complex
local and non-local patterns : the gauge symmetry Z 2 . This symmetry is
present in physical problems from topological transitions to QCD, and controls
the computational hardness of instances of spin-glasses. Here, we show how to
design a neural network, and a dataset, able to learn this symmetry and to find
compressed latent representations of the gauge orbits. Our method pays special
attention to system-wrapping loops, the so-called Polyakov loops, known to be
particularly relevant for computational complexity.
