  Learning with an artificial neural network encodes the system behavior in a
feed-forward function with a number of parameters optimized by data-driven
training. An open question is whether one can minimize the network complexity
without loss of performance to reveal how and why it works. Here we investigate
the learning of the phase transition in the Ising model and find that having
two hidden neurons can be enough for an accurate prediction of critical
temperature. We show that the networks learn the scaling dimension of the order
parameter while being trained as a phase classifier, demonstrating how the
machine learning exploits the Ising universality to work for different lattices
of the same criticality within a single set of trainings in one lattice
geometry.
