Double-descent curves in neural networks: a new perspective using Gaussian processes