Sobolev trained neural network surrogate models for optimization