Dynamics of stochastic gradient descent for two-layer neural networks in the teacher-student setup