On the generalization of learning algorithms that do not converge