The ultrametric organization of memories in a neural network